Aucbvax.4986
net.2bsd-bugs
utzoo!decvax!ucbvax!romine@SRC-Unix
Fri Nov 6 06:00:20 1981
Diff Bug
From: Raleigh F. Romine <ROMINE AT SRC-UNIX>
There appear to be two bugs in the 2.8BSD diff source.
In diffdir.c a cast to unsigned is needed in a malloc call and
in diffreg.c a fprintf call needs a stream argument.
A diff listing follows:
*** diffdir.c Fri Nov 6 08:13:39 1981
--- diffdir.c_ Fri Nov 6 08:04:26 1981
***************
*** 185,191
done();
}
fstat(0, &stb);
! dp = (struct direct *)malloc((unsigned)stb.st_size + sizeof (struct direct));
if (dp == 0) {
fprintf(stderr, "diff: ran out of memory\n");
done();
--- 185,191 -----
done();
}
fstat(0, &stb);
! dp = (struct direct *)malloc(stb.st_size + sizeof (struct direct));
if (dp == 0) {
fprintf(stderr, "diff: ran out of memory\n");
done();
*** diffreg.c Fri Nov 6 08:15:34 1981
--- diffreg.c_ Fri Nov 6 08:14:51 1981
***************
*** 167,173
tempfile = mktemp("/tmp/dXXXXX");
f = creat(tempfile,0600);
if (f
<HR>
This Usenet Oldnews Archive
article may be copied and distributed freely, provided:
<P>
1. There is no money collected for the text(s) of the articles.
<BR>
2. The following notice remains appended to each copy:
<P>
<EM>The Usenet Oldnews Archive: Compilation Copyright© 1981, 1996
<BR> Bruce Jones, Henry Spencer, David Wiseman.</EM>
<P>
<HR>
Goto <A HREF="81.11.06_ucbvax.4993_net.2bsd-bugs.html">NEXT</A> article in NET.bugs.2bsd Newsgroup
<BR>Return to <A HREF="NET.bugs.2bsd-index.html">NET.bugs.2bsd index</A>
<BR>Return to the
<A HREF="../index.html">Usenet Oldnews Archive index</A>
</HTML>
-----------------------------------------------------------------
gopher://quux.org/ conversion by John Goerzen <
[email protected]>
of
http://communication.ucsd.edu/A-News/
This Usenet Oldnews Archive
article may be copied and distributed freely, provided:
1. There is no money collected for the text(s) of the articles.
2. The following notice remains appended to each copy:
The Usenet Oldnews Archive: Compilation Copyright (C) 1981, 1996
Bruce Jones, Henry Spencer, David Wiseman.