winhttp: Don't reference past the attribute array. Fixes Coverity item 710.

This commit is contained in:
Juan Lang 2008-09-09 11:51:34 -07:00 committed by Alexandre Julliard
parent 48865c9064
commit 12c1e067c6
1 changed files with 1 additions and 1 deletions

View File

@ -619,7 +619,7 @@ static BOOL query_headers( request_t *request, DWORD level, LPCWSTR name, LPVOID
}
default:
{
if (attr > sizeof(attribute_table)/sizeof(attribute_table[0]) || !attribute_table[attr])
if (attr >= sizeof(attribute_table)/sizeof(attribute_table[0]) || !attribute_table[attr])
{
FIXME("attribute %u not implemented\n", attr);
return FALSE;