From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24131 invoked by alias); 26 Sep 2002 05:10:32 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 24124 invoked from network); 26 Sep 2002 05:10:32 -0000 Received: from unknown (HELO satan.diablo.localnet) (64.164.47.8) by sources.redhat.com with SMTP; 26 Sep 2002 05:10:32 -0000 Received: from p by satan.diablo.localnet with local (Exim 3.35 #1 (Debian)) id 17uQv1-0006Q9-00 for ; Wed, 25 Sep 2002 22:10:31 -0700 Date: Wed, 25 Sep 2002 22:10:00 -0000 To: Gdb Mailing List Subject: rules for conditional breakpoints Message-ID: <20020926051031.GA24523@dirac.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i From: Peter Jay Salzman X-SW-Source: 2002-09/txt/msg00423.txt.bz2 hi all, what exactly are the rules for conditional breakpoints? clearly the condition can use the standard boolean operators, along with the logical qualifiers: break main if i > 3 break test.c:3 if i !=0 && j <=0 but libc functions linked to the code also seem to work: break 40 if *(string + strlen(string)) != '\0' from a previous email i sent to this list, i gather that strlen() works "by accident", and only functions that return an int work. so this won't work, even with typecasting: break 1 if (double)cos(0) == 1.0L so, this seems to be the rule for conditional breakpoints: 1. equality/inequality operators. ie: <, >, <=, >= 2. logic operators. ie: &&, || 3. libc functions linked to code but ONLY if they return an int. ie: strlen(), abs() is this correct? thanks! pete -- Fingerprint: B9F1 6CF3 47C4 7CD8 D33E 70A9 A3B9 1945 67EA 951D