From 7a7248586c7b1554a178fb376e278da3ba96caa3 Mon Sep 17 00:00:00 2001 From: faust3 Date: Thu, 16 Sep 2004 09:25:56 +0000 Subject: [PATCH] make it possible to use the run command from a menu config file, based on a patch by Aurelien Jacobs git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@13354 b3059339-0415-0410-9bf9-f77b7e298cf2 --- mplayer.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/mplayer.c b/mplayer.c index 2c0a00309a..3869e7de25 100644 --- a/mplayer.c +++ b/mplayer.c @@ -3197,6 +3197,16 @@ if (stream->type==STREAMTYPE_DVDNAV && dvd_nav_still) case MP_CMD_GET_PERCENT_POS : { mp_msg(MSGT_GLOBAL,MSGL_INFO,"ANS_PERCENT_POSITION=%ld\n", demuxer_get_percent_pos(demuxer)); } break; +#ifdef HAVE_MENU + case MP_CMD_CRUN : { +#ifndef __MINGW32__ + if(!fork()) { + execl("/bin/sh","sh","-c",cmd->args[0].v.s,NULL); + exit(0); + } +#endif + } break; +#endif #ifdef USE_DVDNAV case MP_CMD_DVDNAV_EVENT: {