Skip to content

Commit

Permalink
Revert test unicode_fromstring() change
Browse files Browse the repository at this point in the history
  • Loading branch information
vstinner committed Nov 1, 2023
1 parent 30bb725 commit 07975be
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions Modules/_testcapi/unicode.c
Original file line number Diff line number Diff line change
Expand Up @@ -301,12 +301,7 @@ unicode_fromstring(PyObject *self, PyObject *arg)
if (!PyArg_Parse(arg, "z#", &s, &size)) {
return NULL;
}
PyObject *unicode = PyUnicode_FromString(s);
if (unicode == NULL) {
return NULL;
}
assert(((PyASCIIObject*)unicode)->state.embed_null == 0);
return unicode;
return PyUnicode_FromString(s);
}

/* Test PyUnicode_FromKindAndData() */
Expand Down

0 comments on commit 07975be

Please sign in to comment.