mirror of
https://github.com/ashaduri/gsmartcontrol.git
synced 2026-09-25 21:35:33 +00:00
Use pkexec --disable-internal-agent for polkit.
Don't warn on Unknown property "Form Factor".
This commit is contained in:
@@ -28,9 +28,6 @@ Bugs / patches:
|
||||
|
||||
TODO:
|
||||
|
||||
Implement PolKit support.
|
||||
|
||||
|
||||
|
||||
Don't rely on smartctl return code (2), parse the output instead.
|
||||
This will allow us to show the Info page.
|
||||
|
||||
@@ -138,7 +138,7 @@ if [ "$GSMARTCONTROL_SU" != "" ]; then
|
||||
full_cmd="$GSMARTCONTROL_SU '$EXEC_BIN $final_args_quoted'";
|
||||
|
||||
elif [ "$found_su" = "pkexec" ]; then
|
||||
full_cmd="pkexec '$EXEC_BIN $final_args_quoted'";
|
||||
full_cmd="pkexec --disable-internal-agent '$EXEC_BIN $final_args_quoted'";
|
||||
|
||||
elif [ "$found_su" = "sux" ]; then
|
||||
full_cmd="xterm -e sux -c '$EXEC_BIN $final_args_quoted'";
|
||||
|
||||
@@ -483,6 +483,11 @@ bool SmartctlParser::parse_section_info_property(StorageProperty& p)
|
||||
p.value_type = StorageProperty::value_type_string;
|
||||
p.value_string = p.reported_value;
|
||||
|
||||
} else if (app_pcre_match("/^Form Factor$/mi", p.reported_name)) {
|
||||
p.set_name(p.reported_name, "form_factor", "Form Factor");
|
||||
p.value_type = StorageProperty::value_type_string;
|
||||
p.value_string = p.reported_value;
|
||||
|
||||
} else if (app_pcre_match("/^Device is$/mi", p.reported_name)) {
|
||||
p.set_name(p.reported_name, "in_smartctl_db", "In Smartctl Database");
|
||||
p.value_type = StorageProperty::value_type_bool;
|
||||
|
||||
Reference in New Issue
Block a user