fix crashes when pkt_id 1 is dropped (#33)
Signed-off-by: Tin Lai <tin@tinyiu.com> Co-authored-by: Tin Lai <tin@tinyiu.com>
This commit is contained in:
+1
-1
@@ -269,7 +269,7 @@ const deal_with_data = (session: Session, dv: DataView) => {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (session.curImage.length == 1) return; // header does not have markers
|
if (session.curImage.length <= 1) return; // header does not have markers
|
||||||
|
|
||||||
let lastFrameSlice = session.curImage[session.curImage.length - 1];
|
let lastFrameSlice = session.curImage[session.curImage.length - 1];
|
||||||
const lastResetMarker = findAllResetMarkers(lastFrameSlice).pop();
|
const lastResetMarker = findAllResetMarkers(lastFrameSlice).pop();
|
||||||
|
|||||||
Reference in New Issue
Block a user