Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#45378 - [lua-sql-sqlite] v2.3.0-4 curser fetching with lua 5.3 produces segfault
Attached to Project:
Community Packages
Opened by Nimrod Maclomhair (nimrod_mack) - Thursday, 18 June 2015, 15:57 GMT
Last edited by Sergej Pupykin (sergej) - Friday, 19 June 2015, 14:06 GMT
Opened by Nimrod Maclomhair (nimrod_mack) - Thursday, 18 June 2015, 15:57 GMT
Last edited by Sergej Pupykin (sergej) - Friday, 19 June 2015, 14:06 GMT
|
DetailsDescription:
============ Using lua-sql-sqlite v2.3.0-4, lua v5.3.0-2, sqlite v3.8.10.2-1 When fetching data after a SELECT statement, the process segfaults. It usually happened after the last result, when fetch() should actually return nil. I also had cases in which fetch failed at the second call even though there were more lines to fetch. The segfaults produced entries in the journal looking like this: kernel: lua[4954]: segfault at c ip b77c281c sp bff03020 error 6 in sqlite3.so[b77c1000+4000] The number after "sp" changed with every process but always started with "bf". The number at the end in brackets also changed with every process except the first numbers "b77" and the number after the + (4000) Furthermore there appears to be a problem with integers. In my test, I got for a sql 1 the number -5226363819227348991, for 2 a -5226363819227348990 and so on. I tried to use the lua-sql-sqlite3 module in lua5.2 and encounterd no errors. When searching Google, I couldn't find any posts or entries describing the problem. lua-sql-sqlite started working normally with lua v5.3 when I dropped the compile option "-DLUA_32BITS" from the PKGBUILD and recompiled. Steps to reproduce: =================== Example script for lua: conn = require "luasql.sqlite3".sqlite3():connect("testdb.db") cur = conn:execute("SELECT id, name FROM test"); while true do local id, name = cur:fetch() if not id then break; end print(id, name); end if cur then cur:close(); end conn:close() I attached a test database for easier reproduction |
This task depends upon
testdb.db
Sergej, do you know why the package is compiled with "-DLUA_32BITS" flag? It seems causes number overflow.