From patchwork Thu Jun 22 18:52:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergio Durigan Junior X-Patchwork-Id: 21207 Received: (qmail 22641 invoked by alias); 22 Jun 2017 18:52:25 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 22570 invoked by uid 89); 22 Jun 2017 18:52:21 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, SPF_HELO_PASS, T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 spammy=Hx-languages-length:1246 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 22 Jun 2017 18:52:19 +0000 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7708A7F413 for ; Thu, 22 Jun 2017 18:52:18 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 7708A7F413 Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=sergiodj@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 7708A7F413 Received: from psique.yyz.redhat.com (unused-10-15-17-193.yyz.redhat.com [10.15.17.193]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8923D5D966; Thu, 22 Jun 2017 18:52:16 +0000 (UTC) From: Sergio Durigan Junior To: GDB Patches Cc: Sergio Durigan Junior Subject: [commit/obvious] Update comment on gdb_environ::unset Date: Thu, 22 Jun 2017 14:52:13 -0400 Message-Id: <20170622185213.12474-1-sergiodj@redhat.com> X-IsSubscribed: yes gdb_environ::unset iterates using '.end () - 1' now, instead of '.cend () - 1'. This obvious patch updates the comment. gdb/ChangeLog: 2017-06-22 Sergio Durigan Junior * common/environ.c (gdb_environ::unset): Update comment. --- gdb/ChangeLog | 4 ++++ gdb/common/environ.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index bf9e08d..95010fc 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2017-06-22 Sergio Durigan Junior + + * common/environ.c (gdb_environ::unset): Update comment. + 2017-06-22 Alan Hayward * python/py-unwind.c (pyuw_sniffer): Allocate space for diff --git a/gdb/common/environ.c b/gdb/common/environ.c index 2d13957..698bda3 100644 --- a/gdb/common/environ.c +++ b/gdb/common/environ.c @@ -114,7 +114,7 @@ gdb_environ::unset (const char *var) { size_t len = strlen (var); - /* We iterate until '.cend () - 1' because the last element is + /* We iterate until '.end () - 1' because the last element is always NULL. */ for (std::vector::iterator el = m_environ_vector.begin (); el != m_environ_vector.end () - 1;