mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
store: Work around 'get-bytevector-n' bug that affects 'import-paths'.
Fixes <http://bugs.gnu.org/17591>. * guix/store.scm (process-stderr) <%stderr-read>: Use 'get-bytevector-n!' instead of 'get-bytevector-n'.
This commit is contained in:
parent
2a7050abf8
commit
5895f24443
1 changed files with 5 additions and 3 deletions
|
@ -397,11 +397,13 @@ (define %stderr-error #x63787470) ; "cxtp", error reporting
|
||||||
#f)
|
#f)
|
||||||
((= k %stderr-read)
|
((= k %stderr-read)
|
||||||
;; Read a byte stream from USER-PORT.
|
;; Read a byte stream from USER-PORT.
|
||||||
|
;; Note: Avoid 'get-bytevector-n' to work around
|
||||||
|
;; <http://bugs.gnu.org/17591> in Guile up to 2.0.11.
|
||||||
(let* ((max-len (read-int p))
|
(let* ((max-len (read-int p))
|
||||||
(data (get-bytevector-n user-port max-len))
|
(data (make-bytevector max-len))
|
||||||
(len (bytevector-length data)))
|
(len (get-bytevector-n! user-port data 0 max-len)))
|
||||||
(write-int len p)
|
(write-int len p)
|
||||||
(put-bytevector p data)
|
(put-bytevector p data 0 len)
|
||||||
(write-padding len p)
|
(write-padding len p)
|
||||||
#f))
|
#f))
|
||||||
((= k %stderr-next)
|
((= k %stderr-next)
|
||||||
|
|
Loading…
Reference in a new issue