[FFmpeg-cvslog] r21492 - trunk/cmdutils.c

stefano subversion
Thu Jan 28 00:08:43 CET 2010


Author: stefano
Date: Thu Jan 28 00:08:43 2010
New Revision: 21492

Log:
Declare variable "version" in the PRINT_LIB_VERSION() macro if block,
slightly simpler and more robust.

Modified:
   trunk/cmdutils.c

Modified: trunk/cmdutils.c
==============================================================================
--- trunk/cmdutils.c	Wed Jan 27 23:39:18 2010	(r21491)
+++ trunk/cmdutils.c	Thu Jan 28 00:08:43 2010	(r21492)
@@ -326,7 +326,7 @@ void print_error(const char *filename, i
 
 #define PRINT_LIB_VERSION(outstream,libname,LIBNAME,indent)             \
     if (CONFIG_##LIBNAME) {                                             \
-        version= libname##_version();                                   \
+        unsigned int version = libname##_version();                     \
         fprintf(outstream, "%slib%-10s %2d.%2d.%2d / %2d.%2d.%2d\n",    \
                 indent? "  " : "", #libname,                            \
                 LIB##LIBNAME##_VERSION_MAJOR,                           \
@@ -337,7 +337,6 @@ void print_error(const char *filename, i
 
 static void print_all_lib_versions(FILE* outstream, int indent)
 {
-    unsigned int version;
     PRINT_LIB_VERSION(outstream, avutil,   AVUTIL,   indent);
     PRINT_LIB_VERSION(outstream, avcodec,  AVCODEC,  indent);
     PRINT_LIB_VERSION(outstream, avformat, AVFORMAT, indent);



More information about the ffmpeg-cvslog mailing list