From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kelly Dean Newsgroups: gmane.emacs.bugs Subject: bug#19536: [PATCH] package-upload-buffer-internal fails for tar files Date: Thu, 08 Jan 2015 03:33:06 +0000 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: ger.gmane.org 1420688172 23657 80.91.229.3 (8 Jan 2015 03:36:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 8 Jan 2015 03:36:12 +0000 (UTC) To: 19536@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jan 08 04:36:06 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Y93sO-0006Zh-Kd for geb-bug-gnu-emacs@m.gmane.org; Thu, 08 Jan 2015 04:35:12 +0100 Original-Received: from localhost ([::1]:43894 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93sO-000268-1F for geb-bug-gnu-emacs@m.gmane.org; Wed, 07 Jan 2015 22:35:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54478) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93sJ-00024e-2J for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:35:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y93sE-0007dS-RJ for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:35:06 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:58584) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93sE-0007d4-Nh for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:35:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Y93sE-0005rU-H4 for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:35:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Kelly Dean Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 08 Jan 2015 03:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 19536 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.142068809322512 (code B ref -1); Thu, 08 Jan 2015 03:35:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 8 Jan 2015 03:34:53 +0000 Original-Received: from localhost ([127.0.0.1]:39717 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Y93s4-0005r2-L3 for submit@debbugs.gnu.org; Wed, 07 Jan 2015 22:34:52 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:52705) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Y93s2-0005qt-Rc for submit@debbugs.gnu.org; Wed, 07 Jan 2015 22:34:51 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y93s1-0007VR-QX for submit@debbugs.gnu.org; Wed, 07 Jan 2015 22:34:50 -0500 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:45806) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93s1-0007VM-MX for submit@debbugs.gnu.org; Wed, 07 Jan 2015 22:34:49 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54427) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93s0-00021x-Q2 for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:34:49 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y93rw-0007U9-LK for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:34:48 -0500 Original-Received: from relay6-d.mail.gandi.net ([2001:4b98:c:538::198]:33725) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y93rw-0007Th-GB for bug-gnu-emacs@gnu.org; Wed, 07 Jan 2015 22:34:44 -0500 Original-Received: from mfilter1-d.gandi.net (mfilter1-d.gandi.net [217.70.178.130]) by relay6-d.mail.gandi.net (Postfix) with ESMTP id 049A4FB882 for ; Thu, 8 Jan 2015 04:34:40 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at mfilter1-d.gandi.net Original-Received: from relay6-d.mail.gandi.net ([217.70.183.198]) by mfilter1-d.gandi.net (mfilter1-d.gandi.net [10.0.15.180]) (amavisd-new, port 10024) with ESMTP id d8QR1U1oOmys for ; Thu, 8 Jan 2015 04:34:08 +0100 (CET) X-Originating-IP: 162.248.99.114 Original-Received: from localhost (114-99-248-162-static.reverse.queryfoundry.net [162.248.99.114]) (Authenticated sender: kelly@prtime.org) by relay6-d.mail.gandi.net (Postfix) with ESMTPSA id 5A7B6FB887 for ; Thu, 8 Jan 2015 04:34:07 +0100 (CET) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:98103 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable It creates a file with a =E2=8C=9C.tar=E2=8C=9D extension that isn't a va= lid tar file. Since elpa.gnu.org _does_ have valid tar files, I guess somebody wrote a = script to work around this bug by overwriting the invalid tar files with = the originals. I'm submitting a patch for this since it affects validation of my patch f= or bug #19479, and I'm submitting the latter patch because it fixes a sec= urity vulnerability. --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=package-upload-bug.patch --- emacs-24.4/lisp/emacs-lisp/package-x.el +++ emacs-24.4/lisp/emacs-lisp/package-x.el @@ -243,7 +243,7 @@ (concat (symbol-name pkg-name) "-readme.txt") package-archive-upload-base))) - (set-buffer pkg-buffer) + (set-buffer (if (eq file-type 'tar) tar-data-buffer pkg-buffer)) (write-region (point-min) (point-max) (expand-file-name (format "%s-%s.%s" pkg-name pkg-version extension) --=-=-=--