Fix typos.
Fix stupid crash.
Add macosx version dispatch.