CuePoint::Find: check Track pointer

replace assert with a check of the pointer, this is a public function so
should be tolerant of invalid parameters

BUG=webm:1415

Change-Id: I28a3a2ef905d62f11928dbbe54c119411d2b1f74
This commit is contained in:
James Zern 2017-04-19 23:24:27 -07:00
parent 50c44bb44d
commit 300d6d8719

View File

@ -2430,7 +2430,9 @@ bool CuePoint::TrackPosition::Parse(IMkvReader* pReader, long long start_,
}
const CuePoint::TrackPosition* CuePoint::Find(const Track* pTrack) const {
assert(pTrack);
if (pTrack == NULL) {
return NULL;
}
const long long n = pTrack->GetNumber();