diff options
author | Marius Bakke <mbakke@fastmail.com> | 2016-12-04 17:41:36 +0100 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2016-12-04 17:41:36 +0100 |
commit | a351fc83694f436c3bff7cbdef09bd3cc91c74fc (patch) | |
tree | 646145378742a6943d7c4dda995fc0fb67f9db32 /nix | |
parent | 80b63e670ef4fe1fd40a903bcd4ee47a11415bd9 (diff) | |
parent | d1a5b20081c30da7503201df260cf20b8d0ba633 (diff) | |
download | guix-a351fc83694f436c3bff7cbdef09bd3cc91c74fc.tar guix-a351fc83694f436c3bff7cbdef09bd3cc91c74fc.tar.gz |
Merge branch 'master' into staging
Diffstat (limited to 'nix')
-rw-r--r-- | nix/nix-daemon/nix-daemon.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/nix/nix-daemon/nix-daemon.cc b/nix/nix-daemon/nix-daemon.cc index 9b29b3e91d..682f9a2b5b 100644 --- a/nix/nix-daemon/nix-daemon.cc +++ b/nix/nix-daemon/nix-daemon.cc @@ -203,11 +203,11 @@ static void stopWork(bool success = true, const string & msg = "", unsigned int } -struct TunnelSink : Sink +struct TunnelSink : BufferedSink { Sink & to; - TunnelSink(Sink & to) : to(to) { } - virtual void operator () (const unsigned char * data, size_t len) + TunnelSink(Sink & to) : BufferedSink(64 * 1024), to(to) { } + virtual void write(const unsigned char * data, size_t len) { writeInt(STDERR_WRITE, to); writeString(data, len, to); @@ -433,6 +433,7 @@ static void performOp(bool trusted, unsigned int clientVersion, startWork(); TunnelSink sink(to); store->exportPath(path, sign, sink); + sink.flush(); stopWork(); writeInt(1, to); break; |