Compile network-related code conditionally.
authorRamiro Polla <ramiro.polla@gmail.com>
Thu, 8 May 2008 00:46:34 +0000 (00:46 +0000)
committerRamiro Polla <ramiro.polla@gmail.com>
Thu, 8 May 2008 00:46:34 +0000 (00:46 +0000)
Originally committed as revision 13076 to svn://svn.ffmpeg.org/ffmpeg/trunk

cmdutils.c

index 8333994..86b4a9e 100644 (file)
@@ -31,7 +31,9 @@
 #include "cmdutils.h"
 #include "avstring.h"
 #include "version.h"
+#ifdef CONFIG_NETWORK
 #include "network.h"
+#endif
 
 #undef exit
 
@@ -181,9 +183,11 @@ void print_error(const char *filename, int err)
     case AVERROR(ENOENT):
         fprintf(stderr, "%s: no such file or directory\n", filename);
         break;
+#ifdef CONFIG_NETWORK
     case AVERROR(FF_NETERROR(EPROTONOSUPPORT)):
         fprintf(stderr, "%s: Unsupported network protocol\n", filename);
         break;
+#endif
     default:
         fprintf(stderr, "%s: Error while opening file\n", filename);
         break;