From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Gabriel Beauchamp Newsgroups: gmane.emacs.bugs Subject: bug#32755: [PATCH] erc.el: Remove warning during compilation. Date: Mon, 17 Sep 2018 17:37:20 -0400 Message-ID: <87d0tbiz5b.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: blaine.gmane.org 1537220168 9405 195.159.176.226 (17 Sep 2018 21:36:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 17 Sep 2018 21:36:08 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) To: 32755@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Sep 17 23:36:04 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1g21Bc-0002Jr-9V for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Sep 2018 23:36:04 +0200 Original-Received: from localhost ([::1]:37459 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g21Di-0008Ie-RQ for geb-bug-gnu-emacs@m.gmane.org; Mon, 17 Sep 2018 17:38:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47791) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g21DZ-0008HF-Q8 for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:38:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1g21DW-0007AT-Hn for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:38:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:39176) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1g21DW-0007A7-BL for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:38:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1g21DW-0004KX-5H for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:38:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gabriel Beauchamp Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 17 Sep 2018 21:38:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 32755 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.153722026516618 (code B ref -1); Mon, 17 Sep 2018 21:38:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 17 Sep 2018 21:37:45 +0000 Original-Received: from localhost ([127.0.0.1]:43434 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1g21DF-0004Jy-1P for submit@debbugs.gnu.org; Mon, 17 Sep 2018 17:37:45 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:54737) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1g21DE-0004Jk-5F for submit@debbugs.gnu.org; Mon, 17 Sep 2018 17:37:44 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1g21D7-0006O6-RJ for submit@debbugs.gnu.org; Mon, 17 Sep 2018 17:37:38 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:40833) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1g21D7-0006NX-JO for submit@debbugs.gnu.org; Mon, 17 Sep 2018 17:37:37 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47446) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g21D6-0007l6-Gf for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:37:37 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1g21D3-0005uV-7M for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:37:36 -0400 Original-Received: from mail-qk1-x72c.google.com ([2607:f8b0:4864:20::72c]:40417) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1g21D2-0005Z0-LP for bug-gnu-emacs@gnu.org; Mon, 17 Sep 2018 17:37:32 -0400 Original-Received: by mail-qk1-x72c.google.com with SMTP id c126-v6so9862572qkd.7 for ; Mon, 17 Sep 2018 14:37:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:user-agent:mime-version; bh=9uMXYkZq7ZMqwI/7GrmQM2Tz75kZGfIPKNx3H+AfXPQ=; b=hNOq2FYwsVkli2ayQfg4g3FMeSVv7ZZSjUjSgm9ly6JfKjj7W+m0eN3PSMNM99YS5n c3mW7lmZ0WlvchheUugCy/RdBpWBFMwdLPI97hJXEAfgtRFDesVJCq9jmaaYiMO8thYA Gxnka/vs8/NterYK81c6qLr7HF6MjOOYIh2PomyFgTyHJNSed3x+S2Hbmy4KoUp3gmtW KHV9o3NqPPadiR9dyM9WkAtps2FYFLHyzkc6+9jIAiYt5WAcjKgjHJn9ffWTP3ziyfWS UiE4F8jY0c04u877Dqy12jVDgVpUrP+zhsZxAh6qiNHw0ENHZ3YfwegTjofbWULzt9YM GsBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:user-agent :mime-version; bh=9uMXYkZq7ZMqwI/7GrmQM2Tz75kZGfIPKNx3H+AfXPQ=; b=BRPhw3YGL6h/RwethXOvg9gdkypAGicac7+z5BxY8FZWxJ432LLrcNppyEenHm0rMs vE7tyoXTsEDWcSzEag6MeYtVD4MX50zvvNJpx8opz4YleJsy4sPAXGxQzmwz7Al7WBQ8 tDC1fWNJyKQaIRUSJ9ed5iUwWA0rQV98NLVLlt1JqLWCd8orBVBQfpl8YFC1p1KxgLJd DADuoVZ9DKGlxtJ2mg3O9+u+MUn8ARlSD24MXiqg2MrL1ts5vPNxdHzdOZd/aLzC2owg Quxvd3doX3a1rP9XB3AfTRU2JggwdJ1GGZ/raj699/ECg28nRJhutcUULUfAlyDkos+Z 6jdA== X-Gm-Message-State: APzg51DhYM7WmILL+jFcgzLLkFuGWMilOAXiRh0kkUrJ/ewmyZFbuDKX A/HvwFECVoVuOq1ATv2GB5Syodjencs= X-Google-Smtp-Source: ANB0VdbaqyAo2E6EqqjlDtMA57B5Kt5T4Fu+mxY/yME73Gp44s4YSZux9xNn0yeknw84vgrfcqWK9A== X-Received: by 2002:a37:1383:: with SMTP id 3-v6mr18123630qkt.129.1537220241035; Mon, 17 Sep 2018 14:37:21 -0700 (PDT) Original-Received: from g-ThinkPad-X230 ([206.167.112.182]) by smtp.gmail.com with ESMTPSA id o5-v6sm11788508qtc.63.2018.09.17.14.37.20 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 17 Sep 2018 14:37:20 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:150383 Archived-At: --=-=-= Content-Type: text/plain Hi, I have attached a patch that removes a warning during the compilation of erc. Tested with `emacs -Q -q' running on HEAD. Thanks, Gabriel --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-lisp-erc-erc.el-erc-handle-irc-url-Remove-warning-du.patch Content-Description: Remove warning during compilation >From cc6d9c0c83fb62172aec5456c1ae16f217478346 Mon Sep 17 00:00:00 2001 From: Gabriel Beauchamp Date: Mon, 17 Sep 2018 17:07:13 -0400 Subject: [PATCH] * lisp/erc/erc.el (erc-handle-irc-url): Remove warning during compilation. --- lisp/erc/erc.el | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index fc51009641..eb9082fa2f 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -5450,14 +5450,14 @@ erc-send-input (beep)) nil) (t - (defvar str) ;; FIXME: Make it obey the "erc-" prefix convention. - (let ((str input) + (defvar erc--str) + (let ((erc--str input) (erc-insert-this t)) (setq erc-send-this t) (run-hook-with-args 'erc-send-pre-hook input) (when erc-send-this - (if (or (string-match "\n" str) - (not (string-match erc-command-regexp str))) + (if (or (string-match "\n" erc--str) + (not (string-match erc-command-regexp erc--str))) (mapc (lambda (line) (mapc @@ -5468,8 +5468,8 @@ erc-send-input (null erc-flood-protect) t)) (or (and erc-flood-protect (erc-split-line line)) (list line)))) - (split-string str "\n")) - (erc-process-input-line (concat str "\n") t nil)) + (split-string erc--str "\n")) + (erc-process-input-line (concat erc--str "\n") t nil)) t))))) (defun erc-display-command (line) -- 2.17.1 --=-=-=--