summaryrefslogtreecommitdiff
path: root/setup_native/source/win32/customactions/sellang/sellang.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'setup_native/source/win32/customactions/sellang/sellang.cxx')
-rw-r--r--setup_native/source/win32/customactions/sellang/sellang.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/setup_native/source/win32/customactions/sellang/sellang.cxx b/setup_native/source/win32/customactions/sellang/sellang.cxx
index bde31d03ab76..e82560f4239a 100644
--- a/setup_native/source/win32/customactions/sellang/sellang.cxx
+++ b/setup_native/source/win32/customactions/sellang/sellang.cxx
@@ -27,6 +27,7 @@
#include <msiquery.h>
#include <malloc.h>
+#include <cassert>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -44,6 +45,7 @@ static BOOL GetMsiPropA( MSIHANDLE hMSI, const char* pPropName, char** ppValue )
sz++;
DWORD nbytes = sz * sizeof( char );
char* buff = static_cast<char*>( malloc( nbytes ) );
+ assert(buff); // Don't handle OOM conditions
ZeroMemory( buff, nbytes );
MsiGetPropertyA( hMSI, pPropName, buff, &sz );
*ppValue = buff;