summaryrefslogtreecommitdiffstatshomepage
path: root/unix/modos.c
diff options
context:
space:
mode:
Diffstat (limited to 'unix/modos.c')
-rw-r--r--unix/modos.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/unix/modos.c b/unix/modos.c
index 0e699ec1d6..36945720d1 100644
--- a/unix/modos.c
+++ b/unix/modos.c
@@ -37,6 +37,7 @@
#include "py/nlr.h"
#include "py/runtime.h"
#include "py/objtuple.h"
+#include "py/mphal.h"
#include "extmod/misc.h"
// Can't include this, as FATFS structure definition is required,
@@ -51,10 +52,6 @@ extern const mp_obj_type_t mp_fat_vfs_type;
#define USE_STATFS 1
#endif
-#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))); } }
-
STATIC mp_obj_t mod_os_stat(mp_obj_t path_in) {
struct stat sb;
mp_uint_t len;
@@ -253,6 +250,5 @@ STATIC MP_DEFINE_CONST_DICT(mp_module_os_globals, mp_module_os_globals_table);
const mp_obj_module_t mp_module_os = {
.base = { &mp_type_module },
- .name = MP_QSTR_uos,
.globals = (mp_obj_dict_t*)&mp_module_os_globals,
};