drivers/display/lcd160cr: Add check that JPEG size is less than 65536.

pull/2921/head
Damien George 2017-02-27 18:39:35 +11:00
rodzic f4a12dca58
commit 528aeb3bf3
1 zmienionych plików z 2 dodań i 0 usunięć

Wyświetl plik

@ -446,6 +446,8 @@ class LCD160CR:
self._send(s)
def jpeg_start(self, l):
if l > 0xffff:
raise ValueError('length must be 65535 or less')
self.oflush()
self._fcmd2('<BBH', 0x6a, l)