aboutsummaryrefslogtreecommitdiff
path: root/src/test_malloc.c
diff options
context:
space:
mode:
authordrh <>2025-01-13 11:28:34 +0000
committerdrh <>2025-01-13 11:28:34 +0000
commit43afab28a09659f7869661a8e56f21865af2414d (patch)
treea9299a76f9b1624d642e00f24fb2945d0b64e8af /src/test_malloc.c
parent14bc98d8e2a7d07b98bf679b9e586043dd772bf3 (diff)
downloadsqlite-43afab28a09659f7869661a8e56f21865af2414d.tar.gz
sqlite-43afab28a09659f7869661a8e56f21865af2414d.zip
GCC 13 has become more quite pedantic about the signature of functions matching the
type of pointers through which the functions are called. Make adjustments to extension functions and test procedures to work around this. No changes to the core. FossilOrigin-Name: ed83b79100b4345235aec990303c4526874f0c2f8701160c4639a80633ebaf70
Diffstat (limited to 'src/test_malloc.c')
-rw-r--r--src/test_malloc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/test_malloc.c b/src/test_malloc.c
index 21faa0d29..8d6c4fa50 100644
--- a/src/test_malloc.c
+++ b/src/test_malloc.c
@@ -41,8 +41,9 @@ static struct MemFault {
** fire on any simulated malloc() failure.
*/
static void sqlite3Fault(void){
- static int cnt = 0;
+ static u64 cnt = 0;
cnt++;
+ if( cnt>((u64)1<<63) ) abort();
}
/*
@@ -52,8 +53,9 @@ static void sqlite3Fault(void){
** This routine only runs on the first such failure.
*/
static void sqlite3FirstFault(void){
- static int cnt2 = 0;
+ static u64 cnt2 = 0;
cnt2++;
+ if( cnt2>((u64)1<<63) ) abort();
}
/*