Ignore http GET data after the useful data.

The HTTP protocol is defined here: https://www.ietf.org/rfc/rfc2616.txt.

Short answer - the header lines are terminated with a CRLF, and they finish with a blank line, after which is the data.

However, you should always attempt to parse the Content-Length header, as an HTTP message can terminate with closing the channel, or a server can send HTTP messages back-to-back by giving the length of the data. If you don't do this, then you must send a 'Connection: close' header with your request so that the server knows to signal end of data by closing the tcp connection.