diff options
| author | David Lechner <david@pybricks.com> | 2022-07-02 15:05:41 -0500 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2022-07-18 13:52:01 +1000 |
| commit | 32e32bd761e91b9aa21f98b4f4fd4d96c723fdb6 (patch) | |
| tree | 52cf0e10b678ba665cb09173c4f02fe5ed5dd58e /extmod/vfs.c | |
| parent | d532c55e3b8ee7955bea99fc79ccd74d9a35f757 (diff) | |
extmod/vfs: Use MP_REGISTER_ROOT_POINTER().
This uses MP_REGISTER_ROOT_POINTER() to register vfs_cur and
vfs_mount_table instead of using a conditional inside of mp_state_vm_t.
Signed-off-by: David Lechner <david@pybricks.com>
Diffstat (limited to 'extmod/vfs.c')
| -rw-r--r-- | extmod/vfs.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/extmod/vfs.c b/extmod/vfs.c index 8bcead190..2799622b3 100644 --- a/extmod/vfs.c +++ b/extmod/vfs.c @@ -547,4 +547,7 @@ int mp_vfs_mount_and_chdir_protected(mp_obj_t bdev, mp_obj_t mount_point) { return ret; } +MP_REGISTER_ROOT_POINTER(struct _mp_vfs_mount_t *vfs_cur); +MP_REGISTER_ROOT_POINTER(struct _mp_vfs_mount_t *vfs_mount_table); + #endif // MICROPY_VFS |
