From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8467 invoked by alias); 7 Feb 2012 20:47:36 -0000 Received: (qmail 8453 invoked by uid 22791); 7 Feb 2012 20:47:34 -0000 X-SWARE-Spam-Status: No, hits=-2.8 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,TW_BJ X-Spam-Check-By: sourceware.org Received: from mail-pz0-f41.google.com (HELO mail-pz0-f41.google.com) (209.85.210.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 07 Feb 2012 20:47:21 +0000 Received: by dadv6 with SMTP id v6so6770638dad.0 for ; Tue, 07 Feb 2012 12:47:21 -0800 (PST) Received: by 10.68.228.101 with SMTP id sh5mr61362308pbc.127.1328647641259; Tue, 07 Feb 2012 12:47:21 -0800 (PST) MIME-Version: 1.0 Received: by 10.68.30.167 with HTTP; Tue, 7 Feb 2012 12:47:01 -0800 (PST) From: Josh Matthews Date: Tue, 07 Feb 2012 20:47:00 -0000 Message-ID: Subject: Another Darwin build fix To: gdb-patches@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 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: 2012-02/txt/msg00087.txt.bz2 The system default gcc on 10.6.8 hits an uninitialized value warning which causes the build to fail. Cheers, Josh diff --git a/gdb/ChangeLog b/gdb/ChangeLog index f85f139..73803fd 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2012-02-07 Josh Matthews (tiny change) + + Fix build error in Darwin port. + * machoread.c: Initialize nbr_syms to avoid warnings-as-errors failure. + 2012-02-07 Tom Tromey * charset.c (find_charset_names): Check 'in' against NULL. diff --git a/gdb/machoread.c b/gdb/machoread.c index 9fa97e1..88ce612 100644 --- a/gdb/machoread.c +++ b/gdb/machoread.c @@ -180,7 +180,7 @@ macho_symtab_read (struct objfile *objfile, const asymbol *dir_so = NULL; const asymbol *file_so = NULL; asymbol **oso_file = NULL; - unsigned int nbr_syms; + unsigned int nbr_syms = 0; /* Current state while reading stabs. */ enum