Refactor plugin_exchangedb_postgres for GNUNET_memcmp
This commit is contained in:
parent
7333c55c53
commit
b669f0dfae
@ -2924,9 +2924,8 @@ postgres_have_deposit (void *cls,
|
|||||||
deposit2.timestamp.abs_value_us) ) ) ||
|
deposit2.timestamp.abs_value_us) ) ) ||
|
||||||
(deposit->refund_deadline.abs_value_us !=
|
(deposit->refund_deadline.abs_value_us !=
|
||||||
deposit2.refund_deadline.abs_value_us) ||
|
deposit2.refund_deadline.abs_value_us) ||
|
||||||
(0 != memcmp (&deposit->h_wire,
|
(0 != GNUNET_memcmp (&deposit->h_wire,
|
||||||
&deposit2.h_wire,
|
&deposit2.h_wire) ) )
|
||||||
sizeof (struct GNUNET_HashCode)) ) )
|
|
||||||
{
|
{
|
||||||
/* Inconsistencies detected! Does not match! (We might want to
|
/* Inconsistencies detected! Does not match! (We might want to
|
||||||
expand the API with a 'get_deposit' function to return the
|
expand the API with a 'get_deposit' function to return the
|
||||||
@ -4114,9 +4113,8 @@ add_ldl (void *cls,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ( (NULL != ldctx->last) &&
|
if ( (NULL != ldctx->last) &&
|
||||||
(0 == memcmp (&transfer_pub,
|
(0 == GNUNET_memcmp (&transfer_pub,
|
||||||
&ldctx->transfer_pub,
|
&ldctx->transfer_pub)) )
|
||||||
sizeof (struct TALER_TransferPublicKeyP))) )
|
|
||||||
{
|
{
|
||||||
pos->next = ldctx->last;
|
pos->next = ldctx->last;
|
||||||
}
|
}
|
||||||
@ -4964,9 +4962,8 @@ postgres_insert_wire_fee (void *cls,
|
|||||||
return qs;
|
return qs;
|
||||||
if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT == qs)
|
if (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT == qs)
|
||||||
{
|
{
|
||||||
if (0 != memcmp (&sig,
|
if (0 != GNUNET_memcmp (&sig,
|
||||||
master_sig,
|
master_sig))
|
||||||
sizeof (sig)))
|
|
||||||
{
|
{
|
||||||
GNUNET_break (0);
|
GNUNET_break (0);
|
||||||
return GNUNET_DB_STATUS_HARD_ERROR;
|
return GNUNET_DB_STATUS_HARD_ERROR;
|
||||||
|
Loading…
Reference in New Issue
Block a user