diff options
author | wm4 <wm4@nowhere> | 2014-12-10 18:28:09 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-12-10 18:28:09 +0100 |
commit | efd3f6f0d24a17c6c44b2bd5bdd0f42f2631ca8d (patch) | |
tree | 3d84464246e44e810c58fc61d29573f8ff31c542 /player | |
parent | f0cdd673a80ff8f89b3f4c136620e398217bfccf (diff) | |
download | mpv-efd3f6f0d24a17c6c44b2bd5bdd0f42f2631ca8d.tar.bz2 mpv-efd3f6f0d24a17c6c44b2bd5bdd0f42f2631ca8d.tar.xz |
command: fix crash with some forms of script_binding
"script_binding name ..." just crashed it. Oops.
Diffstat (limited to 'player')
-rw-r--r-- | player/command.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/player/command.c b/player/command.c index 66ab4eb95f..2387eb25d8 100644 --- a/player/command.c +++ b/player/command.c @@ -4511,7 +4511,7 @@ int run_command(MPContext *mpctx, mp_cmd_t *cmd) char *sep = strchr(name, '/'); char *target = NULL; char space[MAX_CLIENT_NAME]; - if (name) { + if (sep) { snprintf(space, sizeof(space), "%.*s", (int)(sep - name), name); target = space; name = sep + 1; |