aboutsummaryrefslogtreecommitdiff
path: root/src/vdbeaux.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vdbeaux.c')
-rw-r--r--src/vdbeaux.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/vdbeaux.c b/src/vdbeaux.c
index e07aacbca..cd9ecaa69 100644
--- a/src/vdbeaux.c
+++ b/src/vdbeaux.c
@@ -3373,7 +3373,8 @@ static void vdbeAssertFieldCountWithinLimits(
if( CORRUPT_DB ) return;
idx = getVarint32(aKey, szHdr);
- assert( szHdr<=nKey );
+ assert( nKey>=0 );
+ assert( szHdr<=(u32)nKey );
while( idx<szHdr ){
idx += getVarint32(aKey+idx, notUsed);
nField++;