Fixed sandbox flag typos, and error logging work cross-platform.