Init bool value in header and do not init qstring attributes with empty value

This commit is contained in:
Blottiere Paul 2017-08-30 07:43:37 +01:00
parent 622fbfdc8f
commit 05eeb87cda
2 changed files with 4 additions and 9 deletions

View File

@ -261,10 +261,7 @@ bool QgsAuxiliaryLayer::save()
//
QgsAuxiliaryStorage::QgsAuxiliaryStorage( const QgsProject &project, bool copy )
: mValid( false )
, mFileName( QString() )
, mTmpFileName( QString() )
, mCopy( copy )
: mCopy( copy )
{
initTmpFileName();
@ -278,9 +275,7 @@ QgsAuxiliaryStorage::QgsAuxiliaryStorage( const QgsProject &project, bool copy )
}
QgsAuxiliaryStorage::QgsAuxiliaryStorage( const QString &filename, bool copy )
: mValid( false )
, mFileName( filename )
, mTmpFileName( QString() )
: mFileName( filename )
, mCopy( copy )
{
initTmpFileName();

View File

@ -305,10 +305,10 @@ class CORE_EXPORT QgsAuxiliaryStorage
static bool exec( const QString &sql, sqlite3 *handler );
static void debugMsg( const QString &sql, sqlite3 *handler );
bool mValid;
bool mValid = false;
QString mFileName; // original filename
QString mTmpFileName; // temporary filename used in copy mode
bool mCopy;
bool mCopy = false;
};
#endif