server: Don't crash on invalid request sizes.

This commit is contained in:
Alexandre Julliard 2006-07-27 14:39:33 +02:00
parent 8abef9ea50
commit 5522446848
1 changed files with 5 additions and 1 deletions

View File

@ -318,7 +318,11 @@ void read_request( struct thread *thread )
return;
}
if (!(thread->req_data = malloc( thread->req_toread )))
fatal_protocol_error( thread, "no memory for %d bytes request\n", thread->req_toread );
{
fatal_protocol_error( thread, "no memory for %u bytes request %d\n",
thread->req_toread, thread->req.request_header.req );
return;
}
}
/* read the variable sized data */