Diff
Not logged in

Differences From:

File src/diffcmd.c part of check-in [7a2c37063a] - merge trunk into creole branch by bob on 2009-09-22 07:49:39. Also file src/diffcmd.c part of check-in [0eb08b860c] - Change more system() calls into portable_system() in an effort to fix path quoting problems on windows. by drh on 2009-09-16 21:29:18. [view]

To:

File src/diffcmd.c part of check-in [651c75c5b7] - merge trunk into creole by robert on 2009-10-05 10:08:05. Also file src/diffcmd.c part of check-in [b2fdf4fe14] - Fix the "gdiff" command so that it accepts commands with arguments. This will require users to put double-quotes around program pathnames that contain spaces. by drh on 2009-10-01 17:22:46. [view]

@@ -172,10 +172,9 @@
     if( zExternalCommand==0 ){
       internalDiff=1;
     }else{
       blob_zero(&cmd);
-      shell_escape(&cmd, zExternalCommand);
-      blob_append(&cmd, " ", 1);
+      blob_appendf(&cmd,"%s ",zExternalCommand);
     }
   }
   zFile = g.argv[g.argc-1];
   file_tree_name(zFile, &fname, 1);
@@ -208,10 +207,9 @@
     blob_reset(&out);
   }else{
     blob_write_to_file(&record, blob_str(&vname));
     blob_reset(&record);
-    shell_escape(&cmd, blob_str(&vname));
-    blob_appendf(&cmd, " ");
+    blob_appendf(&cmd, "%s ", blob_str(&vname));
     shell_escape(&cmd, zFile);
     portable_system(blob_str(&cmd));
     unlink(blob_str(&vname));
     blob_reset(&vname);