I am running sqlite3 on a Linux Mint 18 desktop.

I first realized the problem with the stock sqlite3 client 3.11.0
2016-02-15 17:29:24 3d862f207e3adc00f78066799ac5a8c282430a5f.

I confirmed it still exists with the currently published most recent
version 3.30.1 2019-10-10 20:19:45
18db032d058f1436ce3dea84081f4ee5a0f2259ad97301d43c426bc7f3df1b0b

Steps to reproduce:

--
$ sqlite3
SQLite version 3.30.1 2019-10-10 20:19:45
Enter ".help" for usage hints.

sqlite> create table feedback (fid integer primary key autoincrement,
cid integer not null references characters, game_number integer not null
default 1, players integer not null default 2, playtime text check
(playtime in ("kurz", "20-30", "30-45", "45-60", "lang")),
beginning_player boolean, liked integer, duration integer, luckiness
integer, complexity integer, rules integer, rule_suggestions text,
budget integer, text text);

sqlite> insert into feedback values (1, 1, 1, 2, "kurz", 1, 10, 3, 2, 3,
9, NULL, 10, NULL);

sqlite> select * from feedback;
1|1|1|2|kurz|1|10|3|2|3|9||10|

sqlite> .explain on
sqlite> select * from feedback;
--

This triggers an infinite loop. It uses a full cpu. strace shows it is
doing write(1, "    "..., 1024) repeatedly (spaces).

gdb shows the following stack (no debug symbols in the sqlite binary
unfortunately):

(gdb) bt
#0  0xf7fd7fe9 in __kernel_vsyscall ()
#1  0xf7e4fb93 in write () from /lib/i386-linux-gnu/libc.so.6
#2  0xf7de30b1 in _IO_file_write () from /lib/i386-linux-gnu/libc.so.6
#3  0xf7de23e4 in ?? () from /lib/i386-linux-gnu/libc.so.6
#4  0xf7de412d in _IO_do_write () from /lib/i386-linux-gnu/libc.so.6
#5  0xf7de4518 in _IO_file_overflow () from /lib/i386-linux-gnu/libc.so.6
#6  0xf7de379e in _IO_file_xsputn () from /lib/i386-linux-gnu/libc.so.6
#7  0xf7dd95f5 in _IO_padn () from /lib/i386-linux-gnu/libc.so.6
#8  0xf7dbd6b7 in vfprintf () from /lib/i386-linux-gnu/libc.so.6
#9  0xf7dc3668 in fprintf () from /lib/i386-linux-gnu/libc.so.6
#10 0x080ea46b in ?? ()
#11 0x080eb033 in ?? ()
#12 0x080eccc9 in ?? ()
#13 0x080ed698 in ?? ()
#14 0x080f5e8f in ?? ()
#15 0x0804f03a in ?? ()
#16 0xf7d92637 in __libc_start_main () from /lib/i386-linux-gnu/libc.so.6
#17 0x0804f139 in ?? ()

Regards,
-Jan
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to