Commits

Anonymous committed c31e597

native347 #i114640# workaround for allowed errors in logfiles

Comments (0)

Files changed (3)

solenv/bin/modules/installer/control.pm

 	my @errors = ();
 	my @output = ();
 	my $contains_error = 0;
+	
+	my $ignore_error = 0;
+	my $make_error_to_warning = 0;
+	
+	if (( ! $installer::globals::pro ) && ( $installer::globals::ignore_error_in_logfile )) { $ignore_error = 1; }
 
 	for ( my $i = 0; $i <= $#{$logfile}; $i++ )
 	{
 		{
 			$contains_error = 1;
 			push(@errors, $line);
+			
+			if ( $ignore_error )
+			{
+				$contains_error = 0;
+				$make_error_to_warning = 1;
+			}
 		}
 	}
 
 	}
 	else
 	{
-		my $line = "\n***********************************************************\n";
+		my $line = "";
+		
+		if ( $make_error_to_warning )
+		{
+			$line = "\n*********************************************************************\n";
+			push(@output, $line);
+			$line = "The following errors in the log file were ignored:\n\n";
+			push(@output, $line);
+
+			for ( my $i = 0; $i <= $#errors; $i++ )
+			{
+				$line = "$errors[$i]";
+				push(@output, $line);
+			}
+		
+			$line = "*********************************************************************\n";
+			push(@output, $line);		
+		}
+		
+		$line = "\n***********************************************************\n";
 		push(@output, $line);
 		$line = "Successful packaging process!\n";
 		push(@output, $line);

solenv/bin/modules/installer/environment.pm

 	if ( $ENV{'SOLAR_JAVA'} ) { $installer::globals::solarjavaset = 1; }
 	if ( $ENV{'RPM'} ) { $installer::globals::rpm = $ENV{'RPM'}; }
 	if ( $ENV{'DONTCOMPRESS'} ) { $installer::globals::solarisdontcompress = 1; }
+	if ( $ENV{'IGNORE_ERROR_IN_LOGFILE'} ) { $installer::globals::ignore_error_in_logfile = 1; }
 	if (( $ENV{'DISABLE_STRIP'} ) && ( $ENV{'DISABLE_STRIP'} ne '' )) { $installer::globals::strip = 0; }
 	
 	if ( $installer::globals::localinstalldir ) { $installer::globals::localinstalldirset = 1; }

solenv/bin/modules/installer/globals.pm

 	@logfileinfo = ();
 	@errorlogfileinfo = ();
 	@globallogfileinfo = ();
+	$ignore_error_in_logfile = 0;
 	$exitlog = "";
 	$globalinfo_copied = 0;
 	$quiet = 0;
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.