pull/801/head
gedoor 4 years ago
parent 3b9613b644
commit c62f798d55
  1. 4
      app/src/main/java/io/legado/app/service/HttpReadAloudService.kt

@ -14,9 +14,7 @@ import io.legado.app.utils.FileUtils
import io.legado.app.utils.LogUtils import io.legado.app.utils.LogUtils
import io.legado.app.utils.MD5Utils import io.legado.app.utils.MD5Utils
import io.legado.app.utils.postEvent import io.legado.app.utils.postEvent
import kotlinx.coroutines.delay
import kotlinx.coroutines.isActive import kotlinx.coroutines.isActive
import kotlinx.coroutines.launch
import org.jetbrains.anko.collections.forEachWithIndex import org.jetbrains.anko.collections.forEachWithIndex
import java.io.File import java.io.File
import java.io.FileDescriptor import java.io.FileDescriptor
@ -115,6 +113,8 @@ class HttpReadAloudService : BaseReadAloudService(),
val fis = FileInputStream(file) val fis = FileInputStream(file)
playAudio(fis.fd) playAudio(fis.fd)
} }
} else {
removeSpeakCacheFile(fileName)
} }
} }
} catch (e: SocketTimeoutException) { } catch (e: SocketTimeoutException) {

Loading…
Cancel
Save