- Try to protect as much as possible from fatal errors occuring during the data load:

1) Make sure we have enough memory to perform the task
2) In case of fatal error in the Ajax call, catch it, display it to the end-user and stop the installation.
See Trac #84 for more information.

SVN:trunk[298]
This commit is contained in:
Denis Flaven
2010-02-17 22:45:17 +00:00
parent 0fe146ecfd
commit 4928220098
3 changed files with 51 additions and 6 deletions

View File

@@ -103,7 +103,8 @@ function DoLoadDataAsynchronous()
$('#setup').block({message: '<p>Loading data...<br/><div id=\"progress\">0%</div></p>'});
$('#progress').progression( {Current:0, Maximum: 100, aBackgroundImg: 'orange-progress.gif', aTextColor: '#000000'} );
LoadNextDataFile('', '');
$('#log').ajaxError(function(e, xhr, settings, exception) { alert('Fatal error detected: '+ xhr.responseText); $('#log').append(xhr.responseText); $('#setup').unblock(); } );
LoadNextDataFile('', '');
return false; // Stop here for now
}