]> sigrok.org Git - libsigrok.git/blobdiff - src/lcr/es51919.c
Don't check sr_channel_new() return value (always succeeds).
[libsigrok.git] / src / lcr / es51919.c
index d15c4d3820e18756b0ae0353ab58fcbd8172d214..0c9054a8670467c6e8476fa9fd0caa1e0b85bc36 100644 (file)
@@ -783,9 +783,7 @@ static int add_channel(struct sr_dev_inst *sdi, const char *name)
 {
        struct sr_channel *ch;
 
-       if (!(ch = sr_channel_new(0, SR_CHANNEL_ANALOG, TRUE, name)))
-               return SR_ERR;
-
+       ch = sr_channel_new(0, SR_CHANNEL_ANALOG, TRUE, name);
        sdi->channels = g_slist_append(sdi->channels, ch);
 
        return SR_OK;