Matt McCutchen's Web Site
/
rsync
/
rsync.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
4cdf25e
)
check argc and show usage if no args
author
Andrew Tridgell
<tridge@samba.org>
Wed, 13 May 1998 07:04:40 +0000
(07:04 +0000)
committer
Andrew Tridgell
<tridge@samba.org>
Wed, 13 May 1998 07:04:40 +0000
(07:04 +0000)
main.c
patch
|
blob
|
blame
|
history
diff --git
a/main.c
b/main.c
index
ea7622a
..
b4c514f
100644
(file)
--- a/
main.c
+++ b/
main.c
@@
-494,6
+494,11
@@
int main(int argc,char *argv[])
starttime = time(NULL);
am_root = (getuid() == 0);
+ if (argc < 2) {
+ usage(FERROR);
+ exit(1);
+ }
+
/* we set a 0 umask so that correct file permissions can be
carried across */
orig_umask = (int)umask(0);