[m-rev.] for review: Handle argv[0] == NULL.

Zoltan Somogyi zoltan.somogyi at runbox.com
Mon Jan 31 13:52:30 AEDT 2022


2022-01-31 13:48 GMT+11:00 "Peter Wang" <novalazy at gmail.com>:
> @@ -11551,7 +11551,7 @@ system_temp_dir("", 0, !IO).
>      [will_not_call_mercury, promise_pure, tabled_for_io, thread_safe,
>          does_not_affect_liveness, may_not_duplicate],
>  "
> -    if (MR_progname) {
> +    if (MR_progname && MR_progname_is_known) {
>          MR_make_aligned_string(PrognameOut, MR_progname);
>      } else {

This is not new, but the first test should be "(MR_progname != NULL)".
The rest of the diff is fine.

Zoltan.


More information about the reviews mailing list