Lines Matching refs:buf
352 const char *buf = fname, *c; in follow_symlink() local
362 while ((rc = lstat (buf, &statbuf)) == 0 in follow_symlink()
365 if (buf == buf2) in follow_symlink()
368 buf = buf1; in follow_symlink()
371 while ((rc = readlink (buf, buf2, buf_size)) == buf_size) in follow_symlink()
378 panic (_("couldn't follow symlink %s: %s"), buf, strerror(errno)); in follow_symlink()
382 if (buf2[0] != '/' && (c = strrchr (buf, '/')) != NULL) in follow_symlink()
386 int len = c - buf + 1; in follow_symlink()
395 if (buf != buf1) in follow_symlink()
396 memcpy (buf1, buf, len); in follow_symlink()
400 buf = buf1; in follow_symlink()
407 buf = buf2; in follow_symlink()
412 panic (_("cannot stat %s: %s"), buf, strerror(errno)); in follow_symlink()
414 return buf; in follow_symlink()
492 ck_memdup(buf, len) in ck_memdup() argument
493 const VOID *buf; in ck_memdup()
497 return memcpy(ret, buf, len);