7 Sep
2022
7 Sep
'22
3:46 a.m.
Zhiyi Zhang (@zhiyi) commented about dlls/win32u/sysparams.c:
{ lstrcpyW( device_name, adapter->dev.device_name ); lstrcpyW( adapter_path, adapter->config_key ); + size = sizeof(DEVMODEW) + adapter->modes[0].dmDriverExtra; + /* allocate an extra mode for easier iteration */ + modes = calloc( adapter->mode_count + 1, size );
This memory copy could be avoided when index is ENUM_CURRENT_SETTINGS or ENUM_REGISTRY_SETTINGS. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/551#note_7847