summaryrefslogtreecommitdiff
path: root/tests/scripts/features/loadapi
diff options
context:
space:
mode:
Diffstat (limited to 'tests/scripts/features/loadapi')
-rw-r--r--tests/scripts/features/loadapi6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/scripts/features/loadapi b/tests/scripts/features/loadapi
index cecb114..94a48a7 100644
--- a/tests/scripts/features/loadapi
+++ b/tests/scripts/features/loadapi
@@ -36,13 +36,17 @@ test_expand (const char *val)
static char *
func_test (const char *funcname, int argc, char **argv)
{
+ char *mem;
+
if (strcmp (funcname, "test-expand") == 0)
return test_expand (argv[0]);
if (strcmp (funcname, "test-eval") == 0)
return test_eval (argv[0]);
- return strdup ("unknown");
+ mem = gmk_alloc (strlen ("unknown") + 1);
+ strcpy (mem, "unknown");
+ return mem;
}
int