From 62bcedced863a9c4ecc3601638635dfe172a9130 Mon Sep 17 00:00:00 2001 From: Matt Colyer Date: Mon, 4 Aug 2008 23:41:56 -0700 Subject: Zack's C. rewrite of usbmux (with a few additions by Matt Colyer). --- src/iphone.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/iphone.c') diff --git a/src/iphone.c b/src/iphone.c index e4acea9..aa9687c 100644 --- a/src/iphone.c +++ b/src/iphone.c @@ -171,10 +171,11 @@ int send_to_phone(iPhone *phone, char *data, int datalen) { int recv_from_phone(iPhone *phone, char *data, int datalen) { if (!phone) return -1; int bytes = 0; + if (debug) printf("recv_from_phone(): attempting to receive %i bytes\n", datalen); bytes = usb_bulk_read(phone->device, BULKIN, data, datalen, 3500); if(bytes < 0) { - if(debug) printf("recv_from_iphone(): libusb gave me the error %d: %s (%s)\n", bytes, usb_strerror(), strerror(-bytes)); + if(debug) printf("recv_from_phone(): libusb gave me the error %d: %s (%s)\n", bytes, usb_strerror(), strerror(-bytes)); return -1; } return bytes; -- cgit v1.1-32-gdbae