diff --git a/apps/app_dial.c b/apps/app_dial.c index c18858021e..74b51d9749 100644 --- a/apps/app_dial.c +++ b/apps/app_dial.c @@ -1575,7 +1575,7 @@ static int dial_exec_full(struct ast_channel *chan, void *data, struct ast_flags if (!res) { if (calldurationlimit > 0) { - chan->whentohangup = time(NULL) + calldurationlimit; + peer->whentohangup = time(NULL) + calldurationlimit; } if (!ast_strlen_zero(dtmfcalled)) { if (option_verbose > 2)