X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=support%2FUtil%2FMySystem.c;h=b78d99aac17b20736a6e3eda39af189a3cfd3fe8;hb=f98f0bb012d04593bdeb00a0c18dc281bae1e9bb;hp=7017ad1e02b4d3118c5df669c3bbc0f34725b744;hpb=0c93fb538f7fd17fa07051fa28681cc8ca2bc12b;p=fw%2Fsdcc diff --git a/support/Util/MySystem.c b/support/Util/MySystem.c index 7017ad1e..b78d99aa 100644 --- a/support/Util/MySystem.c +++ b/support/Util/MySystem.c @@ -237,14 +237,13 @@ merge_command(const char *command, const char *params) { /* allocate extra space for 2x'"', ' ' and '\0' */ char *cmd_line = (char *)Safe_alloc(strlen(command) + strlen(params) + 4); - sprintf(cmd_line, "%s %s", command, params); - + sprintf(cmd_line, "\"%s\" %s", command, params); return cmd_line; } /*! - * check if the path is absolute + * check if the path is relative or absolute (if contains the dir separator) */ static int