Fix a crash in copySubtitleSample.
This commit is contained in:
1 parent
b841840561
commit
dbb759bbd8
4 files changed
+6
-15
No files matched your search
+2
-2
@@ -58,7 +58,7 @@
|
||||
dispatch_semaphore_signal(_empty);
|
||||
}
|
||||
|
||||
- (nullable id)dequeue {
|
||||
- (nullable id)dequeue NS_RETURNS_RETAINED {
|
||||
if (!_count) return nil;
|
||||
|
||||
id item = _array[_head++];
|
||||
@@ -73,7 +73,7 @@
|
||||
return item;
|
||||
}
|
||||
|
||||
- (nullable id)dequeueAndWait {
|
||||
- (nullable id)dequeueAndWait NS_RETURNS_RETAINED {
|
||||
id item = [self dequeue];
|
||||
|
||||
while (!item) {
|
||||
|
||||
@@ -61,8 +61,8 @@ unsigned ParseSubTime(const char *time, unsigned secondScale, BOOL hasSign);
|
||||
|
||||
@class MP42SampleBuffer;
|
||||
|
||||
MP42SampleBuffer * copySubtitleSample(MP4TrackId subtitleTrackId, NSString *string, MP4Duration duration, BOOL forced, BOOL verticalPlacement, BOOL styles, CGSize trackSize, int top);
|
||||
MP42SampleBuffer * copyEmptySubtitleSample(MP4TrackId subtitleTrackId, MP4Duration duration, BOOL forced);
|
||||
MP42SampleBuffer * copySubtitleSample(MP4TrackId subtitleTrackId, NSString *string, MP4Duration duration, BOOL forced, BOOL verticalPlacement, BOOL styles, CGSize trackSize, int top) NS_RETURNS_RETAINED;
|
||||
MP42SampleBuffer * copyEmptySubtitleSample(MP4TrackId subtitleTrackId, MP4Duration duration, BOOL forced) NS_RETURNS_RETAINED;
|
||||
|
||||
typedef struct {
|
||||
// color format is 32-bit ARGB
|
||||
|
||||
@@ -257,15 +257,6 @@
|
||||
return StringFromTime(_duration, 1000);
|
||||
}
|
||||
|
||||
@synthesize sourceURL = _sourceURL;
|
||||
@synthesize trackId = _trackId;
|
||||
@synthesize sourceId = _sourceId;
|
||||
|
||||
@synthesize format = _format;
|
||||
@synthesize sourceFormat = _sourceFormat;
|
||||
@synthesize name = _name;
|
||||
@synthesize extendedLanguageTag = _extendedLanguageTag;
|
||||
|
||||
- (NSString *)name {
|
||||
if (_name == nil) {
|
||||
_name = [[self defaultName] copy];
|
||||
|
||||
Reference in new issue
Block a user