diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2018-10-31 00:28:07 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-31 00:28:07 (GMT) |
commit | 0353b4eaaf451ad463ce7eb3074f6b62d332f401 (patch) | |
tree | ee6c8d6f8368ae88711440e187aaa7294f423f6c /Modules/_lzmamodule.c | |
parent | 3f819ca138db6945ee4271bf13e42db9f9b3b1e4 (diff) | |
download | cpython-0353b4eaaf451ad463ce7eb3074f6b62d332f401.zip cpython-0353b4eaaf451ad463ce7eb3074f6b62d332f401.tar.gz cpython-0353b4eaaf451ad463ce7eb3074f6b62d332f401.tar.bz2 |
bpo-33138: Change standard error message for non-pickleable and non-copyable types. (GH-6239)
Diffstat (limited to 'Modules/_lzmamodule.c')
-rw-r--r-- | Modules/_lzmamodule.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/Modules/_lzmamodule.c b/Modules/_lzmamodule.c index bb7a7ec..b5f9561 100644 --- a/Modules/_lzmamodule.c +++ b/Modules/_lzmamodule.c @@ -591,14 +591,6 @@ _lzma_LZMACompressor_flush_impl(Compressor *self) return result; } -static PyObject * -Compressor_getstate(Compressor *self, PyObject *noargs) -{ - PyErr_Format(PyExc_TypeError, "cannot serialize '%s' object", - Py_TYPE(self)->tp_name); - return NULL; -} - static int Compressor_init_xz(lzma_stream *lzs, int check, uint32_t preset, PyObject *filterspecs) @@ -794,7 +786,6 @@ Compressor_dealloc(Compressor *self) static PyMethodDef Compressor_methods[] = { _LZMA_LZMACOMPRESSOR_COMPRESS_METHODDEF _LZMA_LZMACOMPRESSOR_FLUSH_METHODDEF - {"__getstate__", (PyCFunction)Compressor_getstate, METH_NOARGS}, {NULL} }; @@ -1078,14 +1069,6 @@ _lzma_LZMADecompressor_decompress_impl(Decompressor *self, Py_buffer *data, return result; } -static PyObject * -Decompressor_getstate(Decompressor *self, PyObject *noargs) -{ - PyErr_Format(PyExc_TypeError, "cannot serialize '%s' object", - Py_TYPE(self)->tp_name); - return NULL; -} - static int Decompressor_init_raw(lzma_stream *lzs, PyObject *filterspecs) { @@ -1235,7 +1218,6 @@ Decompressor_dealloc(Decompressor *self) static PyMethodDef Decompressor_methods[] = { _LZMA_LZMADECOMPRESSOR_DECOMPRESS_METHODDEF - {"__getstate__", (PyCFunction)Decompressor_getstate, METH_NOARGS}, {NULL} }; |