Created
July 17, 2012 15:01
-
-
Save freespace/3129907 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 207ed833c4de43fa29dcbd97a3d1a7494bd9d3cc Mon Sep 17 00:00:00 2001 | |
From: Shu Ning Bian <[email protected]> | |
Date: Wed, 18 Jul 2012 00:57:48 +1000 | |
Subject: [PATCH] Restores stub drain function to avrisp2 | |
--- | |
avrdude/usb_libusb.c | 7 ++++++- | |
1 file changed, 6 insertions(+), 1 deletion(-) | |
diff --git a/avrdude/usb_libusb.c b/avrdude/usb_libusb.c | |
index 2bb34b0..9add4f4 100644 | |
--- a/avrdude/usb_libusb.c | |
+++ b/avrdude/usb_libusb.c | |
@@ -445,6 +445,11 @@ static int usbdev_recv_frame(union filedescriptor *fd, unsigned char *buf, size_ | |
return n; | |
} | |
+static int usbdev_drain_stub(union filedescriptor *fd, int display) | |
+{ | |
+ return 0; | |
+} | |
+ | |
static int usbdev_drain(union filedescriptor *fd, int display) | |
{ | |
usb_dev_handle *udev = (usb_dev_handle *)fd->usb.handle; | |
@@ -482,7 +487,7 @@ struct serial_device usb_serdev_frame = | |
.close = usbdev_close, | |
.send = usbdev_send, | |
.recv = usbdev_recv_frame, | |
- .drain = usbdev_drain, | |
+ .drain = usbdev_drain_stub, | |
.flags = SERDEV_FL_NONE, | |
}; | |
-- | |
1.7.10.4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment