summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorJeremy Hylton <jeremy@alum.mit.edu>2003-09-16 03:10:59 (GMT)
committerJeremy Hylton <jeremy@alum.mit.edu>2003-09-16 03:10:59 (GMT)
commit1aad9c7dade411992005343f6b5b825ac9369ebc (patch)
tree70f1192725ca523ac4e4d4f73e8d88bb0c58c88d /Python
parent37a724d718072e0cdb7b9e773a7c0b9461b3eba1 (diff)
downloadcpython-1aad9c7dade411992005343f6b5b825ac9369ebc.zip
cpython-1aad9c7dade411992005343f6b5b825ac9369ebc.tar.gz
cpython-1aad9c7dade411992005343f6b5b825ac9369ebc.tar.bz2
Reflow long lines and reformat.
Diffstat (limited to 'Python')
-rw-r--r--Python/bltinmodule.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index 01771cb..c3beda9 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -2363,33 +2363,33 @@ filterunicode(PyObject *func, PyObject *strobj)
if (ok) {
int reslen;
if (!PyUnicode_Check(item)) {
- PyErr_SetString(PyExc_TypeError, "can't filter unicode to unicode:"
- " __getitem__ returned different type");
+ PyErr_SetString(PyExc_TypeError,
+ "can't filter unicode to unicode:"
+ " __getitem__ returned different type");
Py_DECREF(item);
goto Fail_1;
}
reslen = PyUnicode_GET_SIZE(item);
- if (reslen == 1) {
+ if (reslen == 1)
PyUnicode_AS_UNICODE(result)[j++] =
PyUnicode_AS_UNICODE(item)[0];
- } else {
+ else {
/* do we need more space? */
- int need = j + reslen + len-i-1;
+ int need = j + reslen + len - i - 1;
if (need > outlen) {
- /* overallocate, to avoid reallocations */
- if (need<2*outlen)
- need = 2*outlen;
+ /* overallocate,
+ to avoid reallocations */
+ if (need < 2 * outlen)
+ need = 2 * outlen;
if (PyUnicode_Resize(&result, need)) {
Py_DECREF(item);
goto Fail_1;
}
outlen = need;
}
- memcpy(
- PyUnicode_AS_UNICODE(result) + j,
- PyUnicode_AS_UNICODE(item),
- reslen*sizeof(Py_UNICODE)
- );
+ memcpy(PyUnicode_AS_UNICODE(result) + j,
+ PyUnicode_AS_UNICODE(item),
+ reslen*sizeof(Py_UNICODE));
j += reslen;
}
}