unpack-trees: allow Porcelain to give different error messages
[gitweb.git] / git-send-email.perl
index cb05cf5b9ebc41c6d95067037605154c5a83e9b1..1e1d98656d645371612cac02abad4ea33757d40e 100755 (executable)
@@ -513,7 +513,7 @@ sub expand_aliases {
        close(C);
 
        my $editor = $ENV{GIT_EDITOR} || Git::config(@repo, "core.editor") || $ENV{VISUAL} || $ENV{EDITOR} || "vi";
-       system('sh', '-c', '$0 $@', $editor, $compose_filename);
+       system('sh', '-c', $editor.' "$@"', $editor, $compose_filename);
 
        open(C2,">",$compose_filename . ".final")
                or die "Failed to open $compose_filename.final : " . $!;