mirror of
https://github.com/reactos/reactos.git
synced 2025-08-02 17:07:40 +00:00
- Check if NodeId is out of bounds
- Return correct status code svn path=/trunk/; revision=43253
This commit is contained in:
parent
9ef3f7c1a2
commit
2f541881a8
1 changed files with 8 additions and 0 deletions
|
@ -241,6 +241,13 @@ KsTopologyPropertyHandler(
|
|||
case KSPROPERTY_TOPOLOGY_NAME:
|
||||
Node = (KSP_NODE*)Property;
|
||||
|
||||
if (Node->NodeId >= Topology->TopologyNodesCount)
|
||||
{
|
||||
Irp->IoStatus.Information = 0;
|
||||
Status = STATUS_INVALID_PARAMETER;
|
||||
break;
|
||||
}
|
||||
|
||||
Status = RtlStringFromGUID(&Topology->TopologyNodesNames[Node->NodeId], &GuidString);
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
|
@ -254,6 +261,7 @@ KsTopologyPropertyHandler(
|
|||
if (!KeyName.Buffer)
|
||||
{
|
||||
Irp->IoStatus.Information = 0;
|
||||
Status = STATUS_INSUFFICIENT_RESOURCES;
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue