Bug 174323 - tst-mallocfork.c uses uninit value
tst-mallocfork.c uses uninit value
Status: CLOSED UPSTREAM
Product: Fedora
Classification: Fedora
Component: glibc (Show other bugs)
5
x86_64 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-11-27 17:54 EST by John Reiser
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-11-28 07:42:48 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description John Reiser 2005-11-27 17:54:21 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.8) Gecko/20051118 Fedora/1.5-0.5.0.rc3 Firefox/1.5

Description of problem:
Internal testcase malloc/tst-mallocfork.c uses an uninit value in a structure whose address is passed to sigaction().  This creates doubt about the validity of the rsults of the test.

Run valgrind-3.1.0 on malloc/tst-mallocfork:
==14423== Syscall param rt_sigaction(act->sa_flags) points to uninitialised byte(s)
==14423==    at 0x4A39D39: sigaction (sigaction.c:68)
==14423==    by 0x400FBA: do_test (tst-mallocfork.c:31)


-----malloc/tst-mallocfork.c line 25
  struct sigaction action;
  sigemptyset (&action.sa_mask);
  action.sa_handler = sig_handler;   ## action.sa_flags is not initialized

  malloc (sizeof (int));

  if (sigaction (SIGALRM, &action, NULL) != 0)
-----

Version-Release number of selected component (if applicable):
glibc-2.3.90-18

How reproducible:
Always

Steps to Reproduce:
1. Run internal testcase malloc/tst-mallocfork under valgrind.
2.
3.
  

Actual Results:  memcheck complains that act->sa_flags is uninit.

Expected Results:  No complaints.

Additional info:

Note You need to log in before you can comment on or make changes to this bug.