comparison lisp/process.el @ 1189:23eaac87b4b0

[xemacs-hg @ 2003-01-05 18:38:36 by daiki] 2002-12-17 Daiki Ueno <daiki@xemacs.org> * process.el (shell-command-to-string): Synch with GNU Emacs 21.
author daiki
date Sun, 05 Jan 2003 18:38:37 +0000
parents eaedf30d9d76
children 35aac3cef6af
comparison
equal deleted inserted replaced
1188:11ff4edb6bb7 1189:23eaac87b4b0
510 (concat result (substring argument start)))))) 510 (concat result (substring argument start))))))
511 511
512 (defun shell-command-to-string (command) 512 (defun shell-command-to-string (command)
513 "Execute shell command COMMAND and return its output as a string." 513 "Execute shell command COMMAND and return its output as a string."
514 (with-output-to-string 514 (with-output-to-string
515 (call-process shell-file-name nil t nil shell-command-switch command))) 515 (with-current-buffer standard-output
516 (call-process shell-file-name nil t nil shell-command-switch command))))
516 517
517 (defalias 'exec-to-string 'shell-command-to-string) 518 (defalias 'exec-to-string 'shell-command-to-string)
518 519
519 520
520 ;; History list for environment variable names. 521 ;; History list for environment variable names.