summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2003-08-27 07:39:26 +0000
committerTim Potter <tpot@samba.org>2003-08-27 07:39:26 +0000
commit64ca3346961650d089515b81ca3887fa499c1ef3 (patch)
tree8a3299b7a8ee95a9c528d0c133d379797287cc56 /source3
parentc60f38569104864bfaf67e7ee9ae99f8edb7359f (diff)
downloadsamba-64ca3346961650d089515b81ca3887fa499c1ef3.tar.gz
samba-64ca3346961650d089515b81ca3887fa499c1ef3.tar.bz2
samba-64ca3346961650d089515b81ca3887fa499c1ef3.zip
Print an error instead of crashing if no argument is specified for
smbclient -T Fixes bug 345. (This used to be commit a46e58e2b6e3d9526012d6a2d903163a3373fa59)
Diffstat (limited to 'source3')
-rw-r--r--source3/client/clitar.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/client/clitar.c b/source3/client/clitar.c
index 5e20c3e11b..f7a292dbbf 100644
--- a/source3/client/clitar.c
+++ b/source3/client/clitar.c
@@ -1775,6 +1775,10 @@ int tar_parseargs(int argc, char *argv[], const char *Optarg, int Optind)
if (tarhandle == 1) {
dbf = x_stderr;
}
+ if (!argv[Optind]) {
+ DEBUG(0,("Must specify tar filename\n"));
+ return 0;
+ }
if (!strcmp(argv[Optind], "-")) {
newOptind++;
}