瀏覽代碼

Media: only sync parse if really needed

(cherry picked from commit 170b9c7a622cfe861f005d3c378bb28ad9755711)
Felix Paul Kühne 9 年之前
父節點
當前提交
c721ebfa32
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      Sources/VLCMedia.m

+ 2 - 1
Sources/VLCMedia.m

@@ -597,7 +597,8 @@ NSString *const VLCMediaTracksInformationTextEncoding = @"encoding"; // NSString
 
 - (NSArray *)tracksInformation
 {
-    [self synchronousParse];
+    if (!self.isParsed)
+        [self synchronousParse];
 
     libvlc_media_track_t **tracksInfo;
     unsigned int count = libvlc_media_tracks_get(p_md, &tracksInfo);