summaryrefslogtreecommitdiffstats
path: root/base.c
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2015-08-12 17:37:04 +0200
committerSuren A. Chilingaryan <csa@suren.me>2015-08-12 17:37:04 +0200
commitdc54794546c90f56a7399406c6a7baf9603ae07c (patch)
tree5dfd5e867a90808d0fb7a2bb25e96a79c0f11e4e /base.c
parenteea58e536bcc4b4fadf09e3c2ce29368d22e5a76 (diff)
downloadipecamera-dc54794546c90f56a7399406c6a7baf9603ae07c.tar.gz
ipecamera-dc54794546c90f56a7399406c6a7baf9603ae07c.tar.bz2
ipecamera-dc54794546c90f56a7399406c6a7baf9603ae07c.tar.xz
ipecamera-dc54794546c90f56a7399406c6a7baf9603ae07c.zip
Handle frame headers split between 2 packets
Diffstat (limited to 'base.c')
-rw-r--r--base.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/base.c b/base.c
index 1355486..1adc185 100644
--- a/base.c
+++ b/base.c
@@ -351,6 +351,10 @@ int ipecamera_start(pcilib_context_t *vctx, pcilib_event_t event_mask, pcilib_ev
ctx->parse_data = (flags&PCILIB_EVENT_FLAG_RAW_DATA_ONLY)?0:1;
ctx->cur_size = 0;
+#ifdef IPECAMERA_BUG_MULTIFRAME_HEADERS
+ ctx->saved_header_size = 0;
+#endif /* IPECAMERA_BUG_MULTIFRAME_HEADERS */
+
switch (ctx->firmware) {
case IPECAMERA_FIRMWARE_UFO5:
ctx->dim.width = CMOSIS_WIDTH;