[asterisk-dev] [Code Review] Autologoff when using AgentLogin

Russell Bryant russell at digium.com
Fri Apr 17 06:27:32 CDT 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.digium.com/r/225/#review707
-----------------------------------------------------------


Also, swing by my office sometime so we can discuss why this type of setup is useful.


/trunk/channels/chan_agent.c
<http://reviewboard.digium.com/r/225/#comment1836>

    Why did this code get removed?
    
    if (persistent_agents)
        dump_agents();
    
    



/trunk/channels/chan_agent.c
<http://reviewboard.digium.com/r/225/#comment1838>

    1) I think you should use >= instead of >.
    
    2) You're calling time() a couple of times here.  You could store the result in a variable to avoid calling it twice.


- Russell


On 2009-04-16 18:05:59, David Vossel wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.digium.com/r/225/
> -----------------------------------------------------------
> 
> (Updated 2009-04-16 18:05:59)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Summary
> -------
> 
> Here's the scenario: An agent logs in by calling an extension that calls the AgentLogin app.  In agents.conf ackcall=always is set, so when they get a call they have the choice to either acknowledge it or ignore it.  autologoff=10 is set as well, so if the agent ignores the call over 10sec one may assume that the agent should be logged out (and in this case hungup on as well), but this does not happen.  
> 
> This patch makes autologout happen in this case.  Honestly, I have no idea why a user would want to set up agents like this, but there is a bug report for it.  Since its been like this forever, could this break expected behavior?
> 
>  
> 
> 
> This addresses bug 14091.
>     http://bugs.digium.com/view.php?id=14091
> 
> 
> Diffs
> -----
> 
>   /trunk/channels/chan_agent.c 188742 
> 
> Diff: http://reviewboard.digium.com/r/225/diff
> 
> 
> Testing
> -------
> 
> set up queue and agents.  Logged in as agent using AgentLogin.  Called into the queue on another line, never acknowledged the call on the agent, agent logged out and hung up after 10seconds, other call remained in queue.  Logged agent back in and acknowledged the call in queue, lines were bridged, hooray.    
> 
> 
> Thanks,
> 
> David
> 
>




More information about the asterisk-dev mailing list