Commits

Nikhil Marathe committed 1d30021

Simplified handle-single-reply, implemented dummy bulk handler

  • Participants
  • Parent commits 452912f

Comments (0)

Files changed (1)

     (reply 0)))
 
 (define (redis:handle-single-reply r)
-  (let (pos (find redis:CRLF (r 2)))
-    (if (nil? pos)
-      nil
-      (list (0 pos (r 2)) (+ pos (length redis:CRLF))))))
+  (letn ((trimm (chop (r 2) 2))
+         (message (1 trimm)))
+    (list message (length (r 2)))))
 
-(define (redis:ping r)
-  (:query r "PING"))
+(define (redis:handle-bulk-reply r)
+  (list (r 2) (length (r 2))))
 
 (define (redis:bgsave r)
   (:query r "BGSAVE"))