Fit in 80 symbols per line
This commit is contained in:
14
src/rmps.c
14
src/rmps.c
@@ -180,15 +180,20 @@ static int open_listener(int port)
|
||||
}
|
||||
if (set_reuse_addr(sd) < 0) {
|
||||
log(ERROR,
|
||||
"Failed to set reuse on address - Aborting RMPS...", port);
|
||||
"Failed to set reuse on address - Aborting RMPS...",
|
||||
port);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
if (bind(sd, (struct sockaddr *)&addr, sizeof(addr)) != 0) {
|
||||
log(ERROR, "Failed to bind on port: %d - Aborting RMPS...", port);
|
||||
log(ERROR,
|
||||
"Failed to bind on port: %d - Aborting RMPS...",
|
||||
port);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
if (listen(sd, 10) != 0) {
|
||||
log(ERROR, "Failed to start listener on port %d - Aborting RMPS...", port);
|
||||
log(ERROR,
|
||||
"Failed to start listener on port %d - Aborting RMPS...",
|
||||
port);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
return sd;
|
||||
@@ -231,7 +236,8 @@ void load_certificates(SSL_CTX *ctx, const char *certfile,
|
||||
const char *keyfile, const char *cafile)
|
||||
{
|
||||
/* set the local certificate from certfile */
|
||||
if (SSL_CTX_use_certificate_file(ctx, certfile, SSL_FILETYPE_PEM) <= 0) {
|
||||
if (SSL_CTX_use_certificate_file(ctx, certfile,
|
||||
SSL_FILETYPE_PEM) <= 0) {
|
||||
log(ERROR, "Failed to load certfile! SSL error below:");
|
||||
log_ssl();
|
||||
log(INFO, "RMPS failed to start, shutting down...");
|
||||
|
||||
Reference in New Issue
Block a user