diff options
Diffstat (limited to 'funcs/func_timeout.c')
-rw-r--r-- | funcs/func_timeout.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/funcs/func_timeout.c b/funcs/func_timeout.c index a400a95ab..1da11e54a 100644 --- a/funcs/func_timeout.c +++ b/funcs/func_timeout.c @@ -46,6 +46,9 @@ static int timeout_read(struct ast_channel *chan, const char *cmd, char *data, { time_t myt; + if (!chan) + return -1; + if (!data) { ast_log(LOG_ERROR, "Must specify type of timeout to get.\n"); return -1; @@ -91,6 +94,9 @@ static int timeout_write(struct ast_channel *chan, const char *cmd, char *data, char timestr[64]; struct tm myt; + if (!chan) + return -1; + if (!data) { ast_log(LOG_ERROR, "Must specify type of timeout to set.\n"); return -1; |