diff options
author | mplayer-svn <svn@mplayerhq.hu> | 2012-08-12 17:57:35 +0000 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2012-08-16 17:16:32 +0200 |
commit | 214edc0ef29104ec0561583318a08e31f384e48e (patch) | |
tree | c16e4981389acfbcff9f0a046ee44f4c402854a3 | |
parent | 4672ff39ddb163c6512985858de4a11f673b6c7b (diff) | |
download | mpv-214edc0ef29104ec0561583318a08e31f384e48e.tar.bz2 mpv-214edc0ef29104ec0561583318a08e31f384e48e.tar.xz |
command: expand properties for "run" command
Change "run" command to expand properties.
Patch by Jan Christoph Uhde [Jan UhdeJc com], documentation
part changed by me.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@35081 b3059339-0415-0410-9bf9-f77b7e298cf2
Author: reimar
-rw-r--r-- | command.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -3372,7 +3372,11 @@ void run_command(MPContext *mpctx, mp_cmd_t *cmd) case MP_CMD_RUN: #ifndef __MINGW32__ if (!fork()) { - execl("/bin/sh", "sh", "-c", cmd->args[0].v.s, NULL); + char *exp_cmd = property_expand_string(mpctx, cmd->args[0].v.s); + if (exp_cmd) { + execl("/bin/sh", "sh", "-c", exp_cmd, NULL); + free(exp_cmd); + } exit(0); } #endif |