mirror of
https://github.com/python/cpython.git
synced 2025-07-23 03:05:38 +00:00
bpo-43368: Fix fetching empty bytes in sqlite3 (GH-24706)
Regression introduced in 47feb1feb2
.
This commit is contained in:
parent
09605ad726
commit
3b4b2cf418
3 changed files with 8 additions and 6 deletions
|
@ -409,6 +409,10 @@ class RegressionTests(unittest.TestCase):
|
|||
self.con.execute("select 1") # trigger seg fault
|
||||
method(None)
|
||||
|
||||
def test_return_empty_bytestring(self):
|
||||
cur = self.con.execute("select X''")
|
||||
val = cur.fetchone()[0]
|
||||
self.assertEqual(val, b'')
|
||||
|
||||
|
||||
def suite():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue