unix: Use mp_raise_OSError helper function.

This commit is contained in:
Damien George
2016-10-07 14:05:15 +11:00
parent 23a568240d
commit 503089ea9d
9 changed files with 18 additions and 16 deletions

View File

@@ -35,7 +35,7 @@
#define RAISE_ERRNO(err_flag, error_val) \
{ if (err_flag == -1) \
{ nlr_raise(mp_obj_new_exception_arg1(&mp_type_OSError, MP_OBJ_NEW_SMALL_INT(error_val))); } }
{ mp_raise_OSError(error_val); } }
STATIC mp_obj_t mod_termios_tcgetattr(mp_obj_t fd_in) {
struct termios term;