From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22188 invoked by alias); 22 Jul 2009 19:34:59 -0000 Received: (qmail 22178 invoked by uid 22791); 22 Jul 2009 19:34:58 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00,SPF_PASS 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.43rc1) with ESMTP; Wed, 22 Jul 2009 19:34:52 +0000 Received: from zps75.corp.google.com (zps75.corp.google.com [172.25.146.75]) by smtp-out.google.com with ESMTP id n6MJYk1q014355; Wed, 22 Jul 2009 20:34:46 +0100 Received: from localhost (ppluzhnikov.mtv.corp.google.com [172.18.118.92]) by zps75.corp.google.com with ESMTP id n6MJYgqm022416; Wed, 22 Jul 2009 12:34:43 -0700 Received: by localhost (Postfix, from userid 74925) id C782A76BC0; Wed, 22 Jul 2009 12:34:42 -0700 (PDT) To: gdb-patches@sourceware.org Cc: Pedro Alves , ppluzhnikov@google.com Subject: [patch] Add missing observer_notify call. Message-Id: <20090722193442.C782A76BC0@localhost> Date: Wed, 22 Jul 2009 20:15: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: 2009-07/txt/msg00567.txt.bz2 Greetings, In http://sourceware.org/ml/gdb-patches/2009-07/msg00553.html Pedro noticed that a new objfile may be created without notifying new_objfile observer. Here is a fix. Tested on Linux/x86_64 with no new failures. Thanks, -- Paul Pluzhnikov 2009-07-22 Paul Pluzhnikov * symfile.c (symbol_file_add_with_addrs_or_offsets): Call observer. Index: symfile.c =================================================================== RCS file: /cvs/src/src/gdb/symfile.c,v retrieving revision 1.238 diff -u -p -u -r1.238 symfile.c --- symfile.c 22 Jul 2009 19:21:31 -0000 1.238 +++ symfile.c 22 Jul 2009 19:26:12 -0000 @@ -1080,7 +1080,10 @@ symbol_file_add_with_addrs_or_offsets (b do_cleanups (my_cleanups); if (objfile->sf == NULL) - return objfile; /* No symbols. */ + { + observer_notify_new_objfile (objfile); + return objfile; /* No symbols. */ + } new_symfile_objfile (objfile, add_flags);