mirror of
https://github.com/NixOS/nix
synced 2025-07-06 09:11:47 +02:00
Print a more helpful message if the daemon crashes
Instead of error: unexpected end-of-file you now get error: Nix daemon disconnected unexpectedly (maybe it crashed?)
This commit is contained in:
parent
b5ed36e663
commit
a3cf27ca47
3 changed files with 5 additions and 3 deletions
|
@ -153,12 +153,13 @@ struct FdSource : BufferedSource
|
|||
{
|
||||
int fd;
|
||||
size_t read = 0;
|
||||
std::string endOfFileError{"unexpected end-of-file"};
|
||||
|
||||
FdSource() : fd(-1) { }
|
||||
FdSource(int fd) : fd(fd) { }
|
||||
FdSource(FdSource&&) = default;
|
||||
FdSource(FdSource &&) = default;
|
||||
|
||||
FdSource& operator=(FdSource && s)
|
||||
FdSource & operator=(FdSource && s)
|
||||
{
|
||||
fd = s.fd;
|
||||
s.fd = -1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue