Add error handling to std::os::setenv.

Error handling through std::io::IoResult.
Applying modif related to setenv.
fixup! Dirty hack I need some help on it.
fixup! Dirty hack too... :(