On Mon Aug 21 18:54:47 2023 +0000, Bartosz Kosiorek wrote:
Generally, we should checkout the return value of `GetDIBits`, like:
if (GetDIBits(screendc, iinfo.hbmColor, 0, height, lockeddata.Scan0, (BITMAPINFO*)&bih, DIB_RGB_COLORS)) {
and exit properly if it is fails (`DeleteDC`).
It does seem like a good idea to check the return value and respond appropriately. I think I can add such a check in a cleaner way in part 2, than in part 1.