diff options
author | Sakari Ailus <sakari.ailus@iki.fi> | 2011-10-07 18:38:07 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2011-10-08 13:32:17 +0200 |
commit | 2738635d82da5f010bae6a60472a6306df949ea5 (patch) | |
tree | 97ce4c08c0ab6dcc7abd7f78bd2e5965e15c63a3 /src/main.c | |
parent | 879982243998d6ebf7e7ac4e79b2cfc7371aeda2 (diff) |
Add debugging handler
Add debugging handler to media_device that may be used to redirect all debug
formatting to user-supplied function. fprintf will do, and that's what
media-ctl test program will use.
Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -288,7 +288,8 @@ int main(int argc, char **argv) return EXIT_FAILURE; /* Open the media device and enumerate entities, pads and links. */ - media = media_open(media_opts.devname, media_opts.verbose); + media = media_open_debug(media_opts.devname, media_opts.verbose, + (void (*)(void *, ...))fprintf, stdout); if (media == NULL) goto out; |