mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 08:12:29 +00:00
Merge pull request #10328 from NixOS/backport-10325-to-2.21-maintenance
[Backport 2.21-maintenance] build-remote: fix format string shenanigans
This commit is contained in:
commit
3272ed0d58
@ -202,7 +202,7 @@ static int main_build_remote(int argc, char * * argv)
|
||||
else
|
||||
drvstr = "<unknown>";
|
||||
|
||||
auto error = HintFmt(errorText);
|
||||
auto error = HintFmt::fromFormatString(errorText);
|
||||
error
|
||||
% drvstr
|
||||
% neededSystem
|
||||
|
@ -144,6 +144,10 @@ public:
|
||||
: HintFmt("%s", Uncolored(literal))
|
||||
{ }
|
||||
|
||||
static HintFmt fromFormatString(const std::string & format) {
|
||||
return HintFmt(boost::format(format));
|
||||
}
|
||||
|
||||
/**
|
||||
* Interpolate the given arguments into the format string.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user