Skip to content

Commit

Permalink
Silence the scary warning for a less scary warning
Browse files Browse the repository at this point in the history
  • Loading branch information
pyamsoft committed Feb 7, 2024
1 parent a40b0b4 commit 7611478
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pstate-frequency
Original file line number Diff line number Diff line change
Expand Up @@ -1301,11 +1301,13 @@ root_write_turbo() {
root_write_turbo__target=""
fi
else
log_verbose "Turbo boost is unsupported on your CPU platform."
log_verbose "Could not find turbo information from ANY expected locations."
root_write_turbo__target=""
fi

if [ -w "${root_write_turbo__target}" ]; then
if [ -z "${root_write_turbo__target}" ]; then
elog "Turbo boost is unsupported on your CPU platform."
elif [ -w "${root_write_turbo__target}" ]; then
log_verbose "Write turbo_value '%s' to file: %s" "${root_write_turbo__turbo}" "${root_write_turbo__target}"
printf -- "%s" "${root_write_turbo__turbo}" >"${root_write_turbo__target}" || return 1
log_all "Turbo value written to %s" "${root_write_turbo__target}"
Expand Down

0 comments on commit 7611478

Please sign in to comment.