Package: sqlite Version: 2.8.17-6 Severity: normal I have following code:
""" #!/usr/bin/env python # -*- coding: utf-8 -*- import sqlite print('Sqlite module version: %s' % sqlite.version) conn = sqlite.connect('test.db') connection = conn.cursor() arg = 'foo' connection.execute('insert into test (id, arg, arg3) values (1, arg=:arg)', {"arg": arg}) conn.commit() """ My Python is 2.6.6-8+b1 (/usr/bin/python -V -> Python 2.6.6) fgeek@example:~/pythontest$ /usr/bin/python sqlitefail.py Sqlite module version: 1.0.1 Segmentation fault Trace: Program received signal SIGSEGV, Segmentation fault. __strlen_sse2 () at ../sysdeps/x86_64/multiarch/../strlen.S:31 31 ../sysdeps/x86_64/multiarch/../strlen.S: No such file or directory. in ../sysdeps/x86_64/multiarch/../strlen.S Current language: auto The current source language is "auto; currently asm". (gdb) bt #0 __strlen_sse2 () at ../sysdeps/x86_64/multiarch/../strlen.S:31 #1 0x00007ffff6425de5 in sqliteSetNString () from /usr/lib/libsqlite.so.0 #2 0x00007ffff642339a in sqliteRunParser () from /usr/lib/libsqlite.so.0 #3 0x00007ffff6413c8a in sqlite_compile () from /usr/lib/libsqlite.so.0 #4 0x00007ffff6413f33 in sqlite_exec () from /usr/lib/libsqlite.so.0 #5 0x00007ffff6651e86 in ?? () from /usr/lib/python2.6/dist-packages/_sqlite.so #6 0x00000000004a7ba5 in call_function (f= Frame 0x97c950, for file /usr/lib/python2.6/dist-packages/sqlite/main.py, line 255, in execute (self=<Cursor(description=None, rs=None, rowclass=<classobj at remote 0x7ffff7f1be30>, _real_rowcount=0, current_recnum=-1, rowcount=-1, arraysize=1, closed=None, con=<weakproxy at remote 0x7ffff7f15050>) at remote 0x7ffff7edb9e0>, SQL='insert into test (id, arg, arg3) values (1, arg=:arg)', parms={'arg': "'foo'"}), throwflag=<value optimized out>) at ../Python/ceval.c:3750 #7 PyEval_EvalFrameEx (f= Frame 0x97c950, for file /usr/lib/python2.6/dist-packages/sqlite/main.py, line 255, in execute (self=<Cursor(description=None, rs=None, rowclass=<classobj at remote 0x7ffff7f1be30>, _real_rowcount=0, current_recnum=-1, rowcount=-1, arraysize=1, closed=None, con=<weakproxy at remote 0x7ffff7f15050>) at remote 0x7ffff7edb9e0>, SQL='insert into test (id, arg, arg3) values (1, arg=:arg)', parms={'arg': "'foo'"}), throwflag=<value optimized out>) at ../Python/ceval.c:2412 #8 0x00000000004a95c1 in PyEval_EvalCodeEx (co=0x7ffff7f09eb8, globals=<value optimized out>, locals=<value optimized out>, args=0x2, argcount=<value optimized out>, kws=<value optimized out>, kwcount=0, defs=0x0, defcount=0, closure=0x0) at ../Python/ceval.c:3000 #9 0x00000000004a7752 in fast_function (f=Frame 0x91ba40, for file sqlitefail.py, line 11, in <module> (), throwflag=<value optimized out>) at ../Python/ceval.c:3846 #10 call_function (f=Frame 0x91ba40, for file sqlitefail.py, line 11, in <module> (), throwflag=<value optimized out>) at ../Python/ceval.c:3771 #11 PyEval_EvalFrameEx (f=Frame 0x91ba40, for file sqlitefail.py, line 11, in <module> (), throwflag=<value optimized out>) at ../Python/ceval.c:2412 #12 0x00000000004a95c1 in PyEval_EvalCodeEx (co=0x7ffff7efc7b0, globals=<value optimized out>, locals=<value optimized out>, args=0x0, argcount=<value optimized out>, kws=<value optimized out>, kwcount=0, defs=0x0, defcount=0, closure=0x0) at ../Python/ceval.c:3000 #13 0x00000000004a9692 in PyEval_EvalCode (co=0x7fff00000000, globals=<unknown at remote 0xfffffffc>, locals= <unknown at remote 0x7fffffffdc50>) at ../Python/ceval.c:541 #14 0x00000000004c98be in run_mod (fp=<value optimized out>, filename=0x7fffffffe7f1 "sqlitefail.py", start=<value optimized out>, globals=<value optimized out>, locals=<value optimized out>, closeit=1, flags=0x7fffffffe470) at ../Python/pythonrun.c:1351 #15 PyRun_FileExFlags (fp=<value optimized out>, filename=0x7fffffffe7f1 "sqlitefail.py", start=<value optimized out>, globals=<value optimized out>, locals=<value optimized out>, closeit=1, flags=0x7fffffffe470) at ../Python/pythonrun.c:1337 ---Type <return> to continue, or q <return> to quit--- #16 0x00000000004c9ad4 in PyRun_SimpleFileExFlags (fp=<value optimized out>, filename=0x7fffffffe7f1 "sqlitefail.py", closeit=1, flags=0x7fffffffe470) at ../Python/pythonrun.c:941 #17 0x000000000041a6bd in Py_Main (argc=-134897504, argv=<value optimized out>) at ../Modules/main.c:577 #18 0x00007ffff69e9c8d in __libc_start_main (main=<value optimized out>, argc=<value optimized out>, ubp_av=<value optimized out>, init=<value optimized out>, fini=<value optimized out>, rtld_fini=<value optimized out>, stack_end=0x7fffffffe588) at libc-start.c:228 #19 0x00000000004198d9 in _start () Even with wrong syntax or error states sqlite-module should not segfault. If I import sqlite3 version 2.4.1 it only gives sqlite3.OperationalError: no such table: test -- System Information: Debian Release: 6.0.6 APT prefers stable-updates APT policy: (500, 'stable-updates'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-5-amd64 (SMP w/8 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to en_US.UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages sqlite depends on: ii libc6 2.11.3-4 Embedded GNU C Library: Shared lib ii libreadline6 6.1-3 GNU readline and history libraries ii libsqlite0 2.8.17-6 SQLite shared library sqlite recommends no packages. Versions of packages sqlite suggests: ii sqlite-doc 2.8.17-6 SQLite documentation -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org