diff options
author | Lars-Dominik Braun <PromyLOPh@lavabit.com> | 2009-03-01 15:14:11 +0100 |
---|---|---|
committer | Lars-Dominik Braun <PromyLOPh@lavabit.com> | 2009-03-01 15:14:11 +0100 |
commit | f0e240d8d79d359279a823973b1499bc09c4dff3 (patch) | |
tree | aadedcdbed9a15cbe0475e9a02803d037bc147c6 | |
parent | 1383525f1287365673591b6286034c74f3f213ff (diff) | |
download | pianobar-windows-f0e240d8d79d359279a823973b1499bc09c4dff3.tar.gz pianobar-windows-f0e240d8d79d359279a823973b1499bc09c4dff3.tar.bz2 pianobar-windows-f0e240d8d79d359279a823973b1499bc09c4dff3.zip |
Don't add shared station when input empty
-rw-r--r-- | src/ui_act.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ui_act.c b/src/ui_act.c index 8782532..1ba4277 100644 --- a/src/ui_act.c +++ b/src/ui_act.c @@ -131,7 +131,8 @@ void BarUiActCreateStation (BAR_KS_ARGS) { void BarUiActAddSharedStation (BAR_KS_ARGS) { char *stationId = NULL; - if ((stationId = readline ("Station id: ")) != NULL) { + if ((stationId = readline ("Station id: ")) != NULL && + strlen (stationId) > 0) { BarUiMsg ("Adding shared station... "); BarUiPrintPianoStatus (PianoCreateStation (ph, "sh", stationId)); free (stationId); |