diff options
Diffstat (limited to 'stmhal/modusocket.c')
| -rw-r--r-- | stmhal/modusocket.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/stmhal/modusocket.c b/stmhal/modusocket.c index 1c0b036d3..d705636c1 100644 --- a/stmhal/modusocket.c +++ b/stmhal/modusocket.c @@ -288,7 +288,7 @@ STATIC mp_obj_t socket_setsockopt(mp_uint_t n_args, const mp_obj_t *args) { const void *optval; mp_uint_t optlen; if (mp_obj_is_integer(args[3])) { - int val = mp_obj_int_get(args[3]); + mp_int_t val = mp_obj_int_get_truncated(args[3]); optval = &val; optlen = sizeof(val); } else { |
