summaryrefslogtreecommitdiff
blob: c957ad7aa29d22ac3606711fec77acec2b922ffc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
diff -Nur hiredis-0.2.0.orig/src/reader.c hiredis-0.2.0/src/reader.c
--- hiredis-0.2.0.orig/src/reader.c	2015-04-02 23:49:10.000000000 +0200
+++ hiredis-0.2.0/src/reader.c	2020-04-01 13:26:50.504058251 +0200
@@ -157,7 +157,7 @@
 };
 
 static void Reader_dealloc(hiredis_ReaderObject *self) {
-    redisReplyReaderFree(self->reader);
+    redisReaderFree(self->reader);
     if (self->encoding)
         free(self->encoding);
     Py_XDECREF(self->protocolErrorClass);
@@ -267,7 +267,7 @@
       goto error;
     }
 
-    redisReplyReaderFeed(self->reader, (char *)buf.buf + off, len);
+    redisReaderFeed(self->reader, (char *)buf.buf + off, len);
     PyBuffer_Release(&buf);
     Py_RETURN_NONE;
 
@@ -281,8 +281,8 @@
     PyObject *err;
     char *errstr;
 
-    if (redisReplyReaderGetReply(self->reader, (void**)&obj) == REDIS_ERR) {
-        errstr = redisReplyReaderGetError(self->reader);
+    if (redisReaderGetReply(self->reader, (void**)&obj) == REDIS_ERR) {
+        errstr = redisReaderGetError(self->reader);
         /* protocolErrorClass might be a callable. call it, then use it's type */
         err = createError(self->protocolErrorClass, errstr, strlen(errstr));
         obj = PyObject_Type(err);