undo removal of alloca in builtinimport.c
This commit is contained in:
parent
4b1e9d8f92
commit
1e94c4240c
@ -330,7 +330,7 @@ mp_obj_t mp_builtin___import__(size_t n_args, const mp_obj_t *args) {
|
||||
}
|
||||
|
||||
uint new_mod_l = (mod_len == 0 ? (size_t)(p - this_name) : (size_t)(p - this_name) + 1 + mod_len);
|
||||
char new_mod[new_mod_l];
|
||||
char *new_mod = alloca(new_mod_l);
|
||||
memcpy(new_mod, this_name, p - this_name);
|
||||
if (mod_len != 0) {
|
||||
new_mod[p - this_name] = '.';
|
||||
|
Loading…
x
Reference in New Issue
Block a user