summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2017-04-13 07:01:43 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2017-04-13 07:01:43 +0000
commitb28835a5009751045e619a367231e80d81702836 (patch)
treed60d9fd3227f2e001c68987f8ff59ccede4294eb
parent917fe3fa612dc457f2e561c6cae0d7c2cbf895dc (diff)
downloadexecline-b28835a5009751045e619a367231e80d81702836.tar.xz
Fix invalid variable name check in getpid (thanks jjk)
-rw-r--r--src/execline/getpid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/execline/getpid.c b/src/execline/getpid.c
index 7fb39ac..dd9623a 100644
--- a/src/execline/getpid.c
+++ b/src/execline/getpid.c
@@ -15,7 +15,7 @@ int main (int argc, char const *const *argv, char const *const *envp)
PROG = "getpid" ;
if (argc < 3) strerr_dieusage(100, USAGE) ;
len = strlen(argv[1]) ;
- if (!memchr(argv[1], '=', len))
+ if (memchr(argv[1], '=', len))
strerr_dief2x(100, "invalid variable name: ", argv[1]) ;
{
size_t i = len+1 ;