Skip to content

Commit 1ff192b

Browse files
committed
Resolves clamp is not a member of std error with Buster build.
* https://gitlab.com/CalcProgrammer1/OpenRGB/-/jobs/3359116111#L207
1 parent ce5ab1c commit 1ff192b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

cli.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -637,7 +637,7 @@ bool OptionBrightness(int* currentDev, std::string argument, Options* options)
637637
}
638638

639639
DeviceOptions* currentDevOpts = GetDeviceOptionsForDevID(options, *currentDev);
640-
currentDevOpts->brightness = std::clamp(std::stoi(argument), 0, (int)brightness_percentage);
640+
currentDevOpts->brightness = std::min(std::max(std::stoi(argument), 0),(int)brightness_percentage);
641641
currentDevOpts->hasOption = true;
642642
return true;
643643
}

0 commit comments

Comments
 (0)