소스 검색

重复10次19

TitanWong 1 년 전
부모
커밋
1da05cd942
1개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 3 3
      src/main/java/com/zhili/stationcontrol/tts/service/impl/MusicServiceImpl.java

+ 3 - 3
src/main/java/com/zhili/stationcontrol/tts/service/impl/MusicServiceImpl.java

@@ -56,11 +56,11 @@ public class MusicServiceImpl implements MusicService, Runnable {
     }
 
 
-    @SneakyThrows
     @Override
+    @SneakyThrows
     public void run() {
         while (true) {
-            Thread.sleep(500);
+            Thread.sleep(100);
             synchronized (this) {
                 try {
                     log.info("----------");
@@ -90,7 +90,7 @@ public class MusicServiceImpl implements MusicService, Runnable {
                                 log.info("repeat");
                                 p = Runtime.getRuntime().exec(cmd);
                             } else {
-                                return;
+                                break;
                             }
                         } else {
                             p = Runtime.getRuntime().exec(cmd);