Commit 40ad619a authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

msi: Avoid registering duplicate source list information.

parent 659db6e9
......@@ -2567,6 +2567,11 @@ UINT msi_package_add_info(MSIPACKAGE *package, DWORD context, DWORD options,
{
MSISOURCELISTINFO *info;
LIST_FOR_EACH_ENTRY( info, &package->sourcelist_info, MSISOURCELISTINFO, entry )
{
if (!strcmpW( info->value, value )) return ERROR_SUCCESS;
}
info = msi_alloc(sizeof(MSISOURCELISTINFO));
if (!info)
return ERROR_OUTOFMEMORY;
......@@ -2585,6 +2590,11 @@ UINT msi_package_add_media_disk(MSIPACKAGE *package, DWORD context, DWORD option
{
MSIMEDIADISK *disk;
LIST_FOR_EACH_ENTRY( disk, &package->sourcelist_media, MSIMEDIADISK, entry )
{
if (disk->disk_id == disk_id) return ERROR_SUCCESS;
}
disk = msi_alloc(sizeof(MSIMEDIADISK));
if (!disk)
return ERROR_OUTOFMEMORY;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment