From 19fd6f33b8e55707072feb5d08d0f62028265951 Mon Sep 17 00:00:00 2001
From: Mark Jansen <learn0more+wine@gmail.com>
Date: Fri, 13 Jan 2017 23:20:52 +0100
Subject: [PATCH] msi: Do not sign extend after multiplying.

Signed-off-by: Mark Jansen <learn0more+wine@gmail.com>
---
 dlls/msi/dialog.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/msi/dialog.c b/dlls/msi/dialog.c
index 8825c28..97fc89c 100644
--- a/dlls/msi/dialog.c
+++ b/dlls/msi/dialog.c
@@ -3200,13 +3200,13 @@ static LONGLONG msi_vcl_get_cost( msi_dialog *dialog )
                 MSICOSTTREE_SELFONLY, INSTALLSTATE_LOCAL, &each_cost)))
         {
             /* each_cost is in 512-byte units */
-            total_cost += each_cost * 512;
+            total_cost += ((LONGLONG)each_cost) * 512;
         }
         if (ERROR_SUCCESS == (MSI_GetFeatureCost(dialog->package, feature,
                 MSICOSTTREE_SELFONLY, INSTALLSTATE_ABSENT, &each_cost)))
         {
             /* each_cost is in 512-byte units */
-            total_cost -= each_cost * 512;
+            total_cost -= ((LONGLONG)each_cost) * 512;
         }
     }
     return total_cost;
-- 
1.9.1

