GNU bug report logs -
#2259
23.0.90; PATCH: getenv mistakenly passes a frame to getenv_internal, when it should instead pass a CONS
Previous Next
Reported by: Eric Hanchrow <eric.hanchrow <at> gmail.com>
Date: Tue, 10 Feb 2009 03:45:02 UTC
Severity: normal
Tags: patch
Done: Juanma Barranquero <lekktu <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
On Tue, Feb 10, 2009 at 11:24, Juanma Barranquero <lekktu <at> gmail.com> wrote:
> or it
> is known at that point that the ENV arg of `server-with-environment'
> will never contain negative entries (i.e., can the output of
> (process-get process 'env) contain negative entries)? If it is
> intended, perhaps a comment would be in order.
OK, I see now that "ENV should be in the same format as
`process-environment'", and that, in `process-environment', "[e]ach
element should be a string of the form ENVVARNAME=VALUE". So yes, it
is known that there shouldn't be negative entries, and it is even
documented.
Still, perhaps this change would be useful...
Juanma
Index: server.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/server.el,v
retrieving revision 1.188
diff -u -2 -r1.188 server.el
--- server.el 7 Feb 2009 21:59:35 -0000 1.188
+++ server.el 10 Feb 2009 15:55:04 -0000
@@ -241,7 +241,7 @@
(dolist (,var ,vars)
(let ((,value (getenv-internal ,var ,env)))
- (push (if (null ,value)
- ,var
- (concat ,var "=" ,value))
+ (push (if (stringp ,value)
+ (concat ,var "=" ,value)
+ ,var)
process-environment)))
(progn ,@body))))
This bug report was last modified 16 years and 163 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.