[FFmpeg-cvslog] ffprobe: fix indentation of the first line of packets_and_frames sections in the json output

Stefano Sabatini git at videolan.org
Thu Sep 27 01:11:30 CEST 2012


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Thu Sep 27 00:45:16 2012 +0200| [163f7afbe6667a9a881f5d07b64a232b36152153] | committer: Stefano Sabatini

ffprobe: fix indentation of the first line of packets_and_frames sections in the json output

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=163f7afbe6667a9a881f5d07b64a232b36152153
---

 ffprobe.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ffprobe.c b/ffprobe.c
index ce09dcc..e9f66b0 100644
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -1089,6 +1089,7 @@ static void json_print_section_header(WriterContext *wctx)
         json_escape_str(&buf, section->name, wctx);
         JSON_INDENT();
 
+        json->indent_level++;
         if (section->flags & SECTION_FLAG_IS_ARRAY) {
             printf("\"%s\": [\n", buf.str);
         } else if (!(parent_section->flags & SECTION_FLAG_IS_ARRAY)) {
@@ -1103,7 +1104,6 @@ static void json_print_section_header(WriterContext *wctx)
                 printf("\"type\": \"%s\"%s", section->name, json->item_sep);
             }
         }
-        json->indent_level++;
         av_bprint_finalize(&buf, NULL);
     }
 }



More information about the ffmpeg-cvslog mailing list