From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7700 invoked by alias); 24 Feb 2014 07:10:42 -0000 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 Received: (qmail 7686 invoked by uid 89); 24 Feb 2014 07:10:41 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_WEB,SPF_PASS autolearn=no version=3.3.2 X-HELO: mail-pd0-f173.google.com Received: from mail-pd0-f173.google.com (HELO mail-pd0-f173.google.com) (209.85.192.173) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Mon, 24 Feb 2014 07:10:40 +0000 Received: by mail-pd0-f173.google.com with SMTP id z10so727873pdj.18 for ; Sun, 23 Feb 2014 23:10:39 -0800 (PST) X-Received: by 10.66.221.199 with SMTP id qg7mr23539176pac.88.1393225838920; Sun, 23 Feb 2014 23:10:38 -0800 (PST) Received: from [192.168.1.105] ([120.199.57.179]) by mx.google.com with ESMTPSA id ei4sm46782257pbb.42.2014.02.23.23.10.36 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 23 Feb 2014 23:10:38 -0800 (PST) Message-ID: <530AF067.1010002@gmail.com> Date: Mon, 24 Feb 2014 07:10:00 -0000 From: asmwarrior User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.0 MIME-Version: 1.0 To: Yao Qi CC: gdb-patches@sourceware.org Subject: Re: [Windows]Fix a bug which cause GDB.exe assert when try to run the inferior References: <530612A8.4000903@gmail.com> <5306A9BC.4080701@codesourcery.com> <5306EE2A.2060103@gmail.com> <5306FA43.1070408@codesourcery.com> <83sirc532m.fsf@gnu.org> <530706DD.8060605@codesourcery.com> <530AEA6C.8050002@codesourcery.com> In-Reply-To: <530AEA6C.8050002@codesourcery.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SW-Source: 2014-02/txt/msg00720.txt.bz2 On 2014-2-24 14:45, Yao Qi wrote: > > > > gdb: > > > > 2014-02-21 Yuanhui Zhang > > > > * windows-nat.c (windows_xfer_shared_libraries): Return > > TARGET_XFER_EOF if LEN is zero to fix an assert failure when > > requested object is TARGET_OBJECT_LIBRARIES. > > > Please update your patch to replace "len ?" with "len != 0 ?" and commit > log we discussed here. You can push it in. > > Let me know if you don't have a commit access or have trouble on > committing, I can commit this patch for you. Hi, Yao, thanks. I was thinking that I won't need further change, because it was a tiny patch. Anyway, would you mind to commit for me? I don't have commit access. gdb/windows-nat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdb/windows-nat.c b/gdb/windows-nat.c index a570a1a..b76d94d 100644 --- a/gdb/windows-nat.c +++ b/gdb/windows-nat.c @@ -2480,7 +2480,7 @@ windows_xfer_shared_libraries (struct target_ops *ops, obstack_free (&obstack, NULL); *xfered_len = (ULONGEST) len; - return TARGET_XFER_OK; + return len != 0 ? TARGET_XFER_OK : TARGET_XFER_EOF; } The log message are much better than my original one. gdb: 2014-02-21 Yuanhui Zhang * windows-nat.c (windows_xfer_shared_libraries): Return TARGET_XFER_EOF if LEN is zero to fix an assert failure when requested object is TARGET_OBJECT_LIBRARIES. Thanks for adjustment. Yuanhui Zhang