diff options
author | Alexey Yakovenko <wakeroid@gmail.com> | 2010-06-24 20:41:24 +0200 |
---|---|---|
committer | Alexey Yakovenko <wakeroid@gmail.com> | 2010-06-24 20:41:24 +0200 |
commit | 6946fe327145719cc59f026d151acf25c788297e (patch) | |
tree | 5acc23c6b08da6bde0a3244e468ed8d415c61333 /playlist.c | |
parent | 7ac75999b8aa8055445bf21da7ae88a5c94b19e5 (diff) |
fixed crashes on accessing NULL playlist at startup
Diffstat (limited to 'playlist.c')
-rw-r--r-- | playlist.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -91,8 +91,11 @@ static uintptr_t mutex_plt; #define GLOBAL_LOCK {pl_global_lock();} #define GLOBAL_UNLOCK {pl_global_unlock();} +static playlist_t dummy_playlist; // used at startup to prevent crashes + int pl_init (void) { + playlist = &dummy_playlist; #if !DISABLE_LOCKING mutex = mutex_create (); mutex_plt = mutex_create (); |