fix #2565 by inverting the grb2hsv argcheck condition (#3076)

This commit is contained in:
firenox89 2020-04-26 14:56:41 +02:00 committed by Marcel Stör
parent c50b4789c4
commit fd26dea949
1 changed files with 1 additions and 1 deletions

View File

@ -217,7 +217,7 @@ static int cu_grb2hsv(lua_State *L) {
const int r = luaL_checkint(L, 2);
const int b = luaL_checkint(L, 3);
luaL_argcheck(L, g == r && g == b, 1, "greyscale value cannot be converted to hsv");
luaL_argcheck(L, g != r || g != b, 1, "greyscale value cannot be converted to hsv");
uint32_t hsv = grb2hsv(g, r, b);