Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Don't treat "[:" as the start of a named set if there's no ":]".
[rsync/rsync.git]
/
main.c
diff --git
a/main.c
b/main.c
index
29ee6ad
..
629eb35
100644
(file)
--- a/
main.c
+++ b/
main.c
@@
-285,7
+285,7
@@
oom:
static char *get_local_name(struct file_list *flist,char *name)
{
STRUCT_STAT st;
static char *get_local_name(struct file_list *flist,char *name)
{
STRUCT_STAT st;
- int
len
;
+ int
e
;
extern int orig_umask;
if (verbose > 2)
extern int orig_umask;
if (verbose > 2)
@@
-311,8
+311,7
@@
static char *get_local_name(struct file_list *flist,char *name)
return name;
}
return name;
}
- len = strlen(name);
- if ((len <= 1 || name[len-1] != '/') && flist->count <= 1)
+ if (flist->count <= 1 && ((e = strlen(name)) <= 1 || name[e-1] != '/'))
return name;
if (do_mkdir(name,0777 & ~orig_umask) != 0) {
return name;
if (do_mkdir(name,0777 & ~orig_umask) != 0) {
@@
-1057,6
+1056,5
@@
int main(int argc,char *argv[])
else
exit_cleanup(ret);
else
exit_cleanup(ret);
- exit(ret);
- /* NOTREACHED */
+ return ret;
}
}