]> code.delx.au - gnu-emacs/blobdiff - lisp/env.el
* env.el (getenv): When FRAME is non-nil, pass the frame environment
[gnu-emacs] / lisp / env.el
index 8d8bebe09ba20aa24a79790b0cf7d9091efb0588..33d5545edae50625a0366149b75dea4cf17f1908 100644 (file)
@@ -198,7 +198,9 @@ in the environment list of the selected frame."
                                    (encode-coding-string
                                     variable locale-coding-system)
                                  variable)
-                               frame)))
+                               (and frame
+                                    (assq 'environment
+                                          (frame-parameters frame))))))
     (if (and enable-multibyte-characters value)
        (setq value (decode-coding-string value locale-coding-system)))
     (when (interactive-p)