Skip to content

Commit

Permalink
Make -loop survive errors.
Browse files Browse the repository at this point in the history
This is otherwise rather annoying when testing things against a browser
which will usually throw up a cert error or so.

Change-Id: Ia587efae65764430e39e3eb604e434b5919530cb
Reviewed-on: https://boringssl-review.googlesource.com/15126
Commit-Queue: Steven Valdez <[email protected]>
Reviewed-by: Steven Valdez <[email protected]>
CQ-Verified: CQ bot account: [email protected] <[email protected]>
  • Loading branch information
davidben authored and CQ bot account: [email protected] committed Apr 17, 2017
1 parent 8c62d9d commit 1ddd6e5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tool/server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -250,14 +250,15 @@ bool Server(const std::vector<std::string> &args) {
int ssl_err = SSL_get_error(ssl.get(), ret);
fprintf(stderr, "Error while connecting: %d\n", ssl_err);
ERR_print_errors_cb(PrintErrorCallback, stderr);
return false;
result = false;
continue;
}

fprintf(stderr, "Connected.\n");
PrintConnectionInfo(ssl.get());

result = TransferData(ssl.get(), sock);
} while (result && args_map.count("-loop") != 0);
} while (args_map.count("-loop") != 0);

return result;
}

0 comments on commit 1ddd6e5

Please sign in to comment.