From 1636d4d6945a20c62683b69c69c6b16e0c63b0ca Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Tue, 13 Dec 2011 17:55:58 +0100 Subject: fixes in pcitool --- cli.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'cli.c') diff --git a/cli.c b/cli.c index 59aa2dd..3df612f 100644 --- a/cli.c +++ b/cli.c @@ -1189,7 +1189,7 @@ int raw_data(pcilib_event_id_t event_id, pcilib_event_info_t *info, pcilib_event GRABContext *ctx = (GRABContext*)user; // pcilib_t *handle = ctx->handle; - + err = fastwriter_push_data(ctx->writer, size, data); if (err) { if (err == EWOULDBLOCK) Error("Storage is not able to handle the data stream, buffer overrun"); @@ -1428,7 +1428,7 @@ int TriggerAndGrab(pcilib_t *handle, GRAB_MODE grab_mode, const char *evname, co pcilib_configure_autostop(handle, num, run_time); if (flags&PCILIB_EVENT_FLAG_RAW_DATA_ONLY) { - pcilib_configure_rawdata_callback(handle, &raw_data, NULL); + pcilib_configure_rawdata_callback(handle, &raw_data, &ctx); } if (flags&PCILIB_EVENT_FLAG_PREPROCESS) { @@ -1510,7 +1510,8 @@ int TriggerAndGrab(pcilib_t *handle, GRAB_MODE grab_mode, const char *evname, co pthread_join(trigger_thread, NULL); } - fastwriter_close(ctx.writer); + err = fastwriter_close(ctx.writer); + if (err) Error("Storage problems, error %i", err); ctx.writing_flag = 0; -- cgit v1.2.3