diff mplayer.c @ 13338:1820ef597cdb

quit slave mode command now accepts an exit value, patch by Aurelien Jacobs <aurel at gnuage.org>
author faust3
date Wed, 15 Sep 2004 09:29:10 +0000
parents a7bde33bd7d8
children 1c787349d286
line wrap: on
line diff
--- a/mplayer.c	Wed Sep 15 08:02:51 2004 +0000
+++ b/mplayer.c	Wed Sep 15 09:29:10 2004 +0000
@@ -614,7 +614,7 @@
   if((cmd = mp_input_get_cmd(0,0)) != NULL) {
        switch(cmd->id) {
        case MP_CMD_QUIT:
-	 exit_player_with_rc(MSGTR_Exit_quit, 0);
+	 exit_player_with_rc(MSGTR_Exit_quit, (cmd->nargs > 0)? cmd->args[0].v.i : 0);
        case MP_CMD_PLAY_TREE_STEP: {
 	 eof = (cmd->args[0].v.i > 0) ? PT_NEXT_ENTRY : PT_PREV_ENTRY;
        } break;
@@ -2541,7 +2541,7 @@
       brk_cmd = 1;
     } break;
     case MP_CMD_QUIT : {
-      exit_player_with_rc(MSGTR_Exit_quit, 0);
+      exit_player_with_rc(MSGTR_Exit_quit, (cmd->nargs > 0)? cmd->args[0].v.i : 0);
     }
     case MP_CMD_GRAB_FRAMES : {
       grab_frames=2;