From 3ed5ca860a2e8d7580e9c76645714a9028233217 Mon Sep 17 00:00:00 2001 From: Damiano Galassi Date: Thu, 11 Dec 2014 16:28:49 +0100 Subject: [PATCH] Close the bold tag correctly. --- MP42/MP42AudioConverter.m | 6 +++--- MP42/MP42SubtitleTrack.m | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/MP42/MP42AudioConverter.m b/MP42/MP42AudioConverter.m index 3864180..74efee7 100644 --- a/MP42/MP42AudioConverter.m +++ b/MP42/MP42AudioConverter.m @@ -307,8 +307,8 @@ OSStatus DecoderDataProc(AudioConverterRef inAudioConverter, - (void)DecoderThreadMainRoutine:(id)sender { - NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; - OSStatus err; + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; + OSStatus err; // set up buffers and data proc info struct decoderData.srcBufferSize = 32768; @@ -323,7 +323,7 @@ OSStatus DecoderDataProc(AudioConverterRef inAudioConverter, AudioStreamPacketDescription* outputPktDescs = NULL; int outputSizePerPacket = decoderData.outputFormat.mBytesPerPacket; // this will be non-zero if the format is CBR UInt32 theOutputBufSize = 32768; - char* outputBuffer = (char*)malloc(theOutputBufSize); + char *outputBuffer = (char *)malloc(theOutputBufSize); UInt32 numOutputPackets = theOutputBufSize / outputSizePerPacket; diff --git a/MP42/MP42SubtitleTrack.m b/MP42/MP42SubtitleTrack.m index b2db838..da67946 100644 --- a/MP42/MP42SubtitleTrack.m +++ b/MP42/MP42SubtitleTrack.m @@ -210,7 +210,7 @@ static void insertTagsFromStyleRecord(style_record record, NSMutableString *samp insertTag(@"", sampleText, &index, fontStyles, kStyleItalic, kTagClose); if (!(record.fontStyles & kStyleBold) && *fontStyles & kStyleBold) - insertTag(@"", sampleText, &index, fontStyles, kStyleBold, kStyleColor); + insertTag(@"", sampleText, &index, fontStyles, kStyleBold, kTagClose); if ((!(record.fontStyles & kStyleColor) && *fontStyles & kStyleColor))