anotherim-desktop/crypto-vala/src/error.vala

15 lines
280 B
Vala
Raw Normal View History

2019-09-10 18:55:24 +00:00
namespace Crypto {
public errordomain Error {
ILLEGAL_ARGUMENTS,
2021-03-29 11:20:12 +00:00
GCRYPT,
AUTHENTICATION_FAILED,
UNKNOWN
2019-09-10 18:55:24 +00:00
}
internal void may_throw_gcrypt_error(GCrypt.Error e) throws Error {
2019-09-10 18:55:24 +00:00
if (((int)e) != 0) {
throw new Crypto.Error.GCRYPT(e.to_string());
}
}
}