summaryrefslogtreecommitdiffstats
path: root/pci.c
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2002-06-10 18:39:59 +0000
committerPascal Rigaux <pixel@mandriva.com>2002-06-10 18:39:59 +0000
commit87078193e81d61fb5c19de52bdf1db9a331120dd (patch)
tree0f8a67829febd9c1fd082965b94f7ea1b1b789c5 /pci.c
parent83c30b339bde284b38417ec2e44027f259be72ce (diff)
downloadldetect-87078193e81d61fb5c19de52bdf1db9a331120dd.tar
ldetect-87078193e81d61fb5c19de52bdf1db9a331120dd.tar.gz
ldetect-87078193e81d61fb5c19de52bdf1db9a331120dd.tar.bz2
ldetect-87078193e81d61fb5c19de52bdf1db9a331120dd.tar.xz
ldetect-87078193e81d61fb5c19de52bdf1db9a331120dd.zip
ensure the header file are C++ compliant (do not use "class" for struct field name)
Diffstat (limited to 'pci.c')
-rw-r--r--pci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pci.c b/pci.c
index 2726b63..cb9ae45 100644
--- a/pci.c
+++ b/pci.c
@@ -36,7 +36,7 @@ extern struct pciusb_entries pci_probe(int probe_type) {
snprintf(file, sizeof(file), "/proc/bus/pci/%02x/%02x.%d", e.pci_bus, e.pci_device, e.pci_function);
if (probe_type == 1 && (f = fopen(file, "r"))) {
if (fseek(f, 10, SEEK_SET) == 0)
- fread(&e.class, 2, 1, f);
+ fread(&e.class_, 2, 1, f);
if (fseek(f, 0x2c, SEEK_SET) == 0)
fread(&e.subvendor, 2, 1, f), fread(&e.subdevice, 2, 1, f);
@@ -49,7 +49,7 @@ extern struct pciusb_entries pci_probe(int probe_type) {
if (fseek(f, 9, SEEK_SET) == 0) {
unsigned char class_prog = 0;
fread(&class_prog, 1, 1, f);
- if (e.class == PCI_CLASS_SERIAL_USB) {
+ if (e.class_ == PCI_CLASS_SERIAL_USB) {
/* taken from kudzu's pci.c */
e.module = strdup(class_prog == 0 ? "usb-uhci" : "usb-ohci");
}