]> sigrok.org Git - libsigrok.git/blobdiff - src/libsigrok-internal.h
Store a context pointer in struct sr_session.
[libsigrok.git] / src / libsigrok-internal.h
index 71fc79a9a6c69e9a710775f8854e57b7d3e54141..e0c700e346785855469598f5eabe31b009407d9c 100644 (file)
@@ -180,8 +180,8 @@ struct sr_context {
 #ifdef _WIN32
        GThread *usb_thread;
        gboolean usb_thread_running;
-       GMutex usb_mutex;
-       HANDLE usb_event;
+       HANDLE usb_wait_request_event;
+       HANDLE usb_wait_complete_event;
        GPollFD usb_pollfd;
        sr_receive_data_callback usb_cb;
        void *usb_cb_data;
@@ -402,7 +402,7 @@ struct sr_output_module {
        int (*init) (struct sr_output *o, GHashTable *options);
 
        /**
-        * This function is passed a copy of every packed in the data feed.
+        * This function is passed a copy of every packet in the data feed.
         * Any output generated by the output module in response to the
         * packet should be returned in a newly allocated GString
         * <code>out</code>, which will be freed by the caller.
@@ -663,6 +663,8 @@ SR_PRIV int sr_source_add_channel(GIOChannel *channel, int events, int timeout,
 /*--- session.c -------------------------------------------------------------*/
 
 struct sr_session {
+       /** Context this session exists in. */
+       struct sr_context *ctx;
        /** List of struct sr_dev_inst pointers. */
        GSList *devs;
        /** List of struct sr_dev_inst pointers owned by this session. */