21 Sep
2023
21 Sep
'23
2:15 p.m.
Multiple places across other DLLs assume `wine_get_unix_file_name()` provides a null-terminated string, passing its return value to e.g. `fprintf()` and `strstr()`.
In fact it shouldn't be, you should use an explicit length instead.
Whether I `strlen()` here or when first getting this buffer from `wine_get_unix_file_name()` seems irrelevant to me; is there something I'm missing?
It's null-terminated on the client side, but you can't make any assumptions on the server side. The server has to be able to cope with the client sending malformed data. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/2786#note_46196