Replaced call-process-region with start-file-process and wait.
call-process-region doesn't work with remote tramp directories. Staging of diff hunks was broken.
This commit is contained in:
parent
a291507171
commit
37731ad567
1 changed files with 10 additions and 3 deletions
13
magit.el
13
magit.el
|
@ -1057,10 +1057,17 @@ Many Magit faces inherit from this one by default."
|
|||
(input
|
||||
(with-current-buffer input
|
||||
(setq default-directory dir)
|
||||
(setq magit-process
|
||||
(apply 'start-file-process cmd buf cmd args))
|
||||
(set-process-filter magit-process 'magit-process-filter)
|
||||
(process-send-region magit-process
|
||||
(point-min) (point-max))
|
||||
(process-send-eof magit-process)
|
||||
(while (equal (process-status magit-process) 'run)
|
||||
(sit-for 0.1 t))
|
||||
(setq successp
|
||||
(equal (apply 'call-process-region
|
||||
(point-min) (point-max)
|
||||
cmd nil buf nil args) 0)))
|
||||
(equal (process-exit-status magit-process) 0))
|
||||
(setq magit-process nil))
|
||||
(magit-set-mode-line-process nil)
|
||||
(magit-need-refresh magit-process-client-buffer))
|
||||
(t
|
||||
|
|
Loading…
Reference in a new issue