Function: network-stream-get-response

network-stream-get-response is a byte-compiled function defined in network-stream.el.gz.

Signature

(network-stream-get-response STREAM START END-OF-COMMAND)

Source Code

;; Defined in /usr/src/emacs/lisp/net/network-stream.el.gz
(defun network-stream-get-response (stream start end-of-command)
  (when end-of-command
    (with-current-buffer (process-buffer stream)
      (save-excursion
	(goto-char start)
	(while (and (memq (process-status stream) '(open run))
		    (not (re-search-forward end-of-command nil t)))
	  (accept-process-output stream 0.05)
	  (goto-char start))
	;; Return the data we got back, or nil if the process died.
	(unless (= start (point))
	  (buffer-substring start (point)))))))