]> sigrok.org Git - sigrok-cli.git/commitdiff
srd: extra module path can now optionally be passed to srd_init()
authorBert Vermeulen <redacted>
Sun, 12 Feb 2012 03:07:22 +0000 (04:07 +0100)
committerBert Vermeulen <redacted>
Sun, 12 Feb 2012 03:09:12 +0000 (04:09 +0100)
Also environment variable SIGROKDECODE_DIR, if present, is prepended
to the module path.

sigrok-cli.c

index a9e30017b85b9016cd051f47eee7a6a47e054a43..4502da40482ad53c3aa4f7a8598fcc96a40a6541 100644 (file)
@@ -114,7 +114,7 @@ static void show_version(void)
        printf("\n");
 
        /* TODO: Error handling. */
-       srd_init();
+       srd_init(NULL);
 
        printf("Supported protocol decoders:\n");
        for (l = srd_list_decoders(); l; l = l->next) {
@@ -1006,7 +1006,7 @@ int main(int argc, char **argv)
                return 1;
 
        if (opt_pds) {
-               if (srd_init() != SRD_OK) {
+               if (srd_init(NULL) != SRD_OK) {
                        printf("Failed to initialize sigrokdecode\n");
                        return 1;
                }