All pastes #124707 Raw Edit

Anonymous

public text v1 · immutable
·published 2006-08-10 05:59 UTC
rendered paste body
        char dialstring[2048] = "";
        char *tmp = dialstring;
        size_t len = sizeof(dialstring);
        struct sla_originate_helper *slal;
        pthread_attr_t attr;
        pthread_t th;
        int reason = 0;
        struct ast_channel *chan = NULL;
        
        ASTOBJ_CONTAINER_TRAVERSE(&sla->stations, 1, {
             ast_build_string(&tmp, &len, "%s%s/%s", 
                     ast_strlen_zero(dialstring) ? "" : "&", iterator->tech, iterator->dest);
        });

        ast_verbose("Dial String %s\n",dialstring);

        if (!ast_strlen_zero(dialstring))
                ast_pbx_outgoing_app("local", AST_FORMAT_SLINEAR, "1001", 99999, "dial", dialstring, &reason, 1,
                        S_OR(orig->cid.cid_num, NULL),
                        S_OR(orig->cid.cid_name, NULL),
                        NULL, NULL, &chan);
        /* Locked by ast_pbx_outgoing_exten or ast_pbx_outgo