Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions dtls/client-dtls-cid.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ int main (int argc, char** argv)
if (readErr != SSL_ERROR_WANT_READ) {
printf("wolfSSL_read failed");
}
continue;
}

/* Add a terminating character to the generic server message */
Expand Down
1 change: 1 addition & 0 deletions dtls/client-dtls-ipv6.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ int main (int argc, char** argv)
if (readErr != SSL_ERROR_WANT_READ) {
printf("wolfSSL_read failed");
}
continue;
}

/* Add a terminating character to the generic server message */
Expand Down
9 changes: 5 additions & 4 deletions dtls/client-dtls.c
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,11 @@ int main (int argc, char** argv)
printf("wolfSSL_read failed");
}
}

/* Add a terminating character to the generic server message */
recvLine[n] = '\0';
fputs(recvLine, stdout);
else {
/* Add a terminating character to the generic server message */
recvLine[n] = '\0';
fputs(recvLine, stdout);
}
}
/* End code for sending datagram to server */
/*****************************************************************************/
Expand Down
1 change: 1 addition & 0 deletions dtls/client-dtls13-cid.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ int main (int argc, char** argv)
if (readErr != SSL_ERROR_WANT_READ) {
printf("wolfSSL_read failed");
}
continue;
}

/* Add a terminating character to the generic server message */
Expand Down
4 changes: 2 additions & 2 deletions dtls/memory-bio-dtls.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ static void* client_thread(void* args)
}

cli_ssl = wolfSSL_new(cli_ctx);
if (cli_ctx == NULL) {
if (cli_ssl == NULL) {
err_sys("bad client new");
}

Expand Down Expand Up @@ -170,7 +170,7 @@ int main()
}

srv_ssl = wolfSSL_new(srv_ctx);
if (srv_ctx == NULL) {
if (srv_ssl == NULL) {
err_sys("bad server new");
}

Expand Down
4 changes: 2 additions & 2 deletions tls/memory-tls.c
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ static void* client_thread(void* args)
wolfSSL_SetIORecv(cli_ctx, ClientRecv);

WOLFSSL* cli_ssl = wolfSSL_new(cli_ctx);
if (cli_ctx == NULL) err_sys("bad client new");
if (cli_ssl == NULL) err_sys("bad client new");

ret = wolfSSL_connect(cli_ssl);
if (ret != WOLFSSL_SUCCESS) err_sys("bad client tls connect");
Expand Down Expand Up @@ -185,7 +185,7 @@ int main()
wolfSSL_SetIORecv(srv_ctx, ServerRecv);

WOLFSSL* srv_ssl = wolfSSL_new(srv_ctx);
if (srv_ctx == NULL) err_sys("bad server new");
if (srv_ssl == NULL) err_sys("bad server new");

/* start client thread */
pthread_t tid;
Expand Down