From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 112874 invoked by alias); 28 Feb 2020 20:01:17 -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 112865 invoked by uid 89); 28 Feb 2020 20:01:16 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-4.2 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=Mar, H*f:sk:ceb6741, H*i:sk:ceb6741 X-HELO: us-smtp-delivery-1.mimecast.com Received: from us-smtp-2.mimecast.com (HELO us-smtp-delivery-1.mimecast.com) (207.211.31.81) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 28 Feb 2020 20:01:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1582920073; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QwPH+NcpF3Gj/F/g2oG1xeCzVdpN1Y5qBvn7zOxFG1s=; b=e6xyYDidAyFmCe3YpKmm+WKQFY4euMm18TuBnqBGbdQL1uJ1JGbQkyzmW7rpnITPChHJLg A6grVflrCfSiq46wEkMjn/NBGQGkSabxQc8Hcez4Ns3lmgM+/T2gYi82oVQ8PhIcf42lFo nV4WwtZJSzAb5c4JcNq4gWn0OY638SQ= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-103-qk-6Ls7pMwuZxVeApkhWvA-1; Fri, 28 Feb 2020 15:01:11 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 7067F13FC; Fri, 28 Feb 2020 20:01:10 +0000 (UTC) Received: from localhost (unused-10-15-17-54.yyz.redhat.com [10.15.17.54]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3233F60C18; Fri, 28 Feb 2020 20:01:10 +0000 (UTC) From: Sergio Durigan Junior To: Pedro Alves Cc: GDB Patches , Tom Tromey , Eli Zaretskii , Ruslan Kabatsayev Subject: Re: [PATCH 2/6] Don't reset errno/bfd_error on 'throw_perror_with_name' References: <20190926042155.31481-1-sergiodj@redhat.com> <20200226200542.746617-1-sergiodj@redhat.com> <20200226200542.746617-3-sergiodj@redhat.com> Date: Fri, 28 Feb 2020 20:01:00 -0000 In-Reply-To: (Pedro Alves's message of "Fri, 28 Feb 2020 19:49:02 +0000") Message-ID: <87o8tipjlm.fsf@redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2020-02/txt/msg01072.txt.bz2 On Friday, February 28 2020, Pedro Alves wrote: > On 2/26/20 8:05 PM, Sergio Durigan Junior wrote: >>=20 >> git blame tells me that this piece of code is pretty old; the commit >> that "introduced" it is: >>=20 >> commit c906108c21474dfb4ed285bcc0ac6fe02cd400cc >> Author: Stan Shebs >> Date: Fri Apr 16 01:35:26 1999 +0000 >>=20 >> Initial creation of sourceware repository >>=20 >> so yeah... > > This is not the oldest commit in the tree. Using git log > starting at the hash, you should be able to find older commits > which touch the file. The thing is that history around the time > of that "initial creation" commit, is quite messy, because the=20 > CVS tree back then was deleted and recreated a number of times > and merged in some odd ways. Sorry, I didn't mean to say that this is the oldest commit in the tree. But even doing a bit more search, I could only find this commit: commit 8eec331072987d38064745a33ae89cc5d195029c Author: Steve Chamberlain Date: Sat Mar 19 03:16:10 1994 +0000 * utils.c (prompt_for_continue): Call readline, not gdb_readl= ine. which did: - bfd_error =3D no_error; + bfd_set_error (bfd_error_no_error); This means the code is really old (pre-1994), and I could not track when it was added. And I don't think it matters much at this point: even if I could find the exact commit that added it, I doubt I'd be able to find the rationale. --=20 Sergio GPG key ID: 237A 54B1 0287 28BF 00EF 31F4 D0EB 7628 65FC 5E36 Please send encrypted e-mail if possible http://sergiodj.net/