Changeset 9739 in ntrip for trunk/BNC/src/bncsslconfig.cpp


Ignore:
Timestamp:
May 31, 2022, 2:42:18 PM (2 months ago)
Author:
stuerze
Message:

minor changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/bncsslconfig.cpp

    r8252 r9739  
    1111 * Created:    22-Aug-2011
    1212 *
    13  * Changes:   
     13 * Changes:
    1414 *
    1515 * -----------------------------------------------------------------------*/
     
    2424#include "bncsettings.h"
    2525
     26
     27// Singleton
     28////////////////////////////////////////////////////////////////////////////
     29bncSslConfig bncSslConfig::instance() {
     30  static bncSslConfig _sslConfig;
     31  return _sslConfig;
     32}
     33
    2634// Constructor
    2735////////////////////////////////////////////////////////////////////////////
    28 bncSslConfig::bncSslConfig() : 
    29   QSslConfiguration(QSslConfiguration::defaultConfiguration()) 
     36bncSslConfig::bncSslConfig() :
     37  QSslConfiguration(QSslConfiguration::defaultConfiguration())
    3038{
    31  
     39
    3240  bncSettings settings;
    3341  QString dirName = settings.value("sslCaCertPath").toString();
     
    5058    caCerts += QSslCertificate::fromPath(dirName+QDir::separator()+fileName);
    5159  }
    52  
     60
    5361  this->setCaCertificates(caCerts);
    5462}
     
    6270////////////////////////////////////////////////////////////////////////////
    6371QString bncSslConfig::defaultPath() {
    64   return QDir::homePath() + QDir::separator() 
     72  return QDir::homePath() + QDir::separator()
    6573         + ".config" + QDir::separator() + qApp->organizationName();
    6674}
Note: See TracChangeset for help on using the changeset viewer.