Fix bugs in GNU/Linux
Added checked support