diff options
author | Wayne Davison <wayned@samba.org> | 2007-08-01 22:18:46 +0000 |
---|---|---|
committer | Wayne Davison <wayned@samba.org> | 2007-08-01 22:18:46 +0000 |
commit | 411c04f06fa26642c6bfc29fd70128e3f870a455 (patch) | |
tree | 69690a3b6a3de40a14a51e19faa2a2da18126d04 /flist.c | |
parent | 5d935dce63ae975db0efc23e3d94c32b17424444 (diff) | |
download | android_external_rsync-411c04f06fa26642c6bfc29fd70128e3f870a455.tar.gz android_external_rsync-411c04f06fa26642c6bfc29fd70128e3f870a455.tar.bz2 android_external_rsync-411c04f06fa26642c6bfc29fd70128e3f870a455.zip |
If readdir() gives us an empty name, reject it.
Diffstat (limited to 'flist.c')
-rw-r--r-- | flist.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -1469,6 +1469,13 @@ static void send_directory(int f, struct file_list *flist, char *fbuf, int len, full_fname(fbuf)); continue; } + if (dname[0] == '\0') { + io_error |= IOERR_GENERAL; + rprintf(FINFO, + "cannot send file with empty name in %s\n", + full_fname(fbuf)); + continue; + } send_file_name(f, flist, fbuf, NULL, flags, filter_level); } |