wg <[email protected]> added the comment:

> cosmetics

Ok, patch updated.

____________________________________________________
FFmpeg issue tracker <[email protected]>
<https://roundup.ffmpeg.org/roundup/ffmpeg/issue835>
____________________________________________________
--- trunk/libavformat/utils.c	2009-04-22 18:06:43.000000000 +0200
+++ ffmpeg-test/libavformat/utils.c	2009-05-24 11:49:42.000000000 +0200
@@ -2829,6 +2829,7 @@
                  int is_output)
 {
     int i;
+    int done[MAX_STREAMS] = {0};
 
     av_log(NULL, AV_LOG_INFO, "%s #%d, %s, %s '%s':\n",
             is_output ? "Output" : "Input",
@@ -2867,17 +2868,23 @@
         av_log(NULL, AV_LOG_INFO, "\n");
     }
     if(ic->nb_programs) {
-        int j, k;
+        int j, k, total = 0;
         for(j=0; j<ic->nb_programs; j++) {
             AVMetadataTag *name = av_metadata_get(ic->programs[j]->metadata,
                                                   "name", NULL, 0);
             av_log(NULL, AV_LOG_INFO, "  Program %d %s\n", ic->programs[j]->id,
                    name ? name->value : "");
-            for(k=0; k<ic->programs[j]->nb_stream_indexes; k++)
+            for(k=0; k<ic->programs[j]->nb_stream_indexes; k++) {
                 dump_stream_format(ic, ic->programs[j]->stream_index[k], index, is_output);
-         }
-    } else
+                done[ic->programs[j]->stream_index[k]] = 1;
+            }
+            total += ic->programs[j]->nb_stream_indexes;
+        }
+        if (total < ic->nb_streams)
+            av_log(NULL, AV_LOG_INFO, "  Other\n");
+    }
     for(i=0;i<ic->nb_streams;i++)
+        if (!done[i])
         dump_stream_format(ic, i, index, is_output);
 }
 

Reply via email to