nix search: Don't quietly ignore errors

This commit is contained in:
Eelco Dolstra 2019-10-09 14:46:58 +02:00
parent 64d8872900
commit 7c74f075f4
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE

View file

@ -261,6 +261,7 @@ struct CmdSearch : SourceExprCommand, MixJSON
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66145 */
if (!jsonCacheFile)
throw Error("error writing to %s", tmpFile);
throw;
}
if (writeCache && rename(tmpFile.c_str(), jsonCacheFileName.c_str()) == -1)