fix errno import. Fixes #450
Merge branch 'dev' into nightly