File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed
Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -72,6 +72,7 @@ struct extra_dev_info {
7272 gfloat * * channels_data_copy ;
7373 GSList * plots_sample_counts ;
7474 struct iio_stream * stream ;
75+ struct iio_channels_mask * channels_mask ;
7576};
7677
7778struct buffer {
Original file line number Diff line number Diff line change @@ -1863,6 +1863,7 @@ static void init_device_list(struct iio_context *_ctx)
18631863 struct extra_dev_info * dev_info = calloc (1 , sizeof (* dev_info ));
18641864 iio_device_set_data (dev , dev_info );
18651865 dev_info -> input_device = is_input_device (dev );
1866+ dev_info -> channels_mask = iio_create_channels_mask (nb_channels );
18661867
18671868 for (j = 0 ; j < nb_channels ; j ++ ) {
18681869 struct iio_channel * ch = iio_device_get_channel (dev , j );
@@ -1898,6 +1899,8 @@ static void cleanup_device_list(struct iio_context *_ctx)
18981899 }
18991900
19001901 dev_info = iio_device_get_data (dev );
1902+ if (dev_info -> channels_mask )
1903+ iio_channels_mask_destroy (dev_info -> channels_mask );
19011904 free (dev_info );
19021905 iio_device_set_data (dev , NULL );
19031906 }
You can’t perform that action at this time.
0 commit comments