FileWatching: prevent double-close of FileMonitor/FolderMonitor
The `close` function for FileMonitor/FolderMonitor reads the handle and calls `jl_close_uv`, but does not mark the handle as closed. If `close` is called twice before the async close callback (`_uv_hook_close`) has a chance to set handle to C_NULL, `jl_close_uv` would be called twice on the same handle, hitting a `uv_is_closing` assertion in libuv. Fix by checking `uv_is_closing` before calling `jl_close_uv` to skip handles that are already in the process of being closed. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
K
Kristoffer Carlsson committed
aa6e15f2e99d7991f36fbe3522782dbfd31b44c3
Parent: f92b6c2