1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-27 04:21:16 +02:00

nix-build, nix-shell: Don't print error message if nix-store/nix-instantiate fails

This commit is contained in:
Eelco Dolstra 2016-09-21 16:21:47 +02:00
parent c55bf085eb
commit 4546be1b3e
3 changed files with 39 additions and 6 deletions

View file

@ -247,7 +247,16 @@ pid_t startProcess(std::function<void()> fun, const ProcessOptions & options = P
string runProgram(Path program, bool searchPath = false,
const Strings & args = Strings(), const string & input = "");
MakeError(ExecError, Error)
class ExecError : public Error
{
public:
int status;
template<typename... Args>
ExecError(int status, Args... args)
: Error(args...), status(status)
{ }
};
/* Convert a list of strings to a null-terminated vector of char
*'s. The result must not be accessed beyond the lifetime of the