X-Git-Url: https://git.exim.org/users/heiko/exim.git/blobdiff_plain/c988f1f4faa9f679f79beddf3c14676c5dcb8e28..d4c9963ace2b653f657c74abecfecb7546c722b1:/src/exim_monitor/em_xs.c?ds=sidebyside diff --git a/src/exim_monitor/em_xs.c b/src/exim_monitor/em_xs.c index a6fe64be3..ee91f7c15 100644 --- a/src/exim_monitor/em_xs.c +++ b/src/exim_monitor/em_xs.c @@ -1,10 +1,8 @@ -/* $Cambridge: exim/src/exim_monitor/em_xs.c,v 1.2 2005/01/04 10:00:42 ph10 Exp $ */ - /************************************************* * Exim Monitor * *************************************************/ -/* Copyright (c) University of Cambridge, 1995 - 2005 */ +/* Copyright (c) University of Cambridge, 1995 - 2016 */ /* See the file NOTICE for conditions of use and distribution. */ /* This file contains a number of subroutines that are in effect @@ -32,15 +30,16 @@ void xs_SetValues(Widget w, Cardinal num_args, ...) { int i; va_list ap; -Arg *aa = (num_args > 15)? (Arg *)malloc(num_args*sizeof(Arg)) : xs_temparg; +Arg *aa = (num_args > 15)? store_malloc(num_args*sizeof(Arg)) : xs_temparg; va_start(ap, num_args); for (i = 0; i < num_args; i++) { aa[i].name = va_arg(ap, String); aa[i].value = va_arg(ap, XtArgVal); } +va_end(ap); XtSetValues(w, aa, num_args); -if (num_args > 15) free(aa); +if (num_args > 15) store_free(aa); } /* End of em_xs.c */