Skip to content

Commit

Permalink
setHWRotation: nil guard self.forced_rotation
Browse files Browse the repository at this point in the history
  • Loading branch information
yparitcher committed Jan 15, 2024
1 parent 22ce561 commit 13ce8d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ffi/framebuffer_linux.lua
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ end

function framebuffer:setHWRotation(mode)
local vinfo = self._vinfo
vinfo.rotate = self.forced_rotation[mode+1] or mode
vinfo.rotate = self.forced_rotation and self.forced_rotation[mode+1] or mode
assert(C.ioctl(self.fd, C.FBIOPUT_VSCREENINFO, vinfo) == 0,
"cannot set variable screen info")
end
Expand Down

0 comments on commit 13ce8d3

Please sign in to comment.