mirror of
https://github.com/davidgiven/fluxengine.git
synced 2025-10-31 11:17:01 -07:00
Don't crash when trying to access tracks with no data.
This commit is contained in:
@@ -10,9 +10,15 @@ public:
|
||||
}
|
||||
|
||||
nanoseconds_t duration() const { return _duration; }
|
||||
const uint8_t* ptr() const { return &_intervals.at(0); }
|
||||
int bytes() const { return _intervals.size(); }
|
||||
|
||||
const uint8_t* ptr() const
|
||||
{
|
||||
if (!_intervals.empty())
|
||||
return &_intervals.at(0);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Fluxmap& appendIntervals(std::vector<uint8_t>& intervals);
|
||||
Fluxmap& appendIntervals(const uint8_t* ptr, size_t len);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user