PERFORCE change 143681 for review
Weongyo Jeong
weongyo at FreeBSD.org
Wed Jun 18 05:42:49 UTC 2008
http://perforce.freebsd.org/chv.cgi?CH=143681
Change 143681 by weongyo at weongyo_ws on 2008/06/18 05:41:56
handle (PCI|PCMCIA|USB) .INF files correctly that specify multiple
entries in [Manufacturer] sections.
Affected files ...
.. //depot/projects/ndisusb/usr.sbin/ndiscvt/inf.c#3 edit
Differences ...
==== //depot/projects/ndisusb/usr.sbin/ndiscvt/inf.c#3 (text+ko) ====
@@ -285,7 +285,7 @@
struct section *sec;
struct assign *assign;
char xpsec[256];
- int found = 0;
+ int first = 1, found = 0;
/* Find manufacturer name */
manf = find_assign("Manufacturer", NULL);
@@ -322,8 +322,11 @@
found = 0;
- /* Emit start of PCI device table */
- fprintf (ofp, "#define NDIS_PCI_DEV_TABLE");
+ if (first == 1) {
+ /* Emit start of PCI device table */
+ fprintf (ofp, "#define NDIS_PCI_DEV_TABLE");
+ first = 0;
+ }
retry:
@@ -375,7 +378,7 @@
struct section *sec;
struct assign *assign;
char xpsec[256];
- int found = 0;
+ int first = 1, found = 0;
/* Find manufacturer name */
manf = find_assign("Manufacturer", NULL);
@@ -412,8 +415,11 @@
found = 0;
- /* Emit start of PCMCIA device table */
- fprintf (ofp, "#define NDIS_PCMCIA_DEV_TABLE");
+ if (first == 1) {
+ /* Emit start of PCMCIA device table */
+ fprintf (ofp, "#define NDIS_PCMCIA_DEV_TABLE");
+ first = 0;
+ }
retry:
@@ -465,7 +471,7 @@
struct section *sec;
struct assign *assign;
char xpsec[256];
- int found = 0;
+ int first = 1, found = 0;
/* Find manufacturer name */
manf = find_assign("Manufacturer", NULL);
@@ -502,8 +508,11 @@
found = 0;
- /* Emit start of USB device table */
- fprintf (ofp, "#define NDIS_USB_DEV_TABLE");
+ if (first == 1) {
+ /* Emit start of USB device table */
+ fprintf (ofp, "#define NDIS_USB_DEV_TABLE");
+ first = 0;
+ }
retry:
More information about the p4-projects
mailing list