GNU bug report logs -
#27963
[PATCH] Remove custom version parsing in epg-config.el
Previous Next
Reported by: npostavs <at> users.sourceforge.net
Date: Sat, 5 Aug 2017 02:44:02 UTC
Severity: wishlist
Tags: fixed, patch
Fixed in version 26.1
Done: npostavs <at> users.sourceforge.net
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 27963 in the body.
You can then email your comments to 27963 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
ueno <at> gnu.org, bug-gnu-emacs <at> gnu.org
:
bug#27963
; Package
emacs
.
(Sat, 05 Aug 2017 02:44:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
npostavs <at> users.sourceforge.net
:
New bug report received and forwarded. Copy sent to
ueno <at> gnu.org, bug-gnu-emacs <at> gnu.org
.
(Sat, 05 Aug 2017 02:44:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Severity: wishlist
Tags: patch
[0001-Remove-custom-version-parsing-functions-from-epg-con.patch (text/x-diff, inline)]
From 9415fb046b260cfdb1f87aa396f652d916abd71e Mon Sep 17 00:00:00 2001
From: Noam Postavsky <npostavs <at> gmail.com>
Date: Sat, 22 Jul 2017 23:54:34 -0400
Subject: [PATCH] Remove custom version parsing functions from epg-config.el
* lisp/epg-config.el (epg-config--compare-version)
(epg-config--parse-version): Remove.
(epg-check-configuration): Use `version<=' instead.
---
lisp/epg-config.el | 32 +++++++-------------------------
1 file changed, 7 insertions(+), 25 deletions(-)
diff --git a/lisp/epg-config.el b/lisp/epg-config.el
index 7b963add88..6aed354ca4 100644
--- a/lisp/epg-config.el
+++ b/lisp/epg-config.el
@@ -210,34 +210,16 @@ (defun epg-configuration ()
(declare (obsolete epg-find-configuration "25.1"))
(epg-config--make-gpg-configuration epg-gpg-program))
-(defun epg-config--parse-version (string)
- (let ((index 0)
- version)
- (while (eq index (string-match "\\([0-9]+\\)\\.?" string index))
- (setq version (cons (string-to-number (match-string 1 string))
- version)
- index (match-end 0)))
- (nreverse version)))
-
-(defun epg-config--compare-version (v1 v2)
- (while (and v1 v2 (= (car v1) (car v2)))
- (setq v1 (cdr v1) v2 (cdr v2)))
- (- (or (car v1) 0) (or (car v2) 0)))
-
;;;###autoload
(defun epg-check-configuration (config &optional minimum-version)
"Verify that a sufficient version of GnuPG is installed."
- (let ((entry (assq 'version config))
- version)
- (unless (and entry
- (stringp (cdr entry)))
- (error "Undetermined version: %S" entry))
- (setq version (epg-config--parse-version (cdr entry))
- minimum-version (epg-config--parse-version
- (or minimum-version
- epg-gpg-minimum-version)))
- (unless (>= (epg-config--compare-version version minimum-version) 0)
- (error "Unsupported version: %s" (cdr entry)))))
+ (let ((version (alist-get 'version config)))
+ (unless (stringp version)
+ (error "Undetermined version: %S" version))
+ (unless (version<= (or minimum-version
+ epg-gpg-minimum-version)
+ version)
+ (error "Unsupported version: %s" version))))
;;;###autoload
(defun epg-expand-group (config group)
--
2.11.1
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#27963
; Package
emacs
.
(Fri, 18 Aug 2017 00:55:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 27963 <at> debbugs.gnu.org (full text, mbox):
tags 27963 fixed
close 27963 26.1
quit
Pushed to master.
[1: cb7aa6c4a3]: 2017-08-17 20:51:39 -0400
Remove custom version parsing from epg-config.el (Bug#27963)
http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=cb7aa6c4a33debd4e0b72e00f846df92f395a181
Added tag(s) fixed.
Request was from
npostavs <at> users.sourceforge.net
to
control <at> debbugs.gnu.org
.
(Fri, 18 Aug 2017 00:55:02 GMT)
Full text and
rfc822 format available.
bug marked as fixed in version 26.1, send any further explanations to
27963 <at> debbugs.gnu.org and npostavs <at> users.sourceforge.net
Request was from
npostavs <at> users.sourceforge.net
to
control <at> debbugs.gnu.org
.
(Fri, 18 Aug 2017 00:55:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 15 Sep 2017 11:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 283 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.