We need to initialise SSL before reading the main config Fixes #646
Fix potential NULL dereference found by scan
Only check if were building with libssl