From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9250 invoked by alias); 17 Jul 2008 20:07:00 -0000 Received: (qmail 9241 invoked by uid 22791); 17 Jul 2008 20:07:00 -0000 X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 17 Jul 2008 20:06:40 +0000 Received: from zps36.corp.google.com (zps36.corp.google.com [172.25.146.36]) by smtp-out.google.com with ESMTP id m6HK6Ywb000527 for ; Thu, 17 Jul 2008 21:06:34 +0100 Received: from localhost (elbrus.corp.google.com [172.18.116.17]) by zps36.corp.google.com with ESMTP id m6HK6U90025456; Thu, 17 Jul 2008 13:06:30 -0700 Received: by localhost (Postfix, from userid 74925) id 1C9DC3A67B6; Thu, 17 Jul 2008 13:06:30 -0700 (PDT) To: gdb-patches@sourceware.org Subject: [RFA] Fix for failing gdb.base/auxv.exp on Linux Message-Id: <20080717200630.1C9DC3A67B6@localhost> Date: Thu, 17 Jul 2008 20:07:00 -0000 From: ppluzhnikov@google.com (Paul Pluzhnikov) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-07/txt/msg00343.txt.bz2 Greetings, gdb.base/auxv.exp is failing for me on Linux, because 'info auxv' from live process prints several trailing AT_NULL entries: (gdb) inf auxv 32 AT_SYSINFO Special system info/entry points 0xffffe400 33 AT_SYSINFO_EHDR System-supplied DSO's ELF header 0xffffe000 ... 15 AT_PLATFORM String identifying platform 0xffffda3b "i686" 0 AT_NULL End of vector 0x0 0 AT_NULL End of vector 0x0 0 AT_NULL End of vector 0x0 Attached patch terminates the list at first AT_NULL, and makes the test succeed. Ok to commit? -- Paul Pluzhnikov 2008-07-17 Paul Pluzhnikov * auxv.c (fprint_target_auxv): Stop at AT_NULL. Index: auxv.c =================================================================== RCS file: /cvs/src/src/gdb/auxv.c,v retrieving revision 1.11 diff -u -p -u -r1.11 auxv.c --- auxv.c 4 May 2008 09:28:27 -0000 1.11 +++ auxv.c 17 Jul 2008 18:57:18 -0000 @@ -246,6 +246,8 @@ fprint_target_auxv (struct ui_file *file break; } ++ents; + if (type == AT_NULL) + break; } xfree (data);