On Mon Mar 11 20:50:28 2024 +0000, Andrew Nguyen wrote:
From looking at the output of the strings command on the game executable, I think it would overwrite the description buffer either with "Core Design MMX Hardware Card Emulation" or "Core Design RGB Hardware Card Emulation" which both would occupy 40 bytes (including the null terminator). I chose a size of 64 bytes for the reference_description buffer as a conservative estimate because native can report for the Direct3D HAL device the description string "Microsoft Direct3D Hardware acceleration through Direct3D HAL" which occupies 62 bytes (including the null terminator). I can make it larger if necessary, but 64 bytes should be more than enough for the game. Speaking of which, should the wined3d_description buffer be expanded in the same way? I don't know of any application that needs to overwrite it with more than 40 bytes, but native can report a larger description string as I mentioned.
64 sounds good to me then, I just want to make sure we're not increasing to some arbitrary number that itself might not be enough.
Speaking of which, should the wined3d_description buffer be expanded in the same way? I don't know of any application that needs to overwrite it with more than 40 bytes, but native can report a larger description string as I mentioned.
I wouldn't worry about it if there's no evidence that applications will overwrite. "What if" scenarios are uncountable, after all ;-)