summaryrefslogtreecommitdiff
path: root/src/libpiano/piano.c
diff options
context:
space:
mode:
authorMichał Cichoń <michcic@gmail.com>2018-10-30 13:12:47 +0100
committerMichał Cichoń <michcic@gmail.com>2018-10-30 13:12:47 +0100
commitcb6789b17f81d29c6884c27715c705083e09a5db (patch)
treed6a47c38ff7dcb937992b15dc3c2d051bb877ac8 /src/libpiano/piano.c
parentcd5c65097ecf03480f477e47e0bb706dbf705a21 (diff)
parent82a13ad77bfcf2c6dc37fe0d1d55f93372db6509 (diff)
downloadpianobar-windows-master.tar.gz
pianobar-windows-master.tar.bz2
pianobar-windows-master.zip
Merge branch 'release/2018.10.30'HEAD2018.10.30master
Diffstat (limited to 'src/libpiano/piano.c')
-rw-r--r--src/libpiano/piano.c6
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) {