mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
Cover more ST Coroutine code
This commit is contained in:
parent
a9a720e32f
commit
3d5508e088
3 changed files with 100 additions and 9 deletions
|
@ -101,8 +101,12 @@ srs_error_t SrsSTCoroutine::start()
|
|||
srs_error_t err = srs_success;
|
||||
|
||||
if (started || disposed) {
|
||||
err = srs_error_new(ERROR_THREAD_DISPOSED, "failed for disposed=%d, started=%d", disposed, started);
|
||||
|
||||
if (disposed) {
|
||||
err = srs_error_new(ERROR_THREAD_DISPOSED, "disposed");
|
||||
} else {
|
||||
err = srs_error_new(ERROR_THREAD_STARTED, "started");
|
||||
}
|
||||
|
||||
if (trd_err == srs_success) {
|
||||
trd_err = srs_error_copy(err);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue