diff --git a/README.md b/README.md index c5e745369..af075e970 100755 --- a/README.md +++ b/README.md @@ -209,6 +209,7 @@ Please select according to languages: ### V2 changes +* v2.0, 2018-01-04, Merge [#1039][bug #1039], fix bug of init.d script. * v2.0, 2018-01-01, Merge [#1033][bug #1033], allow user to add some specific flags. 2.0.244 * v2.0, 2017-06-10, [2.0 release2(2.0.243)][r2.0r2] released. 86670 lines. * v2.0, 2017-05-29, Merge [#899][bug #899] to fix [#893][bug #893], ts PES ext length. 2.0.243 @@ -1403,6 +1404,7 @@ Winlin [bug #893]: https://github.com/ossrs/srs/issues/893 [bug #899]: https://github.com/ossrs/srs/issues/899 [bug #1033]: https://github.com/ossrs/srs/issues/1033 +[bug #1039]: https://github.com/ossrs/srs/issues/1039 [bug #xxxxxxxxxx]: https://github.com/ossrs/srs/issues/xxxxxxxxxx [bug #735]: https://github.com/ossrs/srs/issues/735 diff --git a/trunk/etc/init.d/srs b/trunk/etc/init.d/srs index 12e5d6cb3..2c0e92e71 100755 --- a/trunk/etc/init.d/srs +++ b/trunk/etc/init.d/srs @@ -62,7 +62,7 @@ load_process_info() { start() { # if exists, exit. load_process_info - if [[ 0 -eq $? ]]; then failed_msg "SRS started(pid ${srs_pid}), should not start it again."; return 0; fi + if [[ 0 -eq $? ]]; then failed_msg "SRS started(pid ${srs_pid}), should not start it again."; return 1; fi # not exists, start server ok_msg "Starting SRS..." @@ -95,7 +95,7 @@ start() { # check whether started. load_process_info - ret=$?; if [[ 0 -eq $? ]]; then ok_msg "SRS started(pid ${srs_pid})"; return 0; fi + ret=$?; if [[ 0 -eq $ret ]]; then ok_msg "SRS started(pid ${srs_pid})"; return 0; fi failed_msg "SRS not started" return $ret