Message ID | 1415268702-23685-11-git-send-email-j.anaszewski@samsung.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/utils/media-ctl/libmediactl.c b/utils/media-ctl/libmediactl.c index 75021e7..fe38270 100644 --- a/utils/media-ctl/libmediactl.c +++ b/utils/media-ctl/libmediactl.c @@ -919,13 +919,13 @@ void media_device_unref(struct media_device *media) if (media->refcount > 0) return; + media_close_pipeline_subdevs(media); + for (i = 0; i < media->entities_count; ++i) { struct media_entity *entity = &media->entities[i]; free(entity->pads); free(entity->links); - if (entity->fd != -1) - close(entity->fd); } free(media->entities);