summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2007-10-04 06:00:48 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2007-10-04 06:00:48 (GMT)
commit6ba1a5f51b94b9af0aeb27ba6d4f8f50be0b5bbf (patch)
treea715d232cc1568534eea8aa7d89420716c22d58a /Objects
parente3fde8f8cd8baf8f82469f2f2f1f2c2e19bfb2c7 (diff)
downloadcpython-6ba1a5f51b94b9af0aeb27ba6d4f8f50be0b5bbf.zip
cpython-6ba1a5f51b94b9af0aeb27ba6d4f8f50be0b5bbf.tar.gz
cpython-6ba1a5f51b94b9af0aeb27ba6d4f8f50be0b5bbf.tar.bz2
Coverity #151: Remove deadcode.
All this code already exists above starting at line 653.
Diffstat (limited to 'Objects')
-rw-r--r--Objects/bufferobject.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/Objects/bufferobject.c b/Objects/bufferobject.c
index 13442c9..e01938c 100644
--- a/Objects/bufferobject.c
+++ b/Objects/bufferobject.c
@@ -682,19 +682,6 @@ buffer_ass_subscript(PyBufferObject *self, PyObject *item, PyObject *value)
&start, &stop, &step, &slicelength) < 0)
return -1;
- pb = value ? value->ob_type->tp_as_buffer : NULL;
- if (pb == NULL ||
- pb->bf_getreadbuffer == NULL ||
- pb->bf_getsegcount == NULL) {
- PyErr_BadArgument();
- return -1;
- }
- if ((*pb->bf_getsegcount)(value, NULL) != 1) {
- /* ### use a different exception type/message? */
- PyErr_SetString(PyExc_TypeError,
- "single-segment buffer object expected");
- return -1;
- }
if ((othersize = (*pb->bf_getreadbuffer)(value, 0, &ptr2)) < 0)
return -1;