Module: wine Branch: master Commit: a74e025335b107926bf9062ef6ac0fa120613261 URL: http://source.winehq.org/git/wine.git/?a=commit;h=a74e025335b107926bf9062ef6...
Author: Hans Leidekker hans@codeweavers.com Date: Wed Nov 17 10:57:40 2010 +0100
msi: Fix handling of an empty language id list in msi_parse_summary.
---
dlls/msi/package.c | 9 +++++++-- 1 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/dlls/msi/package.c b/dlls/msi/package.c index 50a7dbb..72f3392 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -1336,9 +1336,14 @@ static UINT msi_parse_summary( MSISUMMARYINFO *si, MSIPACKAGE *package ) msi_free( template ); return ERROR_INSTALL_PLATFORM_UNSUPPORTED; } - + p++; + if (!*p) + { + msi_free( template ); + return ERROR_SUCCESS; + } count = 1; - for (q = ++p; (q = strchrW( q, ',' )); q++) count++; + for (q = p; (q = strchrW( q, ',' )); q++) count++;
package->langids = msi_alloc( count * sizeof(LANGID) ); if (!package->langids)