{
STRING PromptBuffer, ResponseBuffer;
BOOLEAN Enable, Resend;
- PVOID CapturedPrompt;
+ CHAR CapturedPrompt[512];
+ CHAR SafeResponseBuffer[512];
PCHAR SafeResponseString;
/* Normalize the lengths */
PromptLength = min(PromptLength,
- 512);
+ sizeof(CapturedPrompt));
MaximumResponseLength = min(MaximumResponseLength,
- 512);
+ sizeof(SafeResponseBuffer));
/* Check if we need to verify the string */
if (PreviousMode != KernelMode)
1);
/* Capture prompt */
- CapturedPrompt = _alloca(PromptLength);
KdpMoveMemory(CapturedPrompt,
PromptString,
PromptLength);
ProbeForWrite(ResponseString,
MaximumResponseLength,
1);
- SafeResponseString = _alloca(MaximumResponseLength);
+ SafeResponseString = SafeResponseBuffer;
}
_SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER)
{