diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2021-01-29 16:44:23 +0100 |
---|---|---|
committer | cgzones <cgzones@googlemail.com> | 2021-01-31 21:44:34 +0100 |
commit | 8bd543562b5b7495194e41a58162e7deb7bb41e3 (patch) | |
tree | e3e465cc54a72a7ac939cb3de448ef57cacd2773 /Settings.c | |
parent | 06b1674aa6202a91caf879fa4b0dae1244bf48b1 (diff) |
Quote SYSCONFDIR definition
As SYSCONFDIR is a compile time string literal, use compile time string
concatenation instead of a runtime one.
Also drop related TODO, cause we indeed using the correct way of getting
$sysconfdir from autoconf
Diffstat (limited to 'Settings.c')
-rw-r--r-- | Settings.c | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -424,10 +424,7 @@ Settings* Settings_new(int initialCpuCount) { } if (!ok) { this->changed = true; - // TODO: how to get SYSCONFDIR correctly through Autoconf? - char* systemSettings = String_cat(SYSCONFDIR, "/htoprc"); - ok = Settings_read(this, systemSettings, initialCpuCount); - free(systemSettings); + ok = Settings_read(this, SYSCONFDIR "/htoprc", initialCpuCount); } if (!ok) { Settings_defaultMeters(this, initialCpuCount); |