Fix for example client to send HTTP GET on resume with "-g". Fixes issue with ./scripts/openssl.test.

This commit is contained in:
David Garske
2020-07-21 15:42:33 -07:00
parent 639f73fe1f
commit 11b0d963d3

View File

@ -3419,8 +3419,16 @@ THREAD_RETURN WOLFSSL_THREAD client_test(void* args)
} }
#endif /* HAVE_SECURE_RENEGOTIATION */ #endif /* HAVE_SECURE_RENEGOTIATION */
(void)ClientWrite(sslResume, kResumeMsg, (int)XSTRLEN(kResumeMsg), XMEMSET(msg, 0, sizeof(msg));
" resume", 0); if (sendGET) {
msgSz = (int)XSTRLEN(kHttpGetMsg);
XMEMCPY(msg, kHttpGetMsg, msgSz);
}
else {
msgSz = (int)XSTRLEN(kResumeMsg);
XMEMCPY(msg, kResumeMsg, msgSz);
}
(void)ClientWrite(sslResume, msg, msgSz, " resume", 0);
(void)ClientRead(sslResume, reply, sizeof(reply)-1, sendGET, (void)ClientRead(sslResume, reply, sizeof(reply)-1, sendGET,
"Server resume: ", 0); "Server resume: ", 0);