From: Richard M. Stallman Date: Sat, 28 Jun 1997 23:45:26 +0000 (+0000) Subject: (Fcall_process): Avoid storing alloca result X-Git-Tag: emacs-20.1~1457 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=67b50bf76ae18dab78366ab13e12eab001dd9df4;p=emacs.git (Fcall_process): Avoid storing alloca result directly into array element. --- diff --git a/src/callproc.c b/src/callproc.c index e90423e4dbe..0de906c5879 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -391,8 +391,10 @@ If you quit, the process is killed with SIGINT, or SIGKILL if you quit again.") int size = encoding_buffer_size (&argument_coding, XSTRING (args[i])->size); int produced, dummy; + unsigned char *dummy = (unsigned char *) alloca (size); - new_argv[i - 3] = (unsigned char *) alloca (size); + /* The Irix 4.0 compiler barfs if we eliminate dummy. */ + new_argv[i - 3] = dummy; produced = encode_coding (&argument_coding, XSTRING (args[i])->data, new_argv[i - 3], XSTRING (args[i])->size, size, &dummy);