diff --git a/guix/profiles.scm b/guix/profiles.scm index 9dc9ab43b9..aa88b849e1 100644 --- a/guix/profiles.scm +++ b/guix/profiles.scm @@ -321,10 +321,10 @@ (define (right-arrow port) (let ((arrow "→")) (catch 'encoding-error (lambda () - (with-fluids ((%default-port-conversion-strategy 'error)) - (with-output-to-string - (lambda () - (display arrow))))) + (call-with-output-string + (lambda (port) + (set-port-conversion-strategy! port 'error) + (display arrow port)))) (lambda (key . args) "->")))))