diff options
author | Lars-Dominik Braun <PromyLOPh@lavabit.com> | 2010-03-13 12:28:45 +0100 |
---|---|---|
committer | Lars-Dominik Braun <PromyLOPh@lavabit.com> | 2010-03-16 20:28:55 +0100 |
commit | b17fed7cf3d1ee7e0fef5de51e1d1cbacc21a06b (patch) | |
tree | 6ba30d4b6ff4ccbb849ebd1476ae049512272b91 /src/player.c | |
parent | 97d9c978334236f9ba190da342eb11f645ccde03 (diff) | |
download | pianobar-b17fed7cf3d1ee7e0fef5de51e1d1cbacc21a06b.tar.gz pianobar-b17fed7cf3d1ee7e0fef5de51e1d1cbacc21a06b.tar.bz2 pianobar-b17fed7cf3d1ee7e0fef5de51e1d1cbacc21a06b.zip |
Replace player return value magic
Diffstat (limited to 'src/player.c')
-rw-r--r-- | src/player.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/player.c b/src/player.c index 2eb6e27..051220c 100644 --- a/src/player.c +++ b/src/player.c @@ -404,7 +404,7 @@ static WaitressCbReturn_t BarPlayerMp3Cb (void *ptr, size_t size, void *stream) void *BarPlayerThread (void *data) { struct audioPlayer *player = data; char extraHeaders[25]; - void *ret = NULL; + void *ret = PLAYER_RET_OK; #ifdef ENABLE_FAAD NeAACDecConfigurationPtr conf; #endif @@ -444,7 +444,7 @@ void *BarPlayerThread (void *data) { default: BarUiMsg (MSG_ERR, "Unsupported audio format!\n"); - return NULL; + return PLAYER_RET_OK; break; } @@ -480,7 +480,7 @@ void *BarPlayerThread (void *data) { break; } if (player->aoError) { - ret = (void *) 0x1; + ret = (void *) PLAYER_RET_ERR; } ao_close(player->audioOutDevice); WaitressFree (&player->waith); @@ -493,7 +493,5 @@ void *BarPlayerThread (void *data) { player->mode = PLAYER_FINISHED_PLAYBACK; - /* return NULL == everything's fine, everything else: hard error, stop - * playback */ return ret; } |