Commit fa1c36dd authored by Sylvain Berfini's avatar Sylvain Berfini 🎩

Use /usr/share/linphone/rootca.pem if there is no /etc/ssl/certs directory on linux

parent 4a044336
......@@ -867,7 +867,13 @@ static void certificates_config_read(LinphoneCore *lc)
{
const char *rootca;
#ifdef __linux
struct stat sb;
rootca=lp_config_get_string(lc->config,"sip","root_ca", "/etc/ssl/certs");
if (stat("/etc/ssl/certs", &sb) != 0 || !S_ISDIR(sb.st_mode))
{
ms_warning("/etc/ssl/certs not found, using %s instead", ROOT_CA_FILE);
rootca=lp_config_get_string(lc->config,"sip","root_ca", ROOT_CA_FILE);
}
#else
rootca=lp_config_get_string(lc->config,"sip","root_ca", ROOT_CA_FILE);
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment