time_t to = 0;
switch_core_session_t *rsession;
+ if (!cmd) {
+ stream->write_function(stream, "USAGE: %s\n", TONE_DETECT_SYNTAX);
+ return SWITCH_STATUS_SUCCESS;
+ }
+
mydata = strdup(cmd);
assert(mydata != NULL);
SWITCH_STANDARD_API(sched_del_function)
{
uint32_t cnt = 0;
+
+ if (!cmd) {
+ stream->write_function(stream, "Invalid syntax\n");
+ return SWITCH_STATUS_SUCCESS;
+ }
if (switch_is_digit_string(cmd)) {
int64_t tmp;
char *dcommand, *edata = NULL, *send = NULL, *command, *arg = NULL;
switch_stream_handle_t mystream = { 0 };
int encoded = 0, elen = 0;
+
+ if (!cmd) {
+ stream->write_function(stream, "Invalid syntax\n");
+ return SWITCH_STATUS_SUCCESS;
+ }
if ((dcommand = strdup(cmd))) {
if (!strncasecmp(dcommand, "encoded ", 8)) {
char *tm = NULL, *dcmd, *group;
time_t when;
- assert(cmd != NULL);
+ if (!cmd) {
+ stream->write_function(stream, "Invalid syntax\n");
+ return SWITCH_STATUS_SUCCESS;
+ }
tm = strdup(cmd);
assert(tm != NULL);