diff --git a/dlls/secur32/schannel.c b/dlls/secur32/schannel.c index eb8106e88c7..885fabfac13 100644 --- a/dlls/secur32/schannel.c +++ b/dlls/secur32/schannel.c @@ -1003,7 +1003,7 @@ static SECURITY_STATUS SEC_ENTRY schan_InitializeSecurityContextW( if (!expected_size) { TRACE("Expected at least %lu bytes, but buffer only contains %u bytes.\n", - max(6, record_size), buffer->cbBuffer); + max(ctx->header_size + 1, record_size), buffer->cbBuffer); return SEC_E_INCOMPLETE_MESSAGE; } }