From a4d22e27c6fa5b78186804ba547e94b97b2925b4 Mon Sep 17 00:00:00 2001 From: Martin Szulecki Date: Wed, 4 Jul 2012 21:29:22 +0200 Subject: Only send another ZLP if requested or regular uploads are broken --- libirecovery.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libirecovery.c b/libirecovery.c index 6be2319..f92cc50 100644 --- a/libirecovery.c +++ b/libirecovery.c @@ -1023,8 +1023,10 @@ irecv_error_t irecv_send_buffer(irecv_client_t client, unsigned char* buffer, un } } - // we send a pseudo ZLP here just in case - irecv_control_transfer(client, 0x21, 1, 0, 0, 0, 0, USB_TIMEOUT); + if (dfuNotifyFinished == 2) { + // we send a pseudo ZLP here just in case + irecv_control_transfer(client, 0x21, 1, 0, 0, 0, 0, USB_TIMEOUT); + } irecv_reset(client); } -- cgit v1.1-32-gdbae