-fix segv

This commit is contained in:
Christian Grothoff 2021-08-22 17:41:30 +02:00
parent 1cc87bf9fe
commit 35133c1e67
No known key found for this signature in database
GPG Key ID: 939E6BE1E29FC3CC

View File

@ -2094,7 +2094,7 @@ handle_credit_history (struct TALER_FAKEBANK_Handle *h,
uint64_t dir; uint64_t dir;
bool skip = true; bool skip = true;
overflow = (t->row_id != ha.start_idx); overflow = ( (NULL != t) && (t->row_id != ha.start_idx) );
dir = (0 > ha.delta) ? (h->ram_limit - 1) : 1; dir = (0 > ha.delta) ? (h->ram_limit - 1) : 1;
/* If account does not match, linear scan for /* If account does not match, linear scan for
first matching account. */ first matching account. */