summaryrefslogtreecommitdiffstats
path: root/Modules/_csv.c
diff options
context:
space:
mode:
authorAndrew McNamara <andrewm@object-craft.com.au>2005-01-12 08:16:17 (GMT)
committerAndrew McNamara <andrewm@object-craft.com.au>2005-01-12 08:16:17 (GMT)
commit5d45a8dc2247d6d9f59e57d7719c3d467dd3b40d (patch)
tree6ef90ed371a962a972d94a95f7b3d31caacb8fed /Modules/_csv.c
parentc89f284df8903de66be6c60eda7d9187b38956f8 (diff)
downloadcpython-5d45a8dc2247d6d9f59e57d7719c3d467dd3b40d.zip
cpython-5d45a8dc2247d6d9f59e57d7719c3d467dd3b40d.tar.gz
cpython-5d45a8dc2247d6d9f59e57d7719c3d467dd3b40d.tar.bz2
Fix logic problem in quoting=csv.QUOTE_ALL, quotechar=None check, add test.
Diffstat (limited to 'Modules/_csv.c')
-rw-r--r--Modules/_csv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_csv.c b/Modules/_csv.c
index 30b7eca..c592933 100644
--- a/Modules/_csv.c
+++ b/Modules/_csv.c
@@ -401,7 +401,7 @@ dialect_new(PyTypeObject *type, PyObject *args, PyObject *kwargs)
PyErr_SetString(PyExc_TypeError, "delimiter must be set");
goto err;
}
- if (quotechar == Py_None && self->quoting != QUOTE_NONE)
+ if (quotechar == Py_None && quoting == NULL)
self->quoting = QUOTE_NONE;
if (self->quoting != QUOTE_NONE && self->quotechar == 0) {
PyErr_SetString(PyExc_TypeError,