fixed setbuf. count field was set wrong
This commit is contained in:
parent
a2d921040d
commit
b8fb8a57fa
2 changed files with 5 additions and 2 deletions
|
@ -1,7 +1,6 @@
|
|||
/* $Header$ */
|
||||
#include <stdio.h>
|
||||
|
||||
|
||||
setbuf(iop, buffer)
|
||||
register FILE *iop;
|
||||
char *buffer;
|
||||
|
@ -13,9 +12,11 @@ char *buffer;
|
|||
|
||||
iop->_buf = (unsigned char *) buffer;
|
||||
|
||||
iop->_count = 0;
|
||||
if ( iop->_buf == NULL )
|
||||
iop->_flags |= IO_UNBUFF;
|
||||
else
|
||||
iop->_count = BUFSIZ;
|
||||
|
||||
iop->_ptr = iop->_buf;
|
||||
iop->_count = 0;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
/* $Header$ */
|
||||
#ifndef __USG
|
||||
static struct zonetable {
|
||||
int offset;
|
||||
char *stdzone;
|
||||
|
@ -58,3 +59,4 @@ timezone(zone, dst)
|
|||
*c = '\0';
|
||||
return buf;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue