From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp44.i.mail.ru (smtp44.i.mail.ru [94.100.177.104]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id C02054696C4 for ; Fri, 24 Apr 2020 13:14:38 +0300 (MSK) From: Chris Sosnin Date: Fri, 24 Apr 2020 13:14:25 +0300 Message-Id: <6460ab0afb45070c0741bd8feecf4de4265d3930.1587722860.git.k.sosnin@tarantool.org> In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH 2/2] sql: fix assertion fault in SELECT * FROM "_vfunc" List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: tarantool-patches@dev.tarantool.org, kyukhin@tarantool.org It fails because it was forgotten to update _vfunc format along with _func in 2.2.1. This leads to bad allocation of vdbe cursor and setting wrong memory to 0. Closes #4666 --- src/box/bootstrap.snap | Bin 5976 -> 5968 bytes src/box/lua/upgrade.lua | 9 +++++++++ test/box-py/bootstrap.result | 11 +++++++++-- test/sql/engine.cfg | 1 + test/sql/gh-4666-sql-select-from-vfunc.result | 7 +++++++ .../gh-4666-sql-select-from-vfunc.test.lua | 4 ++++ 6 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 test/sql/gh-4666-sql-select-from-vfunc.result create mode 100644 test/sql/gh-4666-sql-select-from-vfunc.test.lua diff --git a/src/box/bootstrap.snap b/src/box/bootstrap.snap index 8bd4f7ce24216a8bcced6aa97c20c83eb7a02c77..5b495eac552ade8c6096ad090ea7f01ede5613ce 100644 GIT binary patch delta 5223 zcmV-t6qxJSF3>KJ6@N7@FfBDLXJKMEGB7eZWMv9TZgX^DZewLSAUI_*H(@nqVJ$Ra zV=^r?Wj8S`VlXr`Enzn@Fk~_}W@Is9HVRflY;R+0Iv{&}3JTS_3%bn~*Z|JI@XP|G z0000004TLD{QyvXw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YI@KIY_ zO`kofQI-|~k8TkUcHTY=uOf>jp+Y*?Z{N`O<}JhlhFwIoxMdilugGFa=u6{&(RdGD z(r8v=`ki-7w|%_V$HdvHbMm5n=n1vt1|9sjZshBBd{Ab??H#_-W48OovM!(FWss2~Wkl+b6Xfj@SXLunZWX~Y1tso^OR`iFK{kl0Rvhx`YBvJY6g09c2q z_63`e!b%q?3n~Nq(eXv&K>Us^P7I3(z5$fhI!M`28M%+oD{|Q(`s*D>E8X1nr};#)r)_^i!ocrIrYZgtBv3Yq&w)@q*ez%5 z8hG&_Su`@!q}X}!(DZnJqzMU(M%+6KCnM#86yw5n>p8j&A@Vrl!^l>qwi`DL6y8>$ z<9S?)b~56i5yNXGE0Kh|@94+M91R4>2Pz1SBMD>`ePVqy|1*+9I$mxBT2(L%O4wE8 z`~8?Uz{p=-w1xPg&xGs-lZN3}Otq5m$hn#eOLSi&7ziwME9JV7BfxSeuj7p-GA73~&_OGx44B{s zu3^x|{pRLOqy=Yx#y(CbN<{A1N|9)SgzgV88Be)RxS~=DmdFh1f;NMLhix~=wQM*D zEW-|s#mgK&$Fex+HW5}(j=?pi*}i2FcCXTg7#tl`5m3wT;Q{x{+a(TvOUjbBi=q2z{K6o*$_;3+h)n{XZ&x#0;LY zAq?Fctb?l!U>tgWQWt!BU?>VvPZ)?+)s0;?+xNJ@I$^gyS{&6WC9$#&T@5*;6Lzq4 z{ViDkm(vD+2SIEwa1$Upf0HRn60Q*$wz7cW9arM~hz7x))w9&YK*0L)fwmmLBLRRM z^peXOG~YSUf<65R0q|HF;)k=Vuwrp5A?KEnP?BIW%{$pyGacGv5ZfA?JOjDjxA}5n zZ90&J0sz=i2ujD*V RcJ>e^DZi!Rhd$L1t?g-?(oX;Y diff --git a/src/box/lua/upgrade.lua b/src/box/lua/upgrade.lua index bd9a881b0..eeda155ad 100644 --- a/src/box/lua/upgrade.lua +++ b/src/box/lua/upgrade.lua @@ -978,6 +978,14 @@ local function upgrade_to_2_3_1() create_session_settings_space() end +local function upgrade_to_2_3_1_1() + -- Formats must be equal in order to avoid crashes in SQL + -- caused by incorrectly allocated cursor. + local _func = box.space[box.schema.FUNC_ID] + local _vfunc = box.space[box.schema.VFUNC_ID] + _vfunc:format(_func:format()) +end + -------------------------------------------------------------------------------- local function get_version() @@ -1015,6 +1023,7 @@ local function upgrade(options) {version = mkversion(2, 2, 1), func = upgrade_to_2_2_1, auto = true}, {version = mkversion(2, 3, 0), func = upgrade_to_2_3_0, auto = true}, {version = mkversion(2, 3, 1), func = upgrade_to_2_3_1, auto = true}, + {version = mkversion(2, 3, 1, 1), func = upgrade_to_2_3_1_1, auto = true}, } for _, handler in ipairs(handlers) do diff --git a/test/box-py/bootstrap.result b/test/box-py/bootstrap.result index 0876e77a6..6fb10d88c 100644 --- a/test/box-py/bootstrap.result +++ b/test/box-py/bootstrap.result @@ -4,7 +4,7 @@ box.internal.bootstrap() box.space._schema:select{} --- - - ['max_id', 511] - - ['version', 2, 3, 1] + - ['version', 2, 3, 1, 1] ... box.space._cluster:select{} --- @@ -63,7 +63,14 @@ box.space._space:select{} 'type': 'string'}, {'name': 'last_altered', 'type': 'string'}]] - [297, 1, '_vfunc', 'sysview', 0, {}, [{'name': 'id', 'type': 'unsigned'}, {'name': 'owner', 'type': 'unsigned'}, {'name': 'name', 'type': 'string'}, {'name': 'setuid', - 'type': 'unsigned'}]] + 'type': 'unsigned'}, {'name': 'language', 'type': 'string'}, {'name': 'body', + 'type': 'string'}, {'name': 'routine_type', 'type': 'string'}, {'name': 'param_list', + 'type': 'array'}, {'name': 'returns', 'type': 'string'}, {'name': 'aggregate', + 'type': 'string'}, {'name': 'sql_data_access', 'type': 'string'}, {'name': 'is_deterministic', + 'type': 'boolean'}, {'name': 'is_sandboxed', 'type': 'boolean'}, {'name': 'is_null_call', + 'type': 'boolean'}, {'name': 'exports', 'type': 'array'}, {'name': 'opts', + 'type': 'map'}, {'name': 'comment', 'type': 'string'}, {'name': 'created', + 'type': 'string'}, {'name': 'last_altered', 'type': 'string'}]] - [304, 1, '_user', 'memtx', 0, {}, [{'name': 'id', 'type': 'unsigned'}, {'name': 'owner', 'type': 'unsigned'}, {'name': 'name', 'type': 'string'}, {'name': 'type', 'type': 'string'}, {'name': 'auth', 'type': 'map'}]] diff --git a/test/sql/engine.cfg b/test/sql/engine.cfg index 1e9f08c6a..22ea90043 100644 --- a/test/sql/engine.cfg +++ b/test/sql/engine.cfg @@ -2,6 +2,7 @@ "vinyl-opts.test.lua" : { "vinyl": {"engine": "vinyl"} }, + "gh-4666-sql-select-from-vfunc.test.lua": { }, "bind.test.lua": { "remote": {"remote": "true"}, "local": {"remote": "false"} diff --git a/test/sql/gh-4666-sql-select-from-vfunc.result b/test/sql/gh-4666-sql-select-from-vfunc.result new file mode 100644 index 000000000..5e5ea8aaf --- /dev/null +++ b/test/sql/gh-4666-sql-select-from-vfunc.result @@ -0,0 +1,7 @@ +-- test-run result file version 2 +-- +-- Make sure assertion does not fail. +-- +_ = box.execute([[select * from "_vfunc";]]) + | --- + | ... diff --git a/test/sql/gh-4666-sql-select-from-vfunc.test.lua b/test/sql/gh-4666-sql-select-from-vfunc.test.lua new file mode 100644 index 000000000..3ac0aadc5 --- /dev/null +++ b/test/sql/gh-4666-sql-select-from-vfunc.test.lua @@ -0,0 +1,4 @@ +-- +-- Make sure assertion does not fail. +-- +_ = box.execute([[select * from "_vfunc";]]) -- 2.21.1 (Apple Git-122.3)