network/http-launch: Disconnect clients if there was no valid HTTP request after 1MB of data

This commit is contained in:
Sebastian Dröge 2013-07-28 18:38:01 +02:00
parent 9228d05bf3
commit e38e9ce609

View file

@ -220,7 +220,11 @@ on_read_bytes (GPollableInputStream * stream, Client * client)
}
}
/* FIXME: If too large, disconnect client */
if (client->current_message->len >= 1024 * 1024) {
g_print ("No complete request after 1MB of data\n");
remove_client (client);
return FALSE;
}
return TRUE;
} else {