From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31821 invoked by alias); 17 Jul 2008 21:57:30 -0000 Received: (qmail 31804 invoked by uid 22791); 17 Jul 2008 21:57:27 -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 21:57:10 +0000 Received: from zps37.corp.google.com (zps37.corp.google.com [172.25.146.37]) by smtp-out.google.com with ESMTP id m6HLv4hu003334 for ; Thu, 17 Jul 2008 22:57:05 +0100 Received: from qw-out-2122.google.com (qwb9.prod.google.com [10.241.193.73]) by zps37.corp.google.com with ESMTP id m6HLuFUL012801 for ; Thu, 17 Jul 2008 14:57:04 -0700 Received: by qw-out-2122.google.com with SMTP id 9so118136qwb.23 for ; Thu, 17 Jul 2008 14:57:03 -0700 (PDT) Received: by 10.151.11.19 with SMTP id o19mr1163365ybi.78.1216331823620; Thu, 17 Jul 2008 14:57:03 -0700 (PDT) Received: by 10.151.109.14 with HTTP; Thu, 17 Jul 2008 14:57:03 -0700 (PDT) Message-ID: <8ac60eac0807171457g4f2c972es883f7210c7843a87@mail.gmail.com> Date: Thu, 17 Jul 2008 21:57:00 -0000 From: "Paul Pluzhnikov" To: "Paul Pluzhnikov" , gdb-patches@sourceware.org Subject: Re: [RFC] Detect loops in the solib chain In-Reply-To: <20080717214039.GA21465@caradoc.them.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20080717205721.GA19882@caradoc.them.org> <8ac60eac0807171417h37cbe7d4x860d528d80358c8e@mail.gmail.com> <20080717214039.GA21465@caradoc.them.org> 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/msg00354.txt.bz2 On Thu, Jul 17, 2008 at 2:40 PM, Daniel Jacobowitz wrote: > @@ -784,14 +792,21 @@ svr4_current_sos (void) > > read_memory (lm, new->lm_info->lm, lmo->link_map_size); > > - lm = LM_NEXT (new); > + next_lm = LM_NEXT (new); > + > + if (prev_lm != 0 && LM_PREV (new) != prev_lm && ldsomap == 0) I think you want just: + if (LM_PREV (new) != prev_lm) First entry on the list should also be properly terminated, and ldsomap has nothing to do with whether the list is corrupt or not. -- Paul Pluzhnikov