X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/73233f0f1232c337ede5fae3f9f95d78457df7d0..59503278bfc27ad27c03dfaeab4e3de02198f81c:/syscall.c?ds=sidebyside diff --git a/syscall.c b/syscall.c index a004d9d3..96b42b6f 100644 --- a/syscall.c +++ b/syscall.c @@ -133,3 +133,12 @@ OFF_T do_lseek(int fd, OFF_T offset, int whence) return lseek(fd, offset, whence); #endif } + +char *d_name(struct dirent *di) +{ +#if HAVE_BROKEN_READDIR + return (di->d_name - 2); +#else + return di->d_name; +#endif +}