corrections applied to batch 1

This commit is contained in:
Joseph 2023-01-06 06:16:52 -05:00
parent 043c46c59d
commit 865f3aca19
No known key found for this signature in database
GPG Key ID: E709789D3076B5CC
2 changed files with 5 additions and 11 deletions

View File

@ -92,9 +92,9 @@ transaction_duplicate= TRUE;
transaction_duplicate = FALSE; transaction_duplicate = FALSE;
ELSE ELSE
-- Unhappy... -- Unhappy...
RAISE EXCEPTION 'Reserve did not exist, but INSERT into reserves_in gave conflict'; -- RAISE EXCEPTION 'Reserve did not exist, but INSERT into reserves_in gave conflict';
transaction_duplicate = TRUE; transaction_duplicate = TRUE;
ROLLBACK; -- ROLLBACK;
END IF; END IF;
RETURN; RETURN;
END $$; END $$;

View File

@ -787,6 +787,9 @@ TEH_PG_batch2_reserves_in_insert (void *cls,
need_update |= conflicts[i+1]; need_update |= conflicts[i+1];
t_duplicate |= transaction_duplicate[i]; t_duplicate |= transaction_duplicate[i];
t_duplicate |= transaction_duplicate[i+1]; t_duplicate |= transaction_duplicate[i+1];
results[i] = (t_duplicate)
? GNUNET_DB_STATUS_SUCCESS_NO_RESULTS
: GNUNET_DB_STATUS_SUCCESS_ONE_RESULT;
i += 2; i += 2;
break; break;
case 1: case 1:
@ -831,15 +834,6 @@ TEH_PG_batch2_reserves_in_insert (void *cls,
{ {
goto exit; goto exit;
} }
/* fprintf(stdout, "t : %d", t_duplicate);
if (t_duplicate)
{
GNUNET_break (0);
TEH_PG_rollback (pg);
return GNUNET_DB_STATUS_HARD_ERROR;
}
*/
// begin serializable // begin serializable
{ {
if (GNUNET_OK != if (GNUNET_OK !=