file.pm (fb67933c) | file.pm (d1fa6344) |
---|---|
1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 693 unchanged lines hidden (view full) --- 702 703 # All used sequences stored in %installer::globals::allusedupdatesequences 704 # Maximum sequence number of old database stored in $installer::globals::updatelastsequence 705 # All new files stored in %installer::globals::newupdatefiles 706 707 my $infoline = ""; 708 709 my @missing_sequences = (); | 1#************************************************************** 2# 3# Licensed to the Apache Software Foundation (ASF) under one 4# or more contributor license agreements. See the NOTICE file 5# distributed with this work for additional information 6# regarding copyright ownership. The ASF licenses this file 7# to you under the Apache License, Version 2.0 (the 8# "License"); you may not use this file except in compliance --- 693 unchanged lines hidden (view full) --- 702 703 # All used sequences stored in %installer::globals::allusedupdatesequences 704 # Maximum sequence number of old database stored in $installer::globals::updatelastsequence 705 # All new files stored in %installer::globals::newupdatefiles 706 707 my $infoline = ""; 708 709 my @missing_sequences = (); |
710 my @really_missing_sequences = (); | |
711 712 for ( my $i = 1; $i <= $installer::globals::updatelastsequence; $i++ ) 713 { 714 if ( ! exists($installer::globals::allusedupdatesequences{$i}) ) { push(@missing_sequences, $i); } 715 } 716 717 if ( $#missing_sequences > -1 ) 718 { | 710 711 for ( my $i = 1; $i <= $installer::globals::updatelastsequence; $i++ ) 712 { 713 if ( ! exists($installer::globals::allusedupdatesequences{$i}) ) { push(@missing_sequences, $i); } 714 } 715 716 if ( $#missing_sequences > -1 ) 717 { |
719 # Missing sequences can also be caused by files included in merge modules. This files are added later into the file table. 720 # Therefore now it is time to check the content of the merge modules. 721 | 718 my $errorstring = ""; |
722 for ( my $j = 0; $j <= $#missing_sequences; $j++ ) 723 { 724 my $filename = $allupdatefileorderhashref->{$missing_sequences[$j]}; | 719 for ( my $j = 0; $j <= $#missing_sequences; $j++ ) 720 { 721 my $filename = $allupdatefileorderhashref->{$missing_sequences[$j]}; |
725 726 # Is this a file from a merge module? Then this is no error. 727 if ( ! exists($installer::globals::mergemodulefiles{$filename}) ) 728 { 729 push(@really_missing_sequences, $missing_sequences[$j]); 730 } | 722 my $comp = $allupdatecomponentorderhashref->{$missing_sequences[$j]}; 723 $errorstring = "$errorstring$filename (Sequence: $missing_sequences[$j], Component: \"$comp\")\n"; |
731 } | 724 } |
732 } | |
733 | 725 |
734 if ( $#really_missing_sequences > -1 ) 735 { 736 my $errorstring = ""; 737 for ( my $j = 0; $j <= $#really_missing_sequences; $j++ ) 738 { 739 my $filename = $allupdatefileorderhashref->{$really_missing_sequences[$j]}; 740 my $comp = $allupdatecomponentorderhashref->{$really_missing_sequences[$j]}; 741 $errorstring = "$errorstring$filename (Sequence: $really_missing_sequences[$j], Component: \"$comp\")\n"; 742 } 743 | |
744 $infoline = "ERROR: Files are removed compared with update database.\nThe following files are missing:\n$errorstring"; 745 $installer::logger::Lang->print($infoline); 746 installer::exiter::exit_program($infoline, "check_file_sequences"); 747 } 748 749 # Searching for new files 750 751 my $counter = 0; --- 309 unchanged lines hidden --- | 726 $infoline = "ERROR: Files are removed compared with update database.\nThe following files are missing:\n$errorstring"; 727 $installer::logger::Lang->print($infoline); 728 installer::exiter::exit_program($infoline, "check_file_sequences"); 729 } 730 731 # Searching for new files 732 733 my $counter = 0; --- 309 unchanged lines hidden --- |