Fixed error preventing output of errno
Updated formatting of errno output