Crash bugs fixed