Fix a brown paper bag segfault in clitar
authorVolker Lendecke <vl@samba.org>
Tue, 17 Jun 2008 19:08:56 +0000 (21:08 +0200)
committerKarolin Seeger <kseeger@samba.org>
Wed, 18 Jun 2008 20:30:43 +0000 (22:30 +0200)
Thanks to "No Body is Perfect" from gmail, whoever that is :-)

Volker
(cherry picked from commit 679d8dfa390601f777bfb43c02cd921eae5edcf4)

source/client/client.c
source/client/clitar.c

index d684ba860da68e7444cfdd6fabf81c129c3a96c8..438306e2ecb0baebe2ff04e810c74f71f856a258 100644 (file)
@@ -40,7 +40,7 @@ static char *desthost;
 static char *calling_name;
 static bool grepable = false;
 static char *cmdstr = NULL;
-static const char *cmd_ptr = NULL;
+const char *cmd_ptr = NULL;
 
 static int io_bufsize = 524288;
 
index f53c9b4035f1c9c8fe8c6b8ae5030c00d8a99658..084f87e3996a86d0f1d55e35c633d9ec50764763 100644 (file)
@@ -100,7 +100,7 @@ char tar_type='\0';
 static char **cliplist=NULL;
 static int clipn=0;
 static bool must_free_cliplist = False;
-static const char *cmd_ptr = NULL;
+extern const char *cmd_ptr;
 
 extern bool lowercase;
 extern uint16 cnum;