Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
htop
Commits
28a5859f
Commit
28a5859f
authored
Aug 24, 2018
by
Hisham Muhammad
Browse files
Settings: fix storage of screens in htoprc
parent
0939e5cb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Settings.c
View file @
28a5859f
...
...
@@ -361,6 +361,7 @@ static bool Settings_read(Settings* this, const char* fileName) {
didReadMeters
=
true
;
}
else
if
(
strncmp
(
option
[
0
],
"screen:"
,
7
)
==
0
)
{
Settings_newScreen
(
this
,
option
[
0
]
+
7
,
option
[
1
]);
didReadFields
=
true
;
}
else
if
(
String_eq
(
option
[
0
],
".tree_view"
))
{
if
(
this
->
nScreens
>
0
)
{
this
->
screens
[
this
->
nScreens
-
1
]
->
treeView
=
atoi
(
option
[
1
]);
...
...
@@ -380,6 +381,7 @@ static bool Settings_read(Settings* this, const char* fileName) {
if
(
this
->
nScreens
==
0
)
{
Settings_defaultScreens
(
this
);
if
(
legacyFieldsRead
)
{
didReadFields
=
true
;
free
(
this
->
screens
[
0
]
->
fields
);
this
->
screens
[
0
]
->
fields
=
legacyFields
;
this
->
screens
[
0
]
->
flags
=
legacyFlags
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment