summaryrefslogtreecommitdiffstats
path: root/pciusb.c
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2007-08-06 15:33:49 +0000
committerThierry Vignaud <tv@mandriva.org>2007-08-06 15:33:49 +0000
commitc94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47 (patch)
treedd3d3fbd510020b199ef1cb66a786c8fec0300ea /pciusb.c
parent999afb62bf1db1d0f4b908b7df0c4d9b0bbd7324 (diff)
downloadldetect-c94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47.tar
ldetect-c94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47.tar.gz
ldetect-c94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47.tar.bz2
ldetect-c94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47.tar.xz
ldetect-c94563d98d5ecf26baf4c2dfb6a52bd3aef1fa47.zip
(pciusb_find_modules) handle pcitable without description field
Diffstat (limited to 'pciusb.c')
-rw-r--r--pciusb.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/pciusb.c b/pciusb.c
index 0803c2d..971e20b 100644
--- a/pciusb.c
+++ b/pciusb.c
@@ -137,6 +137,8 @@ extern int pciusb_find_modules(struct pciusb_entries *entries, const char *fpciu
if (!p) { // only calc text & module if not already done
p = buf + offset + 1;
q = strchr(p, '\t');
+ if (!q) // no description field?
+ q = strchr(p, '\0') - 1;
}
if (strncmp(p, "unknown", q-p-1)) {
ifree(e->module);