]> gcc.gnu.org Git - gcc.git/commitdiff
Don't crash when copying a call with no arguments.
authorIan Lance Taylor <ian@gcc.gnu.org>
Thu, 16 Dec 2010 01:47:10 +0000 (01:47 +0000)
committerIan Lance Taylor <ian@gcc.gnu.org>
Thu, 16 Dec 2010 01:47:10 +0000 (01:47 +0000)
From-SVN: r167897

gcc/go/gofrontend/expressions.h

index 53cca06d42e9801c707a62cab56fffe6b7ebfa8f..5d7d90bdb01690b62d456dcc954409938cbed5c9 100644 (file)
@@ -1235,7 +1235,10 @@ class Call_expression : public Expression
   Expression*
   do_copy()
   {
-    return Expression::make_call(this->fn_->copy(), this->args_->copy(),
+    return Expression::make_call(this->fn_->copy(),
+                                (this->args_ == NULL
+                                 ? NULL
+                                 : this->args_->copy()),
                                 this->is_varargs_, this->location());
   }
 
This page took 0.067327 seconds and 5 git commands to generate.