aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Lechner2020-03-21 17:11:30 -0500
committerDamien George2020-03-25 00:56:38 +1100
commit100012bec6e8103fcf4aa429dfe1bd801301d642 (patch)
treea3bae71fc14d4f02ee27cb661f2d252293792e26
parentb1066a9f967ba4e12e9ca87820eab494177d8467 (diff)
windows: Remove custom definition of MP_PLAT_PRINT_STRN.
This removes the port-specific definition of MP_PLAT_PRINT_STRN on the windows port, so that the default mp_hal_stdout_tx_strn_cooked() is always used. This fixes releasing the GIL during the call to write() (this was missed in bc3499f0103abcae39ad048bb42a518a665b8497). Also, mp_hal_dupterm_tx_strn() was defined but never used anywhere so it is safe to delete it.
-rw-r--r--ports/windows/mpconfigport.h9
1 files changed, 0 insertions, 9 deletions
diff --git a/ports/windows/mpconfigport.h b/ports/windows/mpconfigport.h
index 410945983..2efcf6b15 100644
--- a/ports/windows/mpconfigport.h
+++ b/ports/windows/mpconfigport.h
@@ -171,15 +171,6 @@ typedef long long mp_off_t;
typedef long mp_off_t;
#endif
-#if MICROPY_PY_OS_DUPTERM
-#define MP_PLAT_PRINT_STRN(str, len) mp_hal_stdout_tx_strn_cooked(str, len)
-void mp_hal_dupterm_tx_strn(const char *str, size_t len);
-#else
-#include <unistd.h>
-#define MP_PLAT_PRINT_STRN(str, len) do { int ret = write(1, str, len); (void)ret; } while (0)
-#define mp_hal_dupterm_tx_strn(s, l)
-#endif
-
#define MICROPY_PORT_BUILTINS \
{ MP_ROM_QSTR(MP_QSTR_open), MP_ROM_PTR(&mp_builtin_open_obj) },