]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
api command sent through sched_api was getting the last char lopped off
authorMichael Collins <msc@freeswitch.org>
Sat, 13 Dec 2008 04:57:27 +0000 (04:57 +0000)
committerMichael Collins <msc@freeswitch.org>
Sat, 13 Dec 2008 04:57:27 +0000 (04:57 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@10748 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/applications/mod_commands/mod_commands.c

index cb315a140991bba8f02ecccba391f05cec94564c..677c5fa8da517b4fd03926d86781aa55eba99c73 100644 (file)
@@ -2106,7 +2106,7 @@ SWITCH_STANDARD_API(sched_api_function)
                        }
 
                        switch_zmalloc(api_task, sizeof(*api_task) + strlen(dcmd) + 1);
-                       switch_copy_string(api_task->cmd, dcmd, strlen(dcmd));
+                       switch_copy_string(api_task->cmd, dcmd, strlen(dcmd) + 1);
                        api_task->recur = recur;
 
                        id = switch_scheduler_add_task(when, sch_api_callback, (char *) __SWITCH_FUNC__, group, 0, api_task, SSHF_FREE_ARG);