[Pkg-gnupg-commit] [gnupg2] 117/132: gpgscm: Make it possible to set the logfile name.

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed May 17 03:07:48 UTC 2017


This is an automated email from the git hooks/post-receive script.

dkg pushed a commit to branch experimental
in repository gnupg2.

commit 29ef34cc4cb23e7b743dbf4cc8e5761f06076b9a
Author: Justus Winter <justus at g10code.com>
Date:   Thu May 11 14:44:33 2017 +0200

    gpgscm: Make it possible to set the logfile name.
    
    * tests/gpgscm/tests.scm (test): Only set the default log filename
    when it has not been set before.
    
    Signed-off-by: Justus Winter <justus at g10code.com>
---
 tests/gpgscm/tests.scm | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tests/gpgscm/tests.scm b/tests/gpgscm/tests.scm
index e5ec5c7..490f95a 100644
--- a/tests/gpgscm/tests.scm
+++ b/tests/gpgscm/tests.scm
@@ -615,7 +615,7 @@
 	(current-environment))
 
       ;; The log is written here.
-      (define log-file-name "not set")
+      (define log-file-name #f)
 
       ;; Record time stamps.
       (define timestamp #f)
@@ -629,7 +629,8 @@
 	(set! end-time (get-time)))
 
       (define (open-log-file)
-	(set! log-file-name (string-append (basename name) ".log"))
+	(unless log-file-name
+		(set! log-file-name (string-append (basename name) ".log")))
 	(catch '() (unlink log-file-name))
 	(open log-file-name (logior O_RDWR O_BINARY O_CREAT) #o600))
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg2.git



More information about the Pkg-gnupg-commit mailing list