1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

Add HTTP responses to FileTransferErrors

This commit is contained in:
Carlo Nucera 2020-06-16 15:14:11 -04:00 committed by John Ericson
parent a835c740ca
commit 004570a377
2 changed files with 23 additions and 8 deletions

View file

@ -103,9 +103,10 @@ class FileTransferError : public Error
{
public:
FileTransfer::Error error;
std::shared_ptr<string> response; // intentionally optional
template<typename... Args>
FileTransferError(FileTransfer::Error error, const Args & ... args)
: Error(args...), error(error)
FileTransferError(FileTransfer::Error error, std::shared_ptr<string> response, const Args & ... args)
: Error(args...), error(error), response(response)
{ }
};