Changeset 4105 in vbox for trunk/src/VBox/Additions/common/VBoxGuestLib
- Timestamp:
- Aug 10, 2007 9:13:38 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxGuestLib/HGCMInternal.cpp
r4071 r4105 24 24 #include <iprt/string.h> 25 25 #include <iprt/assert.h> 26 #include <iprt/alloca.h> 26 27 27 28 /* These functions can be only used by VBoxGuest. */ … … 128 129 129 130 if (!pCallInfo || !pAsyncCallback || pCallInfo->cParms > VBOX_HGCM_MAX_PARMS) 131 { 132 AssertFailed(); 130 133 return VERR_INVALID_PARAMETER; 134 } 131 135 132 136 dprintf (("VbglHGCMCall: pCallInfo->cParms = %d, pHGCMCall->u32Function = %d\n", pCallInfo->cParms, pCallInfo->u32Function)); … … 143 147 if (VBOX_SUCCESS(rc)) 144 148 { 145 void * apvCtx[VBOX_HGCM_MAX_PARMS];146 memset (apvCtx, 0, sizeof (apvCtx));149 void **apvCtx = (void **)alloca(sizeof(void *) * pCallInfo->cParms); 150 memset (apvCtx, 0, sizeof(void *) * pCallInfo->cParms); 147 151 148 152 /* Initialize request memory */ … … 251 255 } 252 256 } 257 else 258 Assert(!apvCtx[iParm]); 253 259 } 254 260
Note:
See TracChangeset
for help on using the changeset viewer.