From: Uwe Hermann Date: Sat, 15 Jan 2011 02:00:15 +0000 (+0100) Subject: Bugfix: Use only .py decoders, ignore .pyc files. X-Git-Tag: libsigrokdecode-0.1.0~315 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=276b55eb6e4308cfaf6b18b457f514b2f9409cc5;p=libsigrokdecode.git Bugfix: Use only .py decoders, ignore .pyc files. --- diff --git a/decode.c b/decode.c index 7125d32..598b2ba 100644 --- a/decode.c +++ b/decode.c @@ -60,7 +60,7 @@ int sigrokdecode_init(void) return SIGROKDECODE_ERR_DECODERS_DIR; while ((dp = readdir(dir)) != NULL) { - if (!strstr(dp->d_name, ".py")) + if (!g_str_has_suffix(dp->d_name, ".py")) continue; if ((tmp = strdup(dp->d_name))) list_pds = g_slist_append(list_pds, tmp);