Added a check on a null pointer. Re #6533.
Another check for a null pointer. Re #6533.
Merge remote-tracking branch 'origin/bugfix/6533_reload_large_project'