summaryrefslogtreecommitdiff
path: root/solenv/bin/modules/installer/worker.pm
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2008-10-29 13:27:59 +0000
committerRüdiger Timm <rt@openoffice.org>2008-10-29 13:27:59 +0000
commit1488be181ddb4d5c3475a0c73bd40577f67c6bb9 (patch)
treed2e92fdd82141683d6e5b7d203b17b67a3dc72b5 /solenv/bin/modules/installer/worker.pm
parentdd293aafd93805e1740ad2353b23a1873d8d1fb8 (diff)
CWS-TOOLING: integrate CWS native201_DEV300
Diffstat (limited to 'solenv/bin/modules/installer/worker.pm')
-rw-r--r--solenv/bin/modules/installer/worker.pm18
1 files changed, 16 insertions, 2 deletions
diff --git a/solenv/bin/modules/installer/worker.pm b/solenv/bin/modules/installer/worker.pm
index 1fa5a9e56125..92c1b2a4d444 100644
--- a/solenv/bin/modules/installer/worker.pm
+++ b/solenv/bin/modules/installer/worker.pm
@@ -1512,6 +1512,7 @@ sub shift_section_to_end
my @patchfile = ();
my @lastsection = ();
my $lastsection = "program";
+ my $notlastsection = "Basis\\program";
my $record = 0;
for ( my $i = 0; $i <= $#{$patchfilelist}; $i++ )
@@ -1520,7 +1521,7 @@ sub shift_section_to_end
if (( $record ) && ( $line =~ /^\s*\[/ )) { $record = 0; }
- if ( $line =~ /^\s*\[\Q$lastsection\E\\\]\s*$/ ) { $record = 1; }
+ if (( $line =~ /^\s*\[\Q$lastsection\E\\\]\s*$/ ) && ( ! ( $line =~ /\Q$notlastsection\E\\\]\s*$/ ))) { $record = 1; }
if ( $record ) { push(@lastsection, $line); }
else { push(@patchfile, $line); }
@@ -1554,14 +1555,27 @@ sub shift_file_to_end
my $lastfileline = "";
my $foundfile = 0;
+ # Only searching this file in the last section
+ my $lastsectionname = "";
+
for ( my $i = 0; $i <= $#{$patchfilelist}; $i++ )
{
my $line = ${$patchfilelist}[$i];
+ if ( $line =~ /^\s*\[(.*?)\]\s*$/ ) { $lastsectionname = $1; }
+ }
- if ( $line =~ /^\s*\"\Q$lastfilename\E\"\=/ )
+ my $record = 0;
+ for ( my $i = 0; $i <= $#{$patchfilelist}; $i++ )
+ {
+ my $line = ${$patchfilelist}[$i];
+
+ if ( $line =~ /^\s*\[\Q$lastsectionname\E\]\s*$/ ) { $record = 1; }
+
+ if (( $line =~ /^\s*\"\Q$lastfilename\E\"\=/ ) && ( $record ))
{
$lastfileline = $line;
$foundfile = 1;
+ $record = 0;
next;
}