1
0
mirror of https://gitlab.xiph.org/xiph/icecast-server.git synced 2024-12-04 14:46:30 -05:00

Feature: playlist history for ICY based streams.

This patch adds support for history for ICY based streams.
Of cause this has the same limits for metedata as ICY has.

See: #766
This commit is contained in:
Philipp Schafft 2015-03-28 18:14:41 +00:00
parent 961453b0de
commit bfbb8f207c
2 changed files with 6 additions and 0 deletions

View File

@ -181,6 +181,7 @@ static void filter_shoutcast_metadata (source_t *source, char *metadata, unsigne
stats_event_conv (source->mount, "title", p, source->format->charset);
yp_touch (source->mount);
free (p);
playlist_push_track(source->history, &source->format->vc);
}
} while (0);
}

View File

@ -141,6 +141,11 @@ int playlist_push_track(playlist_t *playlist, vorbis_comment *vc)
track->creator = __query_vc(vc, "ARTIST");
track->album = __query_vc(vc, "ALBUM");
track->trackNum = __query_vc(vc, "TRACKNUMBER");
if (!track->title && !track->creator && !track->album && !track->trackNum) {
/* no useful meta data has been found. try ICY style meta data */
track->title = __query_vc(vc, "X_ICY_TITLE");
}
}
return 0;