summaryrefslogtreecommitdiffstats
path: root/Python/pystrhex.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2017-11-28 15:56:10 (GMT)
committerGitHub <noreply@github.com>2017-11-28 15:56:10 (GMT)
commit598ceae876ff4a23072e59945597e945583de4ab (patch)
treea7c0c1380c40bda01c70b8bd40ba47d1b2f6d54a /Python/pystrhex.c
parent08d2b86a1058b733bb7f1ae2b55818dd9687d21c (diff)
downloadcpython-598ceae876ff4a23072e59945597e945583de4ab.zip
cpython-598ceae876ff4a23072e59945597e945583de4ab.tar.gz
cpython-598ceae876ff4a23072e59945597e945583de4ab.tar.bz2
bpo-32150: Expand tabs to spaces in C files. (#4583)
Diffstat (limited to 'Python/pystrhex.c')
-rw-r--r--Python/pystrhex.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/Python/pystrhex.c b/Python/pystrhex.c
index 1259ed1..6dbf32d 100644
--- a/Python/pystrhex.c
+++ b/Python/pystrhex.c
@@ -16,14 +16,14 @@ static PyObject *_Py_strhex_impl(const char* argbuf, const Py_ssize_t arglen,
if (return_bytes) {
/* If _PyBytes_FromSize() were public we could avoid malloc+copy. */
retbuf = (Py_UCS1*) PyMem_Malloc(arglen*2);
- if (!retbuf)
- return PyErr_NoMemory();
+ if (!retbuf)
+ return PyErr_NoMemory();
retval = NULL; /* silence a compiler warning, assigned later. */
} else {
- retval = PyUnicode_New(arglen*2, 127);
- if (!retval)
- return NULL;
- retbuf = PyUnicode_1BYTE_DATA(retval);
+ retval = PyUnicode_New(arglen*2, 127);
+ if (!retval)
+ return NULL;
+ retbuf = PyUnicode_1BYTE_DATA(retval);
}
/* make hex version of string, taken from shamodule.c */