Lines Matching defs:buf
83 static char buf[1024];
103 if (chars > sizeof (buf) - 1) {
104 chars = sizeof (buf) - 1;
108 wcstombs(buf, msgbuf, chars + 1);
112 sprintf(buf, "unknown win32 error (%ld)", error);
116 return buf;
217 static int gzwrite(gzFile gz, const void *buf, unsigned len)
225 strm->next_in = (void *)buf;
236 static int gzread(gzFile gz, void *buf, unsigned len)
248 strm->next_out = (void *)buf;
323 caddr_t buf; /* mmap'ed buffer for the entire input file */
339 buf = mmap((caddr_t) 0, buf_len, PROT_READ, MAP_SHARED, ifd, (off_t)0);
340 if (buf == (caddr_t)(-1))
346 len = gzwrite(out, (char *)buf, (unsigned)buf_len);
353 munmap(buf, buf_len);
369 local char buf[BUFLEN];
380 len = (int)fread(buf, 1, sizeof(buf), in);
390 if (gzwrite(out, buf, (unsigned)len) != len)
407 local char buf[BUFLEN];
412 len = gzread(in, buf, sizeof(buf));
422 if ((int)fwrite(buf, 1, (unsigned)len, out) != len) {
481 local char buf[MAX_NAME_LEN];
487 if (len + strlen(GZ_SUFFIX) >= sizeof(buf)) {
493 snprintf(buf, sizeof(buf), "%s", file);
495 strcpy(buf, file);
500 outfile = buf;
504 infile = buf;
506 snprintf(buf + len, sizeof(buf) - len, "%s", GZ_SUFFIX);