You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The hash calculation should use unsigned long / Py_uhash_t to ensure that overflows cause wrap-around as expected.
When compiling with gcc -fsanitize=undefined:
apsw/src/apswbuffer.c:121:18: runtime error: signed integer overflow: 10240061520092322 * 1000003 cannot be represented in type 'long int'
#0 0x14554f995692 in APSWBuffer_hash apsw/src/apswbuffer.c:121
#1 0x145559d8e7a0 in PyDict_Contains Objects/dictobject.c:3094
#2 0x14554f9b6427 in statementcache_finalize apsw/src/statementcache.c:454
#3 0x14554f9b7664 in resetcursor apsw/src/cursor.c:184
#4 0x14554f9c70cc in APSWCursor_step apsw/src/cursor.c:825
#5 0x14554f9c9b61 in APSWCursor_execute apsw/src/cursor.c:1046
#6 0x145559d9dc6d in _PyCFunction_FastCallDict Objects/methodobject.c:234
#7 0x145559e27033 in call_function Python/ceval.c:4788
#8 0x145559e2a409 in _PyEval_EvalFrameDefault Python/ceval.c:3275
The text was updated successfully, but these errors were encountered:
The hash calculation should use
unsigned long
/Py_uhash_t
to ensure that overflows cause wrap-around as expected.When compiling with
gcc -fsanitize=undefined
:The text was updated successfully, but these errors were encountered: