projects
/
APKPM.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
50a815a
)
fix more quirks in right column parsing
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Mon, 26 Sep 2011 13:21:53 +0000
(15:21 +0200)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Mon, 26 Sep 2011 13:21:53 +0000
(15:21 +0200)
lib/H1/ZTEMSAN.pm
patch
|
blob
|
history
diff --git
a/lib/H1/ZTEMSAN.pm
b/lib/H1/ZTEMSAN.pm
index
4bf8144
..
85c81bb
100644
(file)
--- a/
lib/H1/ZTEMSAN.pm
+++ b/
lib/H1/ZTEMSAN.pm
@@
-33,14
+33,15
@@
sub parse {
my $last_line;
foreach my $line ( split(/[\n\r]+/, $out) ) {
warn "# $line\n";
my $last_line;
foreach my $line ( split(/[\n\r]+/, $out) ) {
warn "# $line\n";
- if ( $line =~ m/^(\S+.*?)\s
+
:+\s+(\S+.*?)\s*$/ ) {
+ if ( $line =~ m/^(\S+.*?)\s
*
:+\s+(\S+.*?)\s*$/ ) {
my ($n,$v) = ($1,$2);
$n =~ s/\(.+\)//;
if ( $v =~ s/\s+(\S+)\s*:\s+(\S+.+)// ) {
# strip second column
my ($n2,$v2) = ($1,$2);
$n2 =~ s/\(.+\)//;
my ($n,$v) = ($1,$2);
$n =~ s/\(.+\)//;
if ( $v =~ s/\s+(\S+)\s*:\s+(\S+.+)// ) {
# strip second column
my ($n2,$v2) = ($1,$2);
$n2 =~ s/\(.+\)//;
- $hash->{ $section . $n2 } = $2;
+ $hash->{ $section . $n2 } = $v2;
+ warn "## $n2 = $v2\n";
}
$hash->{ $section . $n } = $v;
warn "## $n = $v\n";
}
$hash->{ $section . $n } = $v;
warn "## $n = $v\n";