From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31074 invoked by alias); 28 Nov 2005 12:45:29 -0000 Received: (qmail 31038 invoked by uid 22791); 28 Nov 2005 12:45:29 -0000 X-Spam-Check-By: sourceware.org Received: from sunsite.ms.mff.cuni.cz (HELO sunsite.mff.cuni.cz) (195.113.15.26) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 28 Nov 2005 12:45:27 +0000 Received: from sunsite.mff.cuni.cz (sunsite.mff.cuni.cz [127.0.0.1]) by sunsite.mff.cuni.cz (8.13.1/8.13.1) with ESMTP id jASCjGMJ010818; Mon, 28 Nov 2005 13:45:16 +0100 Received: (from jakub@localhost) by sunsite.mff.cuni.cz (8.13.1/8.13.1/Submit) id jASCjF7W010817; Mon, 28 Nov 2005 13:45:15 +0100 Date: Mon, 28 Nov 2005 12:45:00 -0000 From: Jakub Jelinek To: Ulrich Drepper Cc: Glibc hackers Subject: [PATCH] Fix tst-mallocfork Message-ID: <20051128124515.GX16723@sunsite.mff.cuni.cz> Reply-To: Jakub Jelinek Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.1i Mailing-List: contact libc-hacker-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sourceware.org X-SW-Source: 2005-11/txt/msg00036.txt.bz2 Hi! As detected by valgrind, sa_flags was uninitialized when calling sigaction. Fixed thusly. 2005-11-28 Jakub Jelinek * malloc/tst-mallocfork.c (do_test): Make sure sa_flags is initialized. Reported by John Reiser . --- libc/malloc/tst-mallocfork.c.jj 2005-09-27 07:42:06.000000000 +0200 +++ libc/malloc/tst-mallocfork.c 2005-11-28 13:28:48.000000000 +0100 @@ -22,9 +22,8 @@ do_test (void) { pid_t parent = getpid (); - struct sigaction action; + struct sigaction action = { .sa_handler = sig_handler }; sigemptyset (&action.sa_mask); - action.sa_handler = sig_handler; malloc (sizeof (int)); Jakub