diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2004-12-04 11:02:10 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2004-12-04 11:02:10 +0000 |
commit | 243305d3fdcc29ff8d8cf33ae8770700e18cdd0b (patch) | |
tree | e8f4c665e141aaea7b0fc0f64a619669b0bc8c0e /mdk-stage1 | |
parent | dde477e686bf313473dff962fd6d6581f6c61eba (diff) | |
download | drakx-243305d3fdcc29ff8d8cf33ae8770700e18cdd0b.tar drakx-243305d3fdcc29ff8d8cf33ae8770700e18cdd0b.tar.gz drakx-243305d3fdcc29ff8d8cf33ae8770700e18cdd0b.tar.bz2 drakx-243305d3fdcc29ff8d8cf33ae8770700e18cdd0b.tar.xz drakx-243305d3fdcc29ff8d8cf33ae8770700e18cdd0b.zip |
simplify
Diffstat (limited to 'mdk-stage1')
-rwxr-xr-x | mdk-stage1/pcmcia_/merge_from_pcitable | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/mdk-stage1/pcmcia_/merge_from_pcitable b/mdk-stage1/pcmcia_/merge_from_pcitable index 27cda239b..b48fb6e2a 100755 --- a/mdk-stage1/pcmcia_/merge_from_pcitable +++ b/mdk-stage1/pcmcia_/merge_from_pcitable @@ -5,15 +5,10 @@ use MDK::Common; -my @probelines = cat_('probe.c'); -my $status = 0; -foreach (@probelines) { - if ($status == 0) { - /^pci_id_t pci_id\[\] = {/ and $status = 1; - } elsif ($status == 1) { +foreach (cat_('probe.c')) { + if (/^pci_id_t pci_id\[\] = {/ ... /^};/) { /^\s*{\s*0x([\da-f]+),\s*0x([\da-f]+),\s*"([^"]*)",\s*"([^"]*)"\s*}/ and push @probes, { vendor => $1, device => $2, tag => $3, name => $4, vd => "$1$2" }; - /^};/ and last; } } |