eric pouech (@epo) commented about dlls/kernel32/tests/process.c:
ok( ret, "Setting mode (%ld)\n", GetLastError()); ret = SetConsoleMode(hConOut, modeOut ^ 1); ok( ret, "Setting mode (%ld)\n", GetLastError());
sbi.dwCursorPosition.X ^= 1;
sbi.dwCursorPosition.Y ^= 1;
sbi.dwCursorPosition.X = (sbi.dwCursorPosition.X ^ 1) % sbi.dwSize.X;
sbi.dwCursorPosition.Y = (sbi.dwCursorPosition.Y ^ 1) % sbi.dwSize.Y;
afaict, there's no explicit check to avoid 0 sized screen buffers in either dimension (right click inside a console let you change window&sb size to eg. (0,1)) so I'm not 100% confident that the modular operation will not yield a division by zero exception
perhaps something like (untested) ``` sbi.dwCursorPosition.X = !sbi.dwCursorPosition.X; ``` would be sufficient (the test only checks in parent that it gets same position as the one set by child)