From 7459f49168be18b2f8e7348ec402bd07e5e5386a Mon Sep 17 00:00:00 2001 From: dimok789 Date: Fri, 25 Mar 2016 09:49:44 +0100 Subject: [PATCH] fixed bugged when downloading bigger files than 65kb from the WiiU --- src/ftp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ftp.c b/src/ftp.c index 6200f8c..08638e6 100644 --- a/src/ftp.c +++ b/src/ftp.c @@ -824,8 +824,8 @@ static void process_data_events(client_t *client) { } else { result = client->data_callback(client->data_socket, client->data_connection_callback_arg); } - - if (result <= 0 && result != -EAGAIN) { + // stupid mess up in nintys code EAGAIN is sometimes -1 (recv, should be -11) and sometimes -11 (send) + if (result <= 0 && result != -EAGAIN && result != -11) { cleanup_data_resources(client); if (result < 0) { result = write_reply(client, 520, "Closing data connection, error occurred during transfer.");