summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Joye <pajoye@php.net>2011-07-28 10:34:16 +0000
committerPierre Joye <pajoye@php.net>2011-07-28 10:34:16 +0000
commit582c2fa8685efdf6315f7ab6467d7e99de1f3156 (patch)
treeb1151c3b187fee3544c8a8c88a348793e40f48f4
parent103d47502108995ed8f2567269d2e27abe092f50 (diff)
downloadphp-git-582c2fa8685efdf6315f7ab6467d7e99de1f3156.tar.gz
- Fix #55301 (com_dotnet part) check if malloc succeded
-rw-r--r--ext/com_dotnet/com_dotnet.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/com_dotnet/com_dotnet.c b/ext/com_dotnet/com_dotnet.c
index 06291ab57d..7c206f6295 100644
--- a/ext/com_dotnet/com_dotnet.c
+++ b/ext/com_dotnet/com_dotnet.c
@@ -129,6 +129,9 @@ static HRESULT dotnet_init(char **p_where TSRMLS_DC)
char *where = "";
stuff = malloc(sizeof(*stuff));
+ if (!stuff) {
+ return S_FALSE;
+ }
memset(stuff, 0, sizeof(*stuff));
where = "CoCreateInstance";