Tighten system call to unzip
authorIan Walls <ian.walls@bywatersolutions.com>
Wed, 6 Oct 2010 20:25:19 +0000 (16:25 -0400)
committerGalen Charlton <gmcharlt@gmail.com>
Wed, 6 Oct 2010 23:22:41 +0000 (19:22 -0400)
Signed-off-by: Galen Charlton <gmcharlt@gmail.com>
tools/picture-upload.pl

index d21b6b0..b60f83c 100755 (executable)
@@ -95,7 +95,7 @@ if ( ($op eq 'Upload') && $uploadfile ) {       # Case is important in these ope
         }
         close $tfh;
         if ( $filetype eq 'zip' ) {
-            unless (system("unzip $tempfile -d $dirname") == 0) {
+            unless (system("unzip", "$tempfile -d $dirname") == 0) {
                 $errors{'UZIPFAIL'} = $uploadfilename;
                $template->param( ERRORS => [ \%errors ] );
                 output_html_with_http_headers $input, $cookie, $template->output;   # This error is fatal to the import, so bail out here