Fix crashes on disconnected pins in wmdks topologies. (#300)
* Fix crashes on disconnected pins in wmdks topologies. * Fix potential assert on disconnected physical output pin in PinNew
This commit is contained in:
parent
88c71a6ec4
commit
7e2a33c875
1 changed files with 5 additions and 4 deletions
|
|
@ -1057,8 +1057,9 @@ static const KSTOPOLOGY_CONNECTION* FindStartConnectionFrom(ULONG startPin, PaWi
|
|||
}
|
||||
}
|
||||
|
||||
/* Some devices may report topologies that leave pins unconnected. This may be by design or driver installation
|
||||
issues. Pass the error condition back to caller. */
|
||||
PA_DEBUG(("FindStartConnectionFrom: returning NULL\n"));
|
||||
assert(FALSE);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -1077,8 +1078,8 @@ static const KSTOPOLOGY_CONNECTION* FindStartConnectionTo(ULONG startPin, PaWinW
|
|||
}
|
||||
}
|
||||
|
||||
/* Unconnected pin. Inform caller. */
|
||||
PA_DEBUG(("FindStartConnectionTo: returning NULL\n"));
|
||||
assert(FALSE);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -1970,8 +1971,8 @@ static PaWinWdmPin* PinNew(PaWinWdmFilter* parentFilter, unsigned long pinId, Pa
|
|||
}
|
||||
else
|
||||
{
|
||||
/* Should never come here! */
|
||||
assert(FALSE);
|
||||
/* Unconnected pin */
|
||||
goto error;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue