summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc-André Lemburg <mal@egenix.com>2002-02-06 18:18:03 (GMT)
committerMarc-André Lemburg <mal@egenix.com>2002-02-06 18:18:03 (GMT)
commite7c6ee4b8a9b7e043d507b85b99148a397c996d9 (patch)
treead1a3e85024093ac1814258455d087c9f880b949
parent3688a882d36fe60be85a9dc8a54d033de356da31 (diff)
downloadcpython-e7c6ee4b8a9b7e043d507b85b99148a397c996d9.zip
cpython-e7c6ee4b8a9b7e043d507b85b99148a397c996d9.tar.gz
cpython-e7c6ee4b8a9b7e043d507b85b99148a397c996d9.tar.bz2
Whitespace fixes.
-rw-r--r--Objects/unicodeobject.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index c7e5c8a..a67caa3 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -1203,9 +1203,9 @@ PyObject *PyUnicode_EncodeUTF8(const Py_UNICODE *s,
if (cbWritten >= cbAllocated) {
cbAllocated += 4 * 10;
if (_PyString_Resize(&v, cbAllocated + 4))
- goto onError;
+ goto onError;
p = PyString_AS_STRING(v) + cbWritten;
- }
+ }
if (ch < 0x10000) {
/* Check for high surrogate */
@@ -1225,19 +1225,19 @@ PyObject *PyUnicode_EncodeUTF8(const Py_UNICODE *s,
/* Fall through: handles isolated high surrogates */
}
*p++ = (char)(0xe0 | (ch >> 12));
- *p++ = (char)(0x80 | ((ch >> 6) & 0x3f));
- *p++ = (char)(0x80 | (ch & 0x3f));
+ *p++ = (char)(0x80 | ((ch >> 6) & 0x3f));
+ *p++ = (char)(0x80 | (ch & 0x3f));
cbWritten += 3;
- } else {
- *p++ = 0xf0 | (ch>>18);
- *p++ = 0x80 | ((ch>>12) & 0x3f);
- *p++ = 0x80 | ((ch>>6) & 0x3f);
- *p++ = 0x80 | (ch & 0x3f);
- cbWritten += 4;
+ } else {
+ *p++ = 0xf0 | (ch>>18);
+ *p++ = 0x80 | ((ch>>12) & 0x3f);
+ *p++ = 0x80 | ((ch>>6) & 0x3f);
+ *p++ = 0x80 | (ch & 0x3f);
+ cbWritten += 4;
+ }
}
}
- }
*p = '\0';
if (_PyString_Resize(&v, cbWritten))
goto onError;