diff --git a/code/__HELPERS/shell.dm b/code/__HELPERS/shell.dm index 8b615eac0a0..eed86a3bd10 100644 --- a/code/__HELPERS/shell.dm +++ b/code/__HELPERS/shell.dm @@ -25,7 +25,10 @@ shelleo_ids[shelleo_id] = TRUE out_file = "[SHELLEO_NAME][shelleo_id][SHELLEO_OUT]" err_file = "[SHELLEO_NAME][shelleo_id][SHELLEO_ERR]" - errorcode = shell("[interpreter] \"[command]\" > [out_file] 2> [err_file]") + if(world.system_type == UNIX) + errorcode = shell("[interpreter] \"[replacetext(command, "\"", "\\\"")]\" > [out_file] 2> [err_file]") + else + errorcode = shell("[interpreter] \"[command]\" > [out_file] 2> [err_file]") if(fexists(out_file)) stdout = file2text(out_file) fdel(out_file)