(bug 548) A spot of refactoring, for legibility and better handling of 'warning'...