We ignore the return value of add_filter() instead of assigning it to
ret as usual, then test ret anyway. That's clearly bogus, even more
so since with the old code ret can never be negative at this point, so
the subsequent condition for the subsequent jump to out: is never true.
This bug was introduced 13 years ago.
Fixes: 081ea8699e6a309c44446884b8c3752529d96a25
*/
if (strcmp(name, "udp") == 0 || strcmp(name, "dccp") == 0) {
tmp = para_strdup("fecdec");
- add_filter(i, tmp);
+ ret = add_filter(i, tmp);
free(tmp);
if (ret < 0)
goto out;