[icecast-dev] fallback source give up and returns to original source

iceuse at kezako.net iceuse at kezako.net
Tue Jan 20 05:32:29 PST 2004

I merged the fallback-override feature in icecast-kh22. I'll send you the 4 modified files
(perhaps you want to integrate them in your release, but also I'm not sure about locking or not the main source
before moving the clients :
    if(source->fallback_override && source->fallback_mount) {
        /* get fallback source */
        avl_tree_rlock (global.source_tree);
        source_t *fallback_source = source_find_mount (source->fallback_mount);
        avl_tree_unlock (global.source_tree);

        if (fallback_source) {
            INFO2 ("passing %d listeners to %s", fallback_source->mount,source->listeners );
            /* Do we need to lock the current source? */
            thread_mutex_lock   (&fallback_source->lock);
            source_move_clients (fallback_source, source);
            thread_mutex_unlock (&fallback_source->lock);
(this code is added in source.c:source_init)

--- >8 ----
List archives:  http://www.xiph.org/archives/
icecast project homepage: http://www.icecast.org/
To unsubscribe from this list, send a message to 'icecast-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.

More information about the Icecast-dev mailing list