summaryrefslogtreecommitdiff
path: root/lisp/mail
diff options
context:
space:
mode:
authorEli Zaretskii <eliz@gnu.org>2018-09-07 17:41:21 +0300
committerEli Zaretskii <eliz@gnu.org>2018-09-07 17:41:21 +0300
commit752a05b17dfb1bfb27867f1cf3a7548dbb570d26 (patch)
treef487433532dac5062cd7834aa21582d02428605f /lisp/mail
parent2c8520e19c0fe72d046033e39953b7a0a87be24e (diff)
downloademacs-752a05b17dfb1bfb27867f1cf3a7548dbb570d26.tar.gz
Read Windows OS info for report-emacs-bug from Registry
* lisp/w32-fns.el (w32--os-description): New function. * lisp/mail/emacsbug.el (report-emacs-bug--os-description): Use 'w32--os-description' instead of launching the 'systeminfo' program, which can be very slow, and is also missing on versions of Windows before XP Professional.
Diffstat (limited to 'lisp/mail')
-rw-r--r--lisp/mail/emacsbug.el17
1 files changed, 1 insertions, 16 deletions
diff --git a/lisp/mail/emacsbug.el b/lisp/mail/emacsbug.el
index 92b005d47d2..8cacad8726d 100644
--- a/lisp/mail/emacsbug.el
+++ b/lisp/mail/emacsbug.el
@@ -134,22 +134,7 @@ This requires either the macOS \"open\" command, or the freedesktop
os))
((eq system-type 'windows-nt)
(or report-emacs-bug--os-description
- (setq
- report-emacs-bug--os-description
- (let (os)
- (with-temp-buffer
- ;; Seems like this command can be slow, because it
- ;; unconditionally queries a bunch of other stuff
- ;; we don't care about.
- (when (eq 0 (ignore-errors
- (call-process "systeminfo" nil '(t nil) nil)))
- (dolist (s '("OS Name" "OS Version"))
- (goto-char (point-min))
- (if (re-search-forward
- (format "^%s\\s-*:\\s-+\\(.*\\)$" s)
- nil t)
- (setq os (concat os " " (match-string 1)))))))
- os))))
+ (setq report-emacs-bug--os-description (w32--os-description))))
((eq system-type 'berkeley-unix)
(with-temp-buffer
(when