diff libvo/vo_pnm.c @ 30516:f4e017b6921a

Fix exit_player() usage throughout the codebase. exit_player() was declared with differing parameter types in mplayer.c and mplayer.h. Make the declaration in the .h file match the one in the .c file and adjust all usages of exit_player() throughout the codebase. Also move the exit_player() declaration into mp_core.h next to exit_player_with_rc().
author diego
date Sun, 14 Feb 2010 10:53:20 +0000
parents 1772a5171ac7
children 32725ca88fed
line wrap: on
line diff
--- a/libvo/vo_pnm.c	Sun Feb 14 09:19:30 2010 +0000
+++ b/libvo/vo_pnm.c	Sun Feb 14 10:53:20 2010 +0000
@@ -39,7 +39,7 @@
 #include "mp_msg.h"
 #include "video_out.h"
 #include "video_out_internal.h"
-#include "mplayer.h"			/* for exit_player() */
+#include "mp_core.h"			/* for exit_player() */
 #include "help_mp.h"
 
 /* ------------------------------------------------------------------------- */
@@ -98,7 +98,7 @@
 
 static void pnm_write_error(void) {
     mp_msg(MSGT_VO, MSGL_ERR, MSGTR_ErrorWritingFile, info.short_name);
-    exit_player(MSGTR_Exit_error);
+    exit_player(EXIT_ERROR);
 }
 
 /* ------------------------------------------------------------------------- */
@@ -214,17 +214,17 @@
                             MSGTR_VO_GenericError, strerror(errno) );
                     mp_msg(MSGT_VO, MSGL_ERR, "%s: %s %s\n", info.short_name,
                             MSGTR_VO_UnableToAccess,buf);
-                    exit_player(MSGTR_Exit_error);
+                    exit_player(EXIT_ERROR);
                 }
                 if ( !S_ISDIR(stat_p.st_mode) ) {
                     mp_msg(MSGT_VO, MSGL_ERR, "%s: %s %s\n", info.short_name,
                             buf, MSGTR_VO_ExistsButNoDirectory);
-                    exit_player(MSGTR_Exit_error);
+                    exit_player(EXIT_ERROR);
                 }
                 if ( !(stat_p.st_mode & S_IWUSR) ) {
                     mp_msg(MSGT_VO, MSGL_ERR, "%s: %s - %s\n", info.short_name,
                             buf, MSGTR_VO_DirExistsButNotWritable);
-                    exit_player(MSGTR_Exit_error);
+                    exit_player(EXIT_ERROR);
                 }
 
                 if (strcmp(buf, ".") != 0) {
@@ -238,7 +238,7 @@
                         MSGTR_VO_GenericError, strerror(errno) );
                 mp_msg(MSGT_VO, MSGL_ERR, "%s: %s - %s\n", info.short_name,
                         buf, MSGTR_VO_CantCreateDirectory);
-                exit_player(MSGTR_Exit_error);
+                exit_player(EXIT_ERROR);
         } /* end switch */
     } else if ( verbose ) {
         mp_msg(MSGT_VO, MSGL_INFO, "%s: %s - %s\n", info.short_name,
@@ -442,7 +442,7 @@
 
     if (!mpi) {
         mp_msg(MSGT_VO, MSGL_ERR, "%s: No image data suplied to video output driver\n", info.short_name );
-        exit_player(MSGTR_Exit_error);
+        exit_player(EXIT_ERROR);
     }
 
     /* Start writing to new subdirectory after a certain amount of frames */
@@ -474,7 +474,7 @@
         mp_msg(MSGT_VO, MSGL_ERR, "%s: %s: %s\n",
                 info.short_name, MSGTR_VO_GenericError,
                 strerror(errno) );
-        exit_player(MSGTR_Exit_error);
+        exit_player(EXIT_ERROR);
     }
 
     pnm_write_pnm(outfile, mpi);