Description: Include <stdlib.h> in src/regex/regex.c to declare malloc/realloc/free/abort
 The bundled GNU regex implementation only includes <stdlib.h> under
 STDC_HEADERS.  The legacy regex sub-configure's AC_STDC_HEADERS test does
 not define STDC_HEADERS on modern toolchains, so regex.c declares
 malloc()/realloc() with old-style empty parameter lists while free(),
 abort() and realloc() are never declared.  GCC 15 turns the resulting
 implicit function declarations into hard errors.  Include <stdlib.h>
 unconditionally, providing the proper declarations for all of these.
Author: tangxiaofeng <tangxiaofeng@kylinos.cn>
Forwarded: not-needed
Last-Update: 2026-09-02

--- hsc-1.0b.orig/src/regex/regex.c
+++ hsc-1.0b/src/regex/regex.c
@@ -63,12 +63,7 @@
 #include <strings.h>
 #endif
 
-#ifdef STDC_HEADERS
 #include <stdlib.h>
-#else
-char *malloc ();
-char *realloc ();
-#endif
 
 
 /* Define the syntax stuff for \<, \>, etc.  */
