]> sigrok.org Git - libsigrok.git/commitdiff
make check: Update to new session API.
authorUwe Hermann <redacted>
Sun, 20 Jul 2014 10:09:10 +0000 (12:09 +0200)
committerUwe Hermann <redacted>
Sun, 20 Jul 2014 10:09:10 +0000 (12:09 +0200)
tests/check_input_binary.c

index aad2b04e5f9ddcad6e9a59bfc5e4dbed04669d15..6f11759fd2ba600b6d66eccfe323348c7bacd901 100644 (file)
@@ -204,6 +204,7 @@ static void check_buf(const char *filename, GHashTable *param,
        int ret;
        struct sr_input *in;
        struct sr_input_format *in_format;
+       struct sr_session *session;
 
        /* Initialize global variables for this run. */
        df_packet_counter = sample_counter = 0;
@@ -226,11 +227,11 @@ static void check_buf(const char *filename, GHashTable *param,
        ret = in->format->init(in, filename);
        fail_unless(ret == SR_OK, "Input format init error: %d", ret);
        
-       sr_session_new();
-       sr_session_datafeed_callback_add(datafeed_in, NULL);
-       sr_session_dev_add(in->sdi);
+       sr_session_new(&session);
+       sr_session_datafeed_callback_add(session, datafeed_in, NULL);
+       sr_session_dev_add(session, in->sdi);
        in_format->loadfile(in, filename);
-       sr_session_destroy();
+       sr_session_destroy(session);
 
        g_unlink(filename); /* Delete file again. */
 }