diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2017-10-02 12:12:01 +0200 |
---|---|---|
committer | Michał Cichoń <michcic@gmail.com> | 2018-10-30 12:04:15 +0100 |
commit | ed3ab2743344dfe2b38427733560b9847d259c8c (patch) | |
tree | bba0f0fd3ff661c13c3cb8d65566c73c0a58e13c /src/libpiano | |
parent | f43a0894cb1386bbb5c0c1f068a4f60192070658 (diff) | |
download | pianobar-windows-ed3ab2743344dfe2b38427733560b9847d259c8c.tar.gz pianobar-windows-ed3ab2743344dfe2b38427733560b9847d259c8c.tar.bz2 pianobar-windows-ed3ab2743344dfe2b38427733560b9847d259c8c.zip |
Show station in song lists
Iff song’s station is not the current station. This is only the case for
the song history right now.
Closes #638
Diffstat (limited to 'src/libpiano')
-rw-r--r-- | src/libpiano/piano.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/libpiano/piano.c b/src/libpiano/piano.c index c496ea1..7f1eff9 100644 --- a/src/libpiano/piano.c +++ b/src/libpiano/piano.c @@ -214,7 +214,11 @@ void PianoDestroyRequest (PianoRequest_t *req) { */ PianoStation_t *PianoFindStationById (PianoStation_t * const stations, const char * const searchStation) { - assert (searchStation != NULL); + assert (stations != NULL); + + if (searchStation == NULL) { + return NULL; + } PianoStation_t *currStation = stations; PianoListForeachP (currStation) { |