On Tue Oct 10 18:21:12 2023 +0000, Zebediah Figura wrote:
This isn't a documented feature of strdup()/wcsdup(), which makes me a little doubtful of whether it's really a good idea, both in terms of functionality (what if it's supposed to trigger an invalid parameter error?) and clarity.
We have a [test for strdup](https://gitlab.winehq.org/wine/wine/-/blob/eb06f991725d21e1ce4e3353a377e8708...) that shows that strdup(NULL) == NULL on Windows, but it appears we don't have a similar test for wcsdup. I'd be happy to add that in a separate MR to reassure everyone that we can count on this behavior. It sounds like we should test the value of errno too.