guix-devel/nix
Jan Nieuwenhuizen 2e009ae7cd
daemon: Flush the sink upon 'exportPath' errors.
Prior to this change, errors such as wrong permissions on
/etc/guix/signing-key.sec would give:

  guix-daemon: nix/libutil/serialise.cc:15: virtual nix::BufferedSink::~BufferedSink(): Assertion `!bufPos' failed.

This patch correctly propagates the error to the client and thus changes
that to:

  error: build failed: file `/etc/guix/signing-key.sec' should be secret (inaccessible to everybody else)!

* nix/nix-daemon/nix-daemon.cc (performOp): Wrap 'exportPath' call in
'try' block.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
2017-07-17 15:13:41 +02:00
..
boost Merge branch 'nix' into 'master'. 2014-12-19 22:47:37 +01:00
guix-register guix-register: Use C++11 range 'for' loop instead of 'foreach' macro. 2015-06-10 13:55:23 +02:00
libstore daemon: Report hash mismatches in a cleaner way. 2017-05-30 18:08:37 +02:00
libutil daemon: Remove unused XML output code. 2016-05-31 18:22:14 +02:00
nix-daemon daemon: Flush the sink upon 'exportPath' errors. 2017-07-17 15:13:41 +02:00
scripts list-runtime-roots: Bufferize the lsof pipe. 2017-03-08 23:42:53 +01:00
.gitignore build: Include a copy of Nix's libstore and daemon; build it. 2012-12-03 23:05:08 +01:00
AUTHORS Merge branch 'nix' into 'master'. 2014-12-19 22:47:37 +01:00
COPYING Merge branch 'nix' into 'master'. 2014-12-19 22:47:37 +01:00
local.mk build: Don't embed absolute paths in .service and .conf service files. 2017-03-06 13:25:51 -05:00