From 8c3fedd243b69349b426144e5e2b94ef4aea6a4c Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Wed, 8 Jul 2020 03:01:45 +0000 Subject: CTAN sync 202007080301 --- graphics/asymptote/runfile.in | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'graphics/asymptote/runfile.in') diff --git a/graphics/asymptote/runfile.in b/graphics/asymptote/runfile.in index d9186eee6d..39eb464c28 100644 --- a/graphics/asymptote/runfile.in +++ b/graphics/asymptote/runfile.in @@ -348,15 +348,17 @@ Int rename(string from, string to) return rc; } -// Create a unique temporary file name. +// Create a uniquely named temporary file. string mktemp(string s) { - char *S=Strdup(s+"XXXXXX"); + char *S=StrdupMalloc(s+"XXXXXX"); int fd=mkstemp(S); if(fd < 0) { ostringstream buf; buf << "Could not create unique temporary filename based on " << s; error(buf); } - return S; + string T(S); + free(S); + return T; } -- cgit v1.2.3