]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Make sure we duplicate strings returned by cgiGetTextField, just as we do for cgiGetV...
authorMichael R Sweet <msweet@msweet.org>
Wed, 14 Aug 2024 00:31:48 +0000 (20:31 -0400)
committerMichael R Sweet <msweet@msweet.org>
Wed, 14 Aug 2024 00:31:48 +0000 (20:31 -0400)
cgi-bin/var.c

index e97d2a8fca80a3bd2064bd796b42a14de3cb09d2..fdc6fa7b57dcd413fb0b2329092bf816f5e0b804 100644 (file)
@@ -288,7 +288,7 @@ cgiGetTextfield(const char *name)   /* I - Name of form field */
     value = NULL;
   }
 
-  return (value);
+  return (value ? strdup(value) : NULL);
 }