Hans Leidekker : msi: Fix parsing of feature overrides.

Alexandre Julliard julliard at winehq.org
Mon Jan 18 10:58:56 CST 2010


Module: wine
Branch: master
Commit: 2bfce6cfdcfbf15ebb85f2680feea0ed62667a66
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=2bfce6cfdcfbf15ebb85f2680feea0ed62667a66

Author: Hans Leidekker <hans at codeweavers.com>
Date:   Mon Jan 18 13:10:15 2010 +0100

msi: Fix parsing of feature overrides.

---

 dlls/msi/action.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/dlls/msi/action.c b/dlls/msi/action.c
index 10338ad..50f2007 100644
--- a/dlls/msi/action.c
+++ b/dlls/msi/action.c
@@ -1562,8 +1562,10 @@ static BOOL process_state_property(MSIPACKAGE* package, int level,
 
             while (ptr)
             {
-                if ((ptr2 && strncmpW(ptr,feature->Feature, ptr2-ptr)==0)
-                    || (!ptr2 && strcmpW(ptr,feature->Feature)==0))
+                int len = ptr2 - ptr;
+
+                if ((ptr2 && strlenW(feature->Feature) == len && !strncmpW(ptr, feature->Feature, len))
+                    || (!ptr2 && !strcmpW(ptr, feature->Feature)))
                 {
                     msi_feature_set_state(package, feature, state);
                     break;




More information about the wine-cvs mailing list