diff --git a/uhubctl.c b/uhubctl.c index c8adf43..718f9d9 100644 --- a/uhubctl.c +++ b/uhubctl.c @@ -1232,7 +1232,7 @@ int main(int argc, char *argv[]) int ports = ((1 << hubs[i].nports) - 1) & opt_ports; int should_be_on = k; if (opt_action == POWER_FLASH) { - k = !k; + should_be_on = !should_be_on; } int port;