From c1c9abbfcafe8e55d86dfe13aed6874ad194d761 Mon Sep 17 00:00:00 2001 From: RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> Date: Fri, 29 Dec 2023 00:45:14 +0100 Subject: Change iritating NULL assignment diff --git a/plugins/popen.c b/plugins/popen.c index 036bc60..54e63bc 100644 --- a/plugins/popen.c +++ b/plugins/popen.c @@ -105,7 +105,7 @@ spopen (const char *cmdstring) #endif env[0] = strdup("LC_ALL=C"); - env[1] = '\0'; + env[1] = NULL; /* if no command was passed, return with no error */ if (cmdstring == NULL) diff --git a/plugins/runcmd.c b/plugins/runcmd.c index 32fd6b9..ed49bb9 100644 --- a/plugins/runcmd.c +++ b/plugins/runcmd.c @@ -115,7 +115,7 @@ np_runcmd_open(const char *cmdstring, int *pfd, int *pfderr) if(!np_pids) NP_RUNCMD_INIT; env[0] = strdup("LC_ALL=C"); - env[1] = '\0'; + env[1] = NULL; /* make copy of command string so strtok() doesn't silently modify it */ /* (the calling program may want to access it later) */ -- cgit v0.10-9-g596f