-simplify zero-check for age-commitment hash
This commit is contained in:
parent
7521ff1cf4
commit
5608a73c00
@ -1309,13 +1309,8 @@ struct TALER_AgeAttestation
|
|||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#define TALER_AgeCommitmentHash_isNullOrZero(ph) ((NULL == ph) || \
|
||||||
extern const struct TALER_AgeCommitmentHash TALER_ZeroAgeCommitmentHash;
|
GNUNET_is_zero (ph))
|
||||||
#define TALER_AgeCommitmentHash_isNullOrZero(ph) \
|
|
||||||
((NULL == ph) || \
|
|
||||||
(0 == memcmp (ph, \
|
|
||||||
&TALER_ZeroAgeCommitmentHash, \
|
|
||||||
sizeof(struct TALER_AgeCommitmentHash))))
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Type of public signing keys for verifying blindly signed coins.
|
* @brief Type of public signing keys for verifying blindly signed coins.
|
||||||
|
@ -26,11 +26,6 @@
|
|||||||
#include "taler_util.h"
|
#include "taler_util.h"
|
||||||
#include <gcrypt.h>
|
#include <gcrypt.h>
|
||||||
|
|
||||||
/**
|
|
||||||
* Used in TALER_AgeCommitmentHash_isNullOrZero for comparison
|
|
||||||
*/
|
|
||||||
const struct TALER_AgeCommitmentHash TALER_ZeroAgeCommitmentHash = {0};
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function called by libgcrypt on serious errors.
|
* Function called by libgcrypt on serious errors.
|
||||||
* Prints an error message and aborts the process.
|
* Prints an error message and aborts the process.
|
||||||
|
Loading…
Reference in New Issue
Block a user