Fix stack-management bug when semctl encounters errors blead
authorAaron Crane <arc@cpan.org>
Mon, 20 Oct 2014 14:22:52 +0000 (15:22 +0100)
committerAaron Crane <arc@cpan.org>
Mon, 20 Oct 2014 20:43:38 +0000 (21:43 +0100)
commitfa367bcbf78381959666f443b5f1d9da7870f943
treef6875abf71ea6bb896a8ece94a5447226cb4ec90
parent6aa683079638ed0b1923473b64317a0ef3a99849
Fix stack-management bug when semctl encounters errors

The success cases in pp_semctl both push a single value to the stack, but
the error case merely set the topmost stack value to undef. The fix is to
push an undef.

This bug manifests most obviously as an "uninitialized value in list slice"
warning when doing something like `my $test = (semctl -1,0,0,0)[0]`; that
was reported out-of-band to rjbs.
MANIFEST
pp_sys.c
t/io/semctl.t [new file with mode: 0644]