Topic: read one byte at a time
I am trying to use wolfSSL embedded SSL to implement a chunked encoding handler and my code seems to fail at this this point (after the socket has been set up and already used successfully):
char tbuff[64];
memset(tbuff,0,64);
recvLen = 0;
while (strstr(tbuff,"\r\n")==nullptr)
{
wolfSSL_read(cssl, buff, 1);
tbuff[recvLen] = buff[0];
recvLen+=1;
cout << tbuff << endl;
}
I realise the extreme inefficiency of this method to find a CRLF but is there any reason why CysSSL would fail here?
Thanks.