Ror() & Rol() bugged on Linux
Posted: Tue Apr 27, 2021 10:18 am
Hello Andreas,
I took me 2 days to identify why my encryption routines worked on Windows but not on Linux (Linux Mint 9, x64).
Finally I've found a small script that demonstrate the bug:
Run on Windows and you get:
Compile and run on Linux and you get:
btw setting 'b' with a smaller value (for example 5) it works the same way on both Windows & Linux
I took me 2 days to identify why my encryption routines worked on Windows but not on Linux (Linux Mint 9, x64).
Finally I've found a small script that demonstrate the bug:
Code: Select all
Local a = 72
Local b = 111
Local c = Ror(a, b, #BYTE)
DebugPrint(a .. " ror " .. b .. " = " .. c)
DebugPrompt("?")
Code: Select all
72 ror 111 = 144
?
Code: Select all
72 ror 111 = 0
?