Skip to content

Commit

Permalink
Fix fallback panel handling (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhen-zen authored May 17, 2021
1 parent d4a9538 commit 74d7369
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion BrightnessKeys/BrightnessKeys.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ void BrightnessKeys::getBrightnessPanel() {
//
// Some vendors just won't follow the specs and update their code
//
if (strncmp(_panel->getName(), "DD02", strlen("DD02"))) {
if (_panel == nullptr || strncmp(_panel->getName(), "DD02", strlen("DD02"))) {
auto fallbackPanel = info->videoBuiltin->childFromPath("DD02", gIODTPlane);
if (fallbackPanel != nullptr) {
_panelFallback = getAcpiDevice(fallbackPanel);
Expand Down

0 comments on commit 74d7369

Please sign in to comment.