lib: Add check to allow -p option to work.

-p was broken, because strlfind makes the assumption that id list
is always filled.
However, that's not the case for plaforms that only rely on hwid to
populate the id of the intf object.

BUG=none
BRANCH=none
TEST=Check -p works:
Before:
sudo /usr/sbin/mosys -p gwendal
Checking platform Alex
strlfind: "gwendal" ?= "Alex": No.
Checking platform Auron
Segmentation fault (core dumped)
After:
sudo /usr/sbin/mosys -p gwendal
Checking platform Alex
strlfind: "gwendal" ?= "Alex": No.
Checking platform Auron
Empty static id list.
Checking platform Beltino
...

Change-Id: Ic895e550f0e6c1d99a1b07022178124654cc0ad3
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/270061
1 file changed