]> git.sesse.net Git - vlc/blobdiff - modules/mux/mpjpeg.c
Swedish translation update by Daniel Nylander
[vlc] / modules / mux / mpjpeg.c
index 257b357e42052a386eb254e10a550481e4814ea8..0d53522a5977fde31a1cc9553b116f0e4e86b526 100644 (file)
 # include "config.h"
 #endif
 
-#include <vlc/vlc.h>
+#include <vlc_common.h>
+#include <vlc_plugin.h>
 #include <vlc_sout.h>
 #include <vlc_block.h>
-#include <vlc_codecs.h>
 
 /*****************************************************************************
  * Module descriptor
@@ -44,7 +44,7 @@ static void Close  ( vlc_object_t * );
 
 vlc_module_begin();
     set_shortname( "MPJPEG" );
-    set_description( _("Multipart JPEG muxer") );
+    set_description( N_("Multipart JPEG muxer") );
     set_capability( "sout mux", 5 );
     add_obsolete_string( SOUT_CFG_PREFIX "separator" );
     set_category( CAT_SOUT );
@@ -62,6 +62,7 @@ static int DelStream( sout_mux_t *, sout_input_t * );
 static int Mux      ( sout_mux_t * );
 
 /* This pseudo-random sequence is unlikely to ever happen */
+/* This should be the same as in src/network/httpd.c */
 #define BOUNDARY "7b3cc56e5f51db803f790dad720ed50a"
 
 /*****************************************************************************
@@ -96,19 +97,19 @@ static void Close( vlc_object_t * p_this )
 static int Control( sout_mux_t *p_mux, int i_query, va_list args )
 {
     VLC_UNUSED(p_mux);
-    vlc_bool_t *pb_bool;
+    bool *pb_bool;
     char **ppsz;
 
     switch( i_query )
     {
         case MUX_CAN_ADD_STREAM_WHILE_MUXING:
-            pb_bool = (vlc_bool_t*)va_arg( args, vlc_bool_t * );
-            *pb_bool = VLC_TRUE;
+            pb_bool = (bool*)va_arg( args, bool * );
+            *pb_bool = true;
             return VLC_SUCCESS;
 
         case MUX_GET_ADD_STREAM_WAIT:
-            pb_bool = (vlc_bool_t*)va_arg( args, vlc_bool_t * );
-            *pb_bool = VLC_TRUE;
+            pb_bool = (bool*)va_arg( args, bool * );
+            *pb_bool = true;
             return VLC_SUCCESS;
 
         case MUX_GET_MIME:
@@ -164,7 +165,7 @@ static int Mux( sout_mux_t *p_mux )
         static const char psz_hfmt[] = "\r\n"
             "--"BOUNDARY"\r\n"
             "Content-Type: image/jpeg\r\n"
-            "Content-Length: %u\r\n"
+            "Content-Length: %zu\r\n"
             "\r\n";
         block_t *p_data = block_FifoGet( p_fifo );
         block_t *p_header = block_New( p_mux, sizeof( psz_hfmt ) + 20 );