sxmp: deprecated use if sys_strerror removed;

master
Alexander Vdolainen 8 years ago
parent cc5cd0a1e0
commit 9e3da0fd3f

@ -657,17 +657,17 @@ int sxhub_setsslserts(sxhub_t *ssys, const char *rootca,
/* check on existence of certificate files */ /* check on existence of certificate files */
if (access(rootca, R_OK) == -1) { if (access(rootca, R_OK) == -1) {
ssys->log(SXERROR_LOG, "Unable to read rootca file '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to read rootca file '%s': %s\n",
rootca, sys_errlist[errno]); rootca, strerror(errno));
return ENOENT; return ENOENT;
} }
if (access(certpem, R_OK) == -1) { if (access(certpem, R_OK) == -1) {
ssys->log(SXERROR_LOG, "Unable to read certpem file '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to read certpem file '%s': %s\n",
certpem, sys_errlist[errno]); certpem, strerror(errno));
return ENOENT; return ENOENT;
} }
if (access(certkey, R_OK) == -1) { if (access(certkey, R_OK) == -1) {
ssys->log(SXERROR_LOG, "Unable to read certkey file '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to read certkey file '%s': %s\n",
certkey, sys_errlist[errno]); certkey, strerror(errno));
return ENOENT; return ENOENT;
} }
@ -675,19 +675,19 @@ int sxhub_setsslserts(sxhub_t *ssys, const char *rootca,
int r; int r;
if (NULL == (ssys->rootca = realpath(rootca, NULL))) { if (NULL == (ssys->rootca = realpath(rootca, NULL))) {
ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n",
rootca, sys_errlist[errno]); rootca, strerror(errno));
if (errno == ENOMEM) r = errno; if (errno == ENOMEM) r = errno;
goto __fail; goto __fail;
} }
if (NULL == (ssys->certpem = realpath(certpem, NULL))) { if (NULL == (ssys->certpem = realpath(certpem, NULL))) {
ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n",
certpem, sys_errlist[errno]); certpem, strerror(errno));
if (errno == ENOMEM) r = errno; if (errno == ENOMEM) r = errno;
goto __fail; goto __fail;
} }
if (NULL == (ssys->certkey = realpath(certkey, NULL))) { if (NULL == (ssys->certkey = realpath(certkey, NULL))) {
ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n", ssys->log(SXERROR_LOG, "Unable to obtain the full path of '%s': %s\n",
certkey, sys_errlist[errno]); certkey, strerror(errno));
if (errno == ENOMEM) r = errno; if (errno == ENOMEM) r = errno;
goto __fail; goto __fail;
} }

Loading…
Cancel
Save