Commit 74a79a77 authored by Sebastian Lackner's avatar Sebastian Lackner Committed by Alexandre Julliard

hidclass.sys: Do not return failure when trying to set same ringbuffer size.

parent 115c6911
......@@ -102,8 +102,10 @@ NTSTATUS RingBuffer_SetSize(struct ReportRingBuffer *ring, UINT size)
BYTE* new_buffer;
int i;
if (size < MIN_BUFFER_SIZE || size > MAX_BUFFER_SIZE || size == ring->size)
if (size < MIN_BUFFER_SIZE || size > MAX_BUFFER_SIZE)
return STATUS_INVALID_PARAMETER;
if (size == ring->size)
return STATUS_SUCCESS;
EnterCriticalSection(&ring->lock);
ring->start = ring->end = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment