SIGN IN SIGN UP

windows: Fix sometimes log error messages don't show the crate name (#18706)

On windows, path could be something like `C:\path\to\the\crate`. Hence,
`split('/')` would refuse to work in this case.

### Before

![Screenshot 2024-10-04
023652](https://github.com/user-attachments/assets/9c14fb24-5ee0-4b56-8fbd-313abb28f134)

### After

![Screenshot 2024-10-04
024115](https://github.com/user-attachments/assets/217e175c-b0e1-4589-9c3d-98670882b185)


Release Notes:

- N/A
J
Junkui Zhang committed
8d6fa9526e076c7cf6e805fc0d73630162e0a81c
Parent: fd22c9b
Committed by GitHub <noreply@github.com> on 10/3/2024, 8:00:33 PM