[dracutlukscfg] Const data
The QLatin1String() might be replaced by char[], that trades one initialization for two but with a simpler data section; this probably is not worth profiling.
This commit is contained in:
parent
1f0aec5f87
commit
1f21b9ad73
@ -20,8 +20,7 @@
|
||||
|
||||
#include "utils/Logger.h"
|
||||
|
||||
// static
|
||||
const QLatin1String DracutLuksCfgJob::CONFIG_FILE( "/etc/dracut.conf.d/calamares-luks.conf" );
|
||||
static const QLatin1String CONFIG_FILE( "/etc/dracut.conf.d/calamares-luks.conf" );
|
||||
|
||||
static const char CONFIG_FILE_HEADER[]
|
||||
= "# Configuration file automatically written by the Calamares system installer\n"
|
||||
@ -36,9 +35,8 @@ static const char CONFIG_FILE_CRYPTTAB_KEYFILE_LINE[]
|
||||
static const char CONFIG_FILE_CRYPTTAB_LINE[] = "# force installing /etc/crypttab even if hostonly=\"no\"\n"
|
||||
"install_items+=\" /etc/crypttab \"\n";
|
||||
|
||||
// static
|
||||
const QLatin1String DracutLuksCfgJob::CONFIG_FILE_SWAPLINE(
|
||||
"# enable automatic resume from swap\nadd_device+=\" /dev/disk/by-uuid/%1 \"\n" );
|
||||
static const QLatin1String
|
||||
CONFIG_FILE_SWAPLINE( "# enable automatic resume from swap\nadd_device+=\" /dev/disk/by-uuid/%1 \"\n" );
|
||||
|
||||
static QString
|
||||
rootMountPoint()
|
||||
|
@ -33,8 +33,6 @@ public:
|
||||
Calamares::JobResult exec() override;
|
||||
|
||||
private:
|
||||
static const QLatin1String CONFIG_FILE;
|
||||
static const QLatin1String CONFIG_FILE_SWAPLINE;
|
||||
};
|
||||
|
||||
CALAMARES_PLUGIN_FACTORY_DECLARATION( DracutLuksCfgJobFactory )
|
||||
|
Loading…
Reference in New Issue
Block a user