diff options
author | Amaury Forgeot d'Arc <amauryfa@gmail.com> | 2008-04-24 18:23:22 (GMT) |
---|---|---|
committer | Amaury Forgeot d'Arc <amauryfa@gmail.com> | 2008-04-24 18:23:22 (GMT) |
commit | ae0b088f6ca4156e7f8ee32fda0264f676f3d6b3 (patch) | |
tree | dfca78d8f8c57849d29f1d15c83fda0840871718 | |
parent | be5229ec0453e5ee9d3932e8e532492936a20845 (diff) | |
download | cpython-ae0b088f6ca4156e7f8ee32fda0264f676f3d6b3.zip cpython-ae0b088f6ca4156e7f8ee32fda0264f676f3d6b3.tar.gz cpython-ae0b088f6ca4156e7f8ee32fda0264f676f3d6b3.tar.bz2 |
There is no reason for imp.get_magic() to return a mutable bytearray
-rw-r--r-- | Python/import.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/import.c b/Python/import.c index 5b96cea..8b11aad 100644 --- a/Python/import.c +++ b/Python/import.c @@ -2686,7 +2686,7 @@ imp_get_magic(PyObject *self, PyObject *noargs) buf[2] = (char) ((pyc_magic >> 16) & 0xff); buf[3] = (char) ((pyc_magic >> 24) & 0xff); - return PyBytes_FromStringAndSize(buf, 4); + return PyString_FromStringAndSize(buf, 4); } static PyObject * |