bnfb@uw-beaver.UUCP (10/10/86)
This program worked under 4.2bsd but not under 4.3bsd. If you change the
"w+" to "w", it works. Or if you use "a" instead of "a+".
The program:
#include <stdio.h>
main()
{
FILE* pF;
long l;
pF = fopen("TEMP","w+");
fputs( "AAAAA\n", pF );
l = ftell( pF );
fputs( "BBBBB\n", pF );
fseek( pF, l, 0 );
fputs( "CC", pF );
fclose( pF );
}
Under 4.2 it produces: Under 4.3 it produces:
AAAAA AAAAA
CCBBB BBBBB
Is this a real bug or am I just lost?
Bjorn
gwyn@brl-smoke.ARPA (Doug Gwyn ) (10/11/86)
In article <1871@uw-beaver> bnfb@uw-beaver.UUCP writes:
- This program worked under 4.2bsd but not under 4.3bsd.
- ...
- Is this a real bug or am I just lost?
It's a real bug.
dlong@sdsu.UUCP (Dean Long) (10/17/86)
Works fine on our 4.3. -- Dean Long San Diego State Univ. sdcsvax!sdsu!dlong