X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fzeroplus-logic-cube%2Fapi.c;h=fa6ef1dc3c76a58ea02c47fb5d3cf412dbe5d999;hb=91219afc75c9aa1d0c5e2da5c03343c1e43eb6df;hp=2cf5aaf117bb924e6bbcb62758802a9351b057ed;hpb=f57d8ffe66612a1fdc20ed09c222f8ea59bd84d4;p=libsigrok.git diff --git a/src/hardware/zeroplus-logic-cube/api.c b/src/hardware/zeroplus-logic-cube/api.c index 2cf5aaf1..fa6ef1dc 100644 --- a/src/hardware/zeroplus-logic-cube/api.c +++ b/src/hardware/zeroplus-logic-cube/api.c @@ -248,9 +248,8 @@ static GSList *scan(GSList *options) /* Fill in channellist according to this device's profile. */ for (j = 0; j < devc->num_channels; j++) { - if (!(ch = sr_channel_new(j, SR_CHANNEL_LOGIC, TRUE, - channel_names[j]))) - return NULL; + ch = sr_channel_new(j, SR_CHANNEL_LOGIC, TRUE, + channel_names[j]); sdi->channels = g_slist_append(sdi->channels, ch); }