mirror of
https://github.com/NixOS/nix
synced 2025-06-25 14:51:16 +02:00
C API: Add nix_clear_err
This commit is contained in:
parent
afdd12be5e
commit
2dc7598779
3 changed files with 35 additions and 3 deletions
|
@ -57,6 +57,12 @@ nix_err nix_set_err_msg(nix_c_context * context, nix_err err, const char * msg)
|
|||
return err;
|
||||
}
|
||||
|
||||
void nix_clear_err(nix_c_context * context)
|
||||
{
|
||||
if (context)
|
||||
context->last_err_code = NIX_OK;
|
||||
}
|
||||
|
||||
const char * nix_version_get()
|
||||
{
|
||||
return PACKAGE_VERSION;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue