diff options
author | Soeren Apel <soeren@apelpie.net> | 2018-12-28 11:41:41 +0100 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2019-03-13 19:22:52 +0100 |
commit | 4c180223a8ae12feb7bc3601e07e848fb9cdb493 (patch) | |
tree | e1102c76fa4ee2d5623b0a8cd17d069889350b94 /decoder.c | |
parent | 49d3e6f83c68e62138621f94bf5e22c9d7717fca (diff) | |
download | libsigrokdecode-4c180223a8ae12feb7bc3601e07e848fb9cdb493.tar.gz libsigrokdecode-4c180223a8ae12feb7bc3601e07e848fb9cdb493.zip |
Add PD tags handling and some tags
Diffstat (limited to 'decoder.c')
-rw-r--r-- | decoder.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -171,6 +171,7 @@ static void decoder_free(struct srd_decoder *dec) g_slist_free_full(dec->outputs, g_free); g_slist_free_full(dec->inputs, g_free); + g_slist_free_full(dec->tags, g_free); g_free(dec->license); g_free(dec->desc); g_free(dec->longname); @@ -802,6 +803,11 @@ SRD_API int srd_decoder_load(const char *module_name) goto err_out; } + if (py_attr_as_strlist(d->py_dec, "tags", &(d->tags)) != SRD_OK) { + fail_txt = "missing or malformed 'tags' attribute"; + goto err_out; + } + /* All options and their default values. */ if (get_options(d) != SRD_OK) { fail_txt = "cannot get options"; |