summaryrefslogtreecommitdiff
path: root/module/sxml
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2013-01-27 21:53:49 +0100
committerAndy Wingo <wingo@pobox.com>2013-01-27 21:53:49 +0100
commit2b6fcf5b1f6f3cf8d94cada4f00885b275f1a7c5 (patch)
treedf36d44f2070069470cc8a232f88c0e09bfe8b68 /module/sxml
parent25645a0ac9158916667588b76cd541ee9dc05132 (diff)
downloadguile-2b6fcf5b1f6f3cf8d94cada4f00885b275f1a7c5.tar.gz
current-ssax-error-port is a parameter
* module/sxml/ssax.scm (current-ssax-error-port): Change to be a parameter.
Diffstat (limited to 'module/sxml')
-rw-r--r--module/sxml/ssax.scm12
1 files changed, 7 insertions, 5 deletions
diff --git a/module/sxml/ssax.scm b/module/sxml/ssax.scm
index a4de0e3e1..474247ba6 100644
--- a/module/sxml/ssax.scm
+++ b/module/sxml/ssax.scm
@@ -1,6 +1,6 @@
;;;; (sxml ssax) -- the SSAX parser
;;;;
-;;;; Copyright (C) 2009, 2010,2012 Free Software Foundation, Inc.
+;;;; Copyright (C) 2009, 2010,2012,2013 Free Software Foundation, Inc.
;;;; Modified 2004 by Andy Wingo <wingo at pobox dot com>.
;;;; Written 2001,2002,2003,2004 by Oleg Kiselyov <oleg at pobox dot com> as SSAX.scm.
;;;;
@@ -170,12 +170,14 @@
(define ascii->char integer->char)
(define char->ascii char->integer)
-(define *current-ssax-error-port* (make-fluid))
-(define (current-ssax-error-port)
- (fluid-ref *current-ssax-error-port*))
+(define current-ssax-error-port
+ (make-parameter (current-error-port)))
+
+(define *current-ssax-error-port*
+ (parameter-fluid current-ssax-error-port))
(define (with-ssax-error-to-port port thunk)
- (with-fluids ((*current-ssax-error-port* port))
+ (parameterize ((current-ssax-error-port port))
(thunk)))
(define (ssax:warn port msg . args)