diff options
author | Suren A. Chilingaryan <csa@suren.me> | 2015-05-01 19:21:14 +0200 |
---|---|---|
committer | Suren A. Chilingaryan <csa@suren.me> | 2015-05-01 19:21:14 +0200 |
commit | 993fb64bcbf75d2c447b718dff862c2124fbb062 (patch) | |
tree | ce03e8a995123b66980d1cf731fc021b97129d81 /data.c | |
parent | ab46db4c388d126095e8e4d8fc3d7aa191a3d649 (diff) | |
download | ipecamera-993fb64bcbf75d2c447b718dff862c2124fbb062.tar.gz ipecamera-993fb64bcbf75d2c447b718dff862c2124fbb062.tar.bz2 ipecamera-993fb64bcbf75d2c447b718dff862c2124fbb062.tar.xz ipecamera-993fb64bcbf75d2c447b718dff862c2124fbb062.zip |
Use pcitool debugging API
Diffstat (limited to 'data.c')
-rw-r--r-- | data.c | 10 |
1 files changed, 1 insertions, 9 deletions
@@ -61,15 +61,7 @@ inline static int ipecamera_decode_frame(ipecamera_t *ctx, pcilib_event_id_t eve printf("%lu\n", ctx->raw_size);*/ res = ufo_decoder_decode_frame(ctx->ipedec, ctx->buffer + buf_ptr * ctx->padded_size, ctx->frame[buf_ptr].event.raw_size, pixels, &ctx->frame[buf_ptr].event.meta); if (!res) { -#ifdef IPECAMERA_DEBUG_BROKEN_FRAMES - char name[128]; - sprintf(name, "%s/broken.%4lu", IPECAMERA_DEBUG_BROKEN_FRAMES, ctx->event_id); - FILE *f = fopen(name, "w"); - if (f) { - fwrite(ctx->buffer + buf_ptr * ctx->padded_size, ctx->raw_size, 1, f); - fclose(f); - } -#endif /* IPECAMERA_DEBUG_BROKEN_FRAMES */ + ipecamera_debug_buffer(BROKEN_FRAMES, ctx->frame[buf_ptr].event.raw_size, ctx->buffer + buf_ptr * ctx->padded_size, PCILIB_DEBUG_BUFFER_MKDIR, "broken_frame.%4lu", ctx->event_id); err = PCILIB_ERROR_FAILED; ctx->frame[buf_ptr].event.image_broken = err; goto ready; |