Output error lines

This commit is contained in:
Stephen Seo 2021-09-16 16:33:40 +09:00
parent 28fa5e1a32
commit 217125eaee

View file

@ -289,6 +289,8 @@ fn info_loop(shared_data: Arc<Mutex<Shared>>) -> Result<(), String> {
//println!("Got response: {}", line); //println!("Got response: {}", line);
if line.starts_with("OK") { if line.starts_with("OK") {
break; break;
} else if line.starts_with("ACK") {
println!("ERROR: {}", line);
} else if line.starts_with("file: ") { } else if line.starts_with("file: ") {
let song_file = line.split_off(6); let song_file = line.split_off(6);
if song_file != lock.current_song { if song_file != lock.current_song {