From: Steven G. Kargl Date: Mon, 3 Aug 2015 16:56:39 +0000 (+0000) Subject: re PR fortran/66942 (trans-expr.c:5701 runtime error: member call on null pointer... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5c4aa279feefc45b5527002c04057c3b0d6b941f;p=gcc.git re PR fortran/66942 (trans-expr.c:5701 runtime error: member call on null pointer of type 'struct vec') 2015-08-03 Steven G. Kargl PR fortran/66942 * trans-expr.c (gfc_conv_procedure_call): Avoid NULL pointer reference From-SVN: r226517 --- diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index 03ea33cc996..36cd6f3b4cd 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2015-08-03 Steven G. Kargl + + PR fortran/66942 + * trans-expr.c (gfc_conv_procedure_call): Avoid NULL pointer reference + 2015-08-03 Mikael Morin PR fortran/64921 diff --git a/gcc/fortran/trans-expr.c b/gcc/fortran/trans-expr.c index be6bfe2006d..af30b558576 100644 --- a/gcc/fortran/trans-expr.c +++ b/gcc/fortran/trans-expr.c @@ -5921,18 +5921,18 @@ gfc_conv_procedure_call (gfc_se * se, gfc_symbol * sym, vec_safe_reserve (retargs, arglen); /* Add the return arguments. */ - retargs->splice (arglist); + vec_safe_splice (retargs, arglist); /* Add the hidden present status for optional+value to the arguments. */ - retargs->splice (optionalargs); + vec_safe_splice (retargs, optionalargs); /* Add the hidden string length parameters to the arguments. */ - retargs->splice (stringargs); + vec_safe_splice (retargs, stringargs); /* We may want to append extra arguments here. This is used e.g. for calls to libgfortran_matmul_??, which need extra information. */ - if (!vec_safe_is_empty (append_args)) - retargs->splice (append_args); + vec_safe_splice (retargs, append_args); + arglist = retargs; /* Generate the actual call. */