3 * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.
4 * See the copyright notice in the ACK home directory, in the file "Copyright".
6 #define MININT (1 << (sizeof(int) * 8 - 1))
7 #define MAXCHUNK (~MININT) /* Highest count we write(2). */
8 /* Notice that MAXCHUNK itself might be too large with some compilers.
9 You have to put it in an int!
12 static int maxchunk
= MAXCHUNK
;
15 * Just write "cnt" bytes to file-descriptor "fd".
17 wr_bytes(fd
, string
, cnt
)
18 register char *string
;
23 register int n
= cnt
>= maxchunk
? maxchunk
: cnt
;
25 if (write(fd
, string
, n
) != n
)