]> sigrok.org Git - libsigrok.git/commit
ftdi-la: do enter the error path upon VID:PID mismatch
authorGerhard Sittig <redacted>
Wed, 12 Jun 2019 21:58:24 +0000 (23:58 +0200)
committerGerhard Sittig <redacted>
Thu, 13 Jun 2019 17:38:06 +0000 (19:38 +0200)
commit01ae826ba3c694eff0cf83cadbc43a98550f94e0
tree05707ebecfe423c3a7ad3f61df8b78a755e910e1
parent03f169b36b1e91d15b3bc292d1dcd2b03c9b50c6
ftdi-la: do enter the error path upon VID:PID mismatch

Bug #1390 reports that "!desc" is always true (should be: false?). But
the actual problem would be that 'desc' is _not_ NULL when none of the
supported chips' VID:PID matched (FT232H happens to "get found" then,
erroneously).

Add a sentinel to the table of supported chips, such that 'desc' becomes
NULL upon mismatch, and the error path is entered.
src/hardware/ftdi-la/api.c