summaryrefslogtreecommitdiffstats
path: root/Modules/_sqlite/module.c
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2018-07-10 04:20:23 (GMT)
committerGitHub <noreply@github.com>2018-07-10 04:20:23 (GMT)
commit7762e4d3872818272800dfbd8e1d8e3a689eb8f2 (patch)
tree6f0cecbbbff18225b574f25e1a8c34e80d0d465d /Modules/_sqlite/module.c
parentd6d4432724b12efc0d280b8eb80bca0deb8d4323 (diff)
downloadcpython-7762e4d3872818272800dfbd8e1d8e3a689eb8f2.zip
cpython-7762e4d3872818272800dfbd8e1d8e3a689eb8f2.tar.gz
cpython-7762e4d3872818272800dfbd8e1d8e3a689eb8f2.tar.bz2
prefix internal sqlite symbols with _pysqlite_ (GH-8215)
Diffstat (limited to 'Modules/_sqlite/module.c')
-rw-r--r--Modules/_sqlite/module.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/Modules/_sqlite/module.c b/Modules/_sqlite/module.c
index 6befa07..db2b495 100644
--- a/Modules/_sqlite/module.c
+++ b/Modules/_sqlite/module.c
@@ -46,8 +46,8 @@ PyObject *pysqlite_IntegrityError = NULL;
PyObject *pysqlite_DataError = NULL;
PyObject *pysqlite_NotSupportedError = NULL;
-PyObject* converters = NULL;
-int _enable_callback_tracebacks = 0;
+PyObject* _pysqlite_converters = NULL;
+int _pysqlite_enable_callback_tracebacks = 0;
int pysqlite_BaseTypeAdapted = 0;
static PyObject* module_connect(PyObject* self, PyObject* args, PyObject*
@@ -204,7 +204,7 @@ static PyObject* module_register_converter(PyObject* self, PyObject* args)
goto error;
}
- if (PyDict_SetItem(converters, name, callable) != 0) {
+ if (PyDict_SetItem(_pysqlite_converters, name, callable) != 0) {
goto error;
}
@@ -222,7 +222,7 @@ Registers a converter with pysqlite. Non-standard.");
static PyObject* enable_callback_tracebacks(PyObject* self, PyObject* args)
{
- if (!PyArg_ParseTuple(args, "i", &_enable_callback_tracebacks)) {
+ if (!PyArg_ParseTuple(args, "i", &_pysqlite_enable_callback_tracebacks)) {
return NULL;
}
@@ -236,12 +236,12 @@ Enable or disable callback functions throwing errors to stderr.");
static void converters_init(PyObject* dict)
{
- converters = PyDict_New();
- if (!converters) {
+ _pysqlite_converters = PyDict_New();
+ if (!_pysqlite_converters) {
return;
}
- PyDict_SetItemString(dict, "converters", converters);
+ PyDict_SetItemString(dict, "converters", _pysqlite_converters);
}
static PyMethodDef module_methods[] = {