Ryan Liptak 75e5b38410
std.fs: End iteration on Linux/WASI during Iterator.next when hitting ENOENT
`getdents` on Linux can return `ENOENT` if the directory referred to by the fd is deleted during iteration. Returning null when this happens makes sense because:

- `ENOENT` is specific to the Linux implementation of `getdents`
- On other platforms like FreeBSD, `getdents` returns `0` in this scenario, which is functionally equivalent to the `.NOENT => return null` handling on Linux
- In all the usage sites of `Iterator.next` throughout the standard library, translating `ENOENT` returned from `next` as null was the best way to handle it, so the use-case for handling the exact `ENOENT` scenario specifically may not exist to a relevant extent

Previously, ENOENT being returned would trigger `os.unexpectedErrno`.

Closes #12211
2022-07-25 16:14:25 +03:00
..
2022-07-15 10:16:31 +03:00
2022-07-23 17:21:17 +03:00
2022-07-01 21:35:19 -07:00
2022-05-13 16:43:59 -04:00
2022-03-08 20:38:12 +02:00
2022-04-20 17:18:06 -07:00
2022-01-07 00:06:06 -05:00
2022-06-03 20:21:20 +03:00
2022-04-14 10:12:45 -07:00
2022-07-09 15:19:03 +03:00
2022-06-03 20:21:20 +03:00
2022-07-15 14:39:21 +03:00
2022-05-26 21:58:19 -07:00
2022-07-11 18:47:29 +03:00
2022-07-01 21:35:19 -07:00
2022-04-15 17:01:01 -05:00
2022-01-07 00:06:06 -05:00