diff options
author | 2009-08-04 22:03:54 +0200 | |
---|---|---|
committer | 2009-08-04 22:03:54 +0200 | |
commit | fbbbd7436a347595e925c5ba8b69e8875b5c73bc (patch) | |
tree | d01626b2c77327a6caebbc54c7acbae1eb11159d /playlist.c | |
parent | 7bccab7d4a27e554259637f4ed23356519433549 (diff) |
fixed playlist insertion
Diffstat (limited to 'playlist.c')
-rw-r--r-- | playlist.c | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -526,16 +526,17 @@ ps_insert_item (playItem_t *after, playItem_t *it) { playlist_head = it; } else { - it->next = after; - it->prev = after->prev; - if (after->prev) { - after->prev->next = it; + it->prev= after; + it->next = after->next; + if (after->next) { + after->next->prev = it; } - after->prev = it; + after->next = it; if (after == playlist_tail) { playlist_tail = it; } } + ps_count++; return it; } |