mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Issue #26764: Fixed SystemError in bytes.__rmod__.
This commit is contained in:
parent
cda80940ed
commit
c9a59e6e4f
2 changed files with 15 additions and 32 deletions
|
@ -3282,15 +3282,13 @@ bytes_methods[] = {
|
|||
};
|
||||
|
||||
static PyObject *
|
||||
bytes_mod(PyObject *self, PyObject *args)
|
||||
bytes_mod(PyObject *self, PyObject *arg)
|
||||
{
|
||||
if (self == NULL || !PyBytes_Check(self)) {
|
||||
PyErr_BadInternalCall();
|
||||
return NULL;
|
||||
if (!PyBytes_Check(self)) {
|
||||
Py_RETURN_NOTIMPLEMENTED;
|
||||
}
|
||||
|
||||
return _PyBytes_FormatEx(PyBytes_AS_STRING(self), PyBytes_GET_SIZE(self),
|
||||
args, 0);
|
||||
arg, 0);
|
||||
}
|
||||
|
||||
static PyNumberMethods bytes_as_number = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue