Add PLAYLIST_SORT_LENGTH. Patch from Diogo Vieira (bug #244).