| ... | @@ -1118,10 +1118,12 @@ fn runCommand( | ... | @@ -1118,10 +1118,12 @@ fn runCommand( |
| 1118 | // Wine's excessive stderr logging is only situationally helpful. Disable it by default, but | 1118 | // Wine's excessive stderr logging is only situationally helpful. Disable it by default, but |
| 1119 | // allow the user to override it (e.g. with `WINEDEBUG=err+all`) if desired. | 1119 | // allow the user to override it (e.g. with `WINEDEBUG=err+all`) if desired. |
| 1120 | if (env_map.get("WINEDEBUG") == null) { | 1120 | if (env_map.get("WINEDEBUG") == null) { |
| 1121 | // We don't own `env_map` at this point, so turn it into a copy before modifying it. | 1121 | // We don't own `env_map` at this point, so create a copy in order to modify it. |
| 1122 | env_map = arena.create(EnvMap) catch @panic("OOM"); | 1122 | const new_env_map = arena.create(EnvMap) catch @panic("OOM"); |
| 1123 | env_map.hash_map = try env_map.hash_map.cloneWithAllocator(arena); | 1123 | new_env_map.hash_map = try env_map.hash_map.cloneWithAllocator(arena); |
| 1124 | try env_map.put("WINEDEBUG", "-all"); | 1124 | try new_env_map.put("WINEDEBUG", "-all"); |
| | 1125 | |
| | 1126 | env_map = new_env_map; |
| 1125 | } | 1127 | } |
| 1126 | } else { | 1128 | } else { |
| 1127 | return failForeign(run, "-fwine", argv[0], exe); | 1129 | return failForeign(run, "-fwine", argv[0], exe); |