280a281,283 > /*! \brief queues.conf [general] option */ > static int global_wrapuptime = 0; > 2640a2644,2669 > /*! \brief Update lastcall time of member in all queues it belongs > * > * We iterate through all the queues and update the lastcall time of every member > * that shares the same interface with the agent that just ended the call. > * This makes wrapuptime work through different queues with "shared" members. > */ > static void update_member_lastcall(struct member *member){ > struct call_queue *q; > struct member *cur; > struct ao2_iterator mem_iter; > > ast_verbose(VERBOSE_PREFIX_3 "Updating all the others Queues that share this interface (%s)...\n", member->interface); > AST_LIST_LOCK(&queues); > AST_LIST_TRAVERSE(&queues, q, list) { > ao2_lock(q); > mem_iter = ao2_iterator_init(q->members, 0); > while ((cur = ao2_iterator_next(&mem_iter))) { > if ( member && ( strcasecmp(cur->interface, member->interface) == 0 ) ) { > time(&cur->lastcall); > } > } > ao2_unlock(q); > } > AST_LIST_UNLOCK(&queues); > } > 2644c2673,2674 < time(&member->lastcall); --- > if (! global_wrapuptime) > time(&member->lastcall); 2649a2680,2681 > if (global_wrapuptime) > update_member_lastcall(member); 4526a4559,4561 > global_wrapuptime = 0; > if ((general_val = ast_variable_retrieve(cfg, "general", "global_wrapuptime"))) > global_wrapuptime = ast_true(general_val);