Correctly return information to caller
authorHervé Poussineau <hpoussin@reactos.org>
Tue, 18 Jul 2006 11:55:40 +0000 (11:55 +0000)
committerHervé Poussineau <hpoussin@reactos.org>
Tue, 18 Jul 2006 11:55:40 +0000 (11:55 +0000)
svn path=/trunk/; revision=23136

reactos/drivers/base/serial/devctrl.c

index b4ca432..dd6be39 100644 (file)
@@ -349,6 +349,7 @@ SerialDeviceControl(
                        {
                                pConfigSize = (PULONG)BufferOut;
                                *pConfigSize = 0;
+                               Information = sizeof(ULONG);
                                Status = STATUS_SUCCESS;
                        }
                        break;
@@ -409,6 +410,7 @@ SerialDeviceControl(
                                        *pDtrRts |= SERIAL_DTR_STATE;
                                if (DeviceExtension->MCR & SR_MCR_RTS)
                                        *pDtrRts |= SERIAL_RTS_STATE;
+                               Information = sizeof(ULONG);
                                Status = STATUS_SUCCESS;
                        }
                        break;
@@ -445,6 +447,7 @@ SerialDeviceControl(
                        {
                                pMCR = (PULONG)BufferOut;
                                *pMCR = DeviceExtension->MCR;
+                               Information = sizeof(ULONG);
                                Status = STATUS_SUCCESS;
                        }
                        break;
@@ -459,6 +462,7 @@ SerialDeviceControl(
                        {
                                pMSR = (PULONG)BufferOut;
                                *pMSR = DeviceExtension->MSR;
+                               Information = sizeof(ULONG);
                                Status = STATUS_SUCCESS;
                        }
                        break;
@@ -500,8 +504,8 @@ SerialDeviceControl(
                        {
                                KeSynchronizeExecution(DeviceExtension->Interrupt,
                                        (PKSYNCHRONIZE_ROUTINE)SerialGetPerfStats, Irp);
-                               Status = STATUS_SUCCESS;
                                Information = sizeof(SERIALPERF_STATS);
+                               Status = STATUS_SUCCESS;
                        }
                        break;
                }
@@ -513,6 +517,7 @@ SerialDeviceControl(
                        else
                        {
                                *(PSERIAL_TIMEOUTS)BufferOut = DeviceExtension->SerialTimeOuts;
+                               Information = sizeof(SERIAL_TIMEOUTS);
                                Status = STATUS_SUCCESS;
                        }
                        break;
@@ -527,6 +532,7 @@ SerialDeviceControl(
                        {
                                pWaitMask = (PULONG)BufferOut;
                                *pWaitMask = DeviceExtension->WaitMask;
+                               Information = sizeof(ULONG);
                                Status = STATUS_SUCCESS;
                        }
                        break;