extmod/vfs: Prevent uninitialized variable warning for path_out.

The warning can appear when building in Release mode on the rp2 port.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George 2022-06-30 13:54:50 +10:00
parent f1b5761ced
commit f75e611054

View File

@ -100,6 +100,8 @@ STATIC mp_vfs_mount_t *lookup_path(mp_obj_t path_in, mp_obj_t *path_out) {
if (vfs != MP_VFS_NONE && vfs != MP_VFS_ROOT) {
*path_out = mp_obj_new_str_of_type(mp_obj_get_type(path_in),
(const byte *)p_out, strlen(p_out));
} else {
*path_out = MP_OBJ_NULL;
}
return vfs;
}