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

Adjust FileTransferError message to use opt response

This commit is contained in:
John Ericson 2020-06-18 14:48:45 +00:00
parent 004570a377
commit 74b219ef6e
3 changed files with 17 additions and 5 deletions

View file

@ -104,10 +104,11 @@ class FileTransferError : public Error
public:
FileTransfer::Error error;
std::shared_ptr<string> response; // intentionally optional
template<typename... Args>
FileTransferError(FileTransfer::Error error, std::shared_ptr<string> response, const Args & ... args)
: Error(args...), error(error), response(response)
{ }
FileTransferError(FileTransfer::Error error, std::shared_ptr<string> response, const Args & ... args);
virtual const char* sname() const override { return "FileTransferError"; }
};
bool isUri(const string & s);