[git] GnuPG - branch, master, updated. gnupg-2.1.18-94-gaab6ba0

by Justus Winter cvs at cvs.gnupg.org
Fri Feb 17 10:51:32 CET 2017


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".

The branch, master has been updated
       via  aab6ba0bb60528b9e816e430be51170cf39611b0 (commit)
      from  99d4dfe83661d05ef3a20ed04e6cec5647536738 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit aab6ba0bb60528b9e816e430be51170cf39611b0
Author: Justus Winter <justus at g10code.com>
Date:   Fri Feb 17 10:43:20 2017 +0100

    gpgscm: Guard use of tagged expressions.
    
    * tests/gpgscm/init.scm (vm-history-print): Check that the tag added
    to expressions when parsing source files matches the expected format.
    * tests/gpgscm/lib.scm (assert): Likewise.
    --
    
    This makes the error handling more robust.  We saw the assumption
    about the format of the tags being violated on one build system, and
    it obscured the view on the underlying problem.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/tests/gpgscm/init.scm b/tests/gpgscm/init.scm
index 83261b0..87d3c88 100644
--- a/tests/gpgscm/init.scm
+++ b/tests/gpgscm/init.scm
@@ -547,11 +547,11 @@
 	(display n)
 	(display ": ")
 	(let ((tag (get-tag f)))
-	  (unless (null? tag)
-		  (display (basename (car tag)))
-		  (display ":")
-		  (display (+ 1 (cdr tag)))
-		  (display ": ")))
+	  (when (and (pair? tag) (string? (car tag)) (number? (cdr tag)))
+		(display (basename (car tag)))
+		(display ":")
+		(display (+ 1 (cdr tag)))
+		(display ": ")))
 	(write f))
 	(newline)
 	(loop (+ n 1) skip (cdr frames))))))
diff --git a/tests/gpgscm/lib.scm b/tests/gpgscm/lib.scm
index 6959aa4..2cfe725 100644
--- a/tests/gpgscm/lib.scm
+++ b/tests/gpgscm/lib.scm
@@ -20,7 +20,7 @@
 (macro (assert form)
   (let ((tag (get-tag form)))
     `(if (not ,(cadr form))
-	 (throw ,(if (pair? tag)
+	 (throw ,(if (and (pair? tag) (string? (car tag)) (number? (cdr tag)))
 		     `(string-append ,(car tag) ":"
 				     ,(number->string (+ 1 (cdr tag)))
 				     ": Assertion failed: ")

-----------------------------------------------------------------------

Summary of changes:
 tests/gpgscm/init.scm | 10 +++++-----
 tests/gpgscm/lib.scm  |  2 +-
 2 files changed, 6 insertions(+), 6 deletions(-)


hooks/post-receive
-- 
The GNU Privacy Guard
http://git.gnupg.org




More information about the Gnupg-commits mailing list