Skip to content

Commit 7c8447b

Browse files
committed
Added/Updated tests\functional\intfunc\unlist\unlist_ascii_char_0_test.py: Checked on 6.0.0.744
1 parent ee65c13 commit 7c8447b

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#coding:utf-8
2+
3+
"""
4+
ID: issue-8418
5+
ISSUE: https://github.com/FirebirdSQL/firebird/pull/8418
6+
TITLE: UNLIST function. Check ability to use ascii_char(0) as delimiter.
7+
DESCRIPTION:
8+
On 6.0.0.725-a2b05f4-x64 usage of ascii_char(0) as separator causes 100% CPU load and FB service could not be stopped.
9+
See: https://github.com/FirebirdSQL/firebird/pull/8418#issuecomment-2792358627
10+
Fixed 19.04.2025 20:36:
11+
https://github.com/FirebirdSQL/firebird/commit/33ad7e632ae073223f808c8fdc83673d6d04e454
12+
NOTES:
13+
[23.04.2025] pzotov
14+
Checked on 6.0.0.744
15+
"""
16+
17+
import pytest
18+
from firebird.qa import *
19+
20+
db = db_factory()
21+
22+
test_script = f"""
23+
set list on;
24+
set count on; select * from unlist('1', ascii_char(0)) as u(x);
25+
"""
26+
27+
act = isql_act('db', test_script, substitutions=[ ('[ \\t]+', ' ') ])
28+
29+
expected_stdout = f"""
30+
X 1
31+
Records affected: 1
32+
"""
33+
34+
@pytest.mark.version('>=6.0')
35+
def test_1(act: Action):
36+
act.expected_stdout = expected_stdout
37+
act.execute(combine_output = True)
38+
assert act.clean_stdout == act.clean_expected_stdout

0 commit comments

Comments
 (0)