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
{{ message }}
Repository navigation
If HAVE_LONG_LONG is not defined, longval will not be initialized (_sqlite) #46792
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2008-05-04.13:03:48.861>created_at=<Date2008-04-03.04:00:30.834>labels= ['extension-modules', 'type-bug']
title='If HAVE_LONG_LONG is not defined, longval will not be initialized (_sqlite)'updated_at=<Date2008-05-04.13:03:48.828>user='https://bugs.python.org/ocean-city'
I noticed compiler warned "'longval' is not used anywhere."
And I found 'longval' was not initialized where HAVE_LONG_LONG
was not defined. Is attached patch intended behavior? Thanks.
Traceback (most recent call last):
File "e:\python-dev\py3k\lib\sqlite3\test\types.py", line 146, in
CheckLargeIn
t
self.cur.execute("insert into test(i) values (?)", (num,))
OverflowError: Python int too large to convert to C long
My problem is that I can't really test (better than #undefining
HAVE_LONG_LONG) this, because I have no platform to test on that doesn't
have long longs.
I'm not even sure SQLite *really* works when there is no 64-bit type.
I'll ask on the SQLite mailing list. If that is so, then I'd like to get
rid of the superfluous #ifdefs.
ghaering commented on May 4, 2008
ghaeringmannequin
Mannequin
More actions
SQLite requires 64-bit integers in order to build. So the whole
HAVE_LONG_LONG #ifdefing was useless. I've removed it in r62700.
Activity
ocean-city commentedon Apr 3, 2008
I noticed compiler warned "'longval' is not used anywhere."
And I found 'longval' was not initialized where HAVE_LONG_LONG
was not defined. Is attached patch intended behavior? Thanks.
ocean-city commentedon Apr 3, 2008
Oh, I forgot this. When I debuged with
#undef HAVE_LONG_LONG
I noticed test_sqlite.py failed with this error message.
======================================================================
ERROR: CheckLargeInt (sqlite3.test.types.SqliteTypeTests)
----------------------------------------------------------------------
OverflowError: Python int too large to convert to C long
======================================================================
ERROR: CheckLargeInt (sqlite3.test.types.DeclTypesTests)
----------------------------------------------------------------------
Traceback (most recent call last): File "e:\python-dev\py3k\lib\sqlite3\test\types.py", line 146, in CheckLargeIn t self.cur.execute("insert into test(i) values (?)", (num,)) OverflowError: Python int too large to convert to C longMaybe some fix for test is needed?
loewis commentedon Apr 3, 2008
Gerhard, what do you think?
ghaering commentedon Apr 3, 2008
My problem is that I can't really test (better than #undefining
HAVE_LONG_LONG) this, because I have no platform to test on that doesn't
have long longs.
I'm not even sure SQLite *really* works when there is no 64-bit type.
I'll ask on the SQLite mailing list. If that is so, then I'd like to get
rid of the superfluous #ifdefs.
ghaering commentedon May 4, 2008
SQLite requires 64-bit integers in order to build. So the whole
HAVE_LONG_LONG #ifdefing was useless. I've removed it in r62700.