summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2018-09-20 17:19:50 (GMT)
committerBerker Peksag <berker.peksag@gmail.com>2018-09-20 17:19:50 (GMT)
commit4fb672ff96ecbb87aaf2ecc4f04aed76aafe63b1 (patch)
treeda7c02dd1ec43e95e7ab2cab81705ad6e5761396 /Modules
parent1eabe19c57938dd70b66b97239be337294e15cba (diff)
downloadcpython-4fb672ff96ecbb87aaf2ecc4f04aed76aafe63b1.zip
cpython-4fb672ff96ecbb87aaf2ecc4f04aed76aafe63b1.tar.gz
cpython-4fb672ff96ecbb87aaf2ecc4f04aed76aafe63b1.tar.bz2
bpo-32215: Fix performance regression in sqlite3 (GH-8511)
(cherry picked from commit 8d1e190fc507a9e304f6817e761e9f628a23cbd8) Co-authored-by: Berker Peksag <berker.peksag@gmail.com>
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_sqlite/statement.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/_sqlite/statement.c b/Modules/_sqlite/statement.c
index 087375b..de26596 100644
--- a/Modules/_sqlite/statement.c
+++ b/Modules/_sqlite/statement.c
@@ -85,10 +85,10 @@ int pysqlite_statement_create(pysqlite_Statement* self, pysqlite_Connection* con
continue;
}
- self->is_dml = (PyOS_strnicmp(p, "insert ", 7) == 0)
- || (PyOS_strnicmp(p, "update ", 7) == 0)
- || (PyOS_strnicmp(p, "delete ", 7) == 0)
- || (PyOS_strnicmp(p, "replace ", 8) == 0);
+ self->is_dml = (PyOS_strnicmp(p, "insert", 6) == 0)
+ || (PyOS_strnicmp(p, "update", 6) == 0)
+ || (PyOS_strnicmp(p, "delete", 6) == 0)
+ || (PyOS_strnicmp(p, "replace", 7) == 0);
break;
}