mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-12-03 02:42:19 +08:00
fix: del the error judge
This commit is contained in:
parent
247743fb16
commit
6aec72a5a4
@ -15,9 +15,7 @@
|
|||||||
package genutil
|
package genutil
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"errors"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/OpenIMSDK/tools/errs"
|
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
)
|
)
|
||||||
@ -43,9 +41,6 @@ func OutDir(path string) (string, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func ExitWithError(err error) {
|
func ExitWithError(err error) {
|
||||||
if errors.Is(errs.Unwrap(err), errors.New("SIGTERM EXIT")) {
|
|
||||||
os.Exit(-1)
|
|
||||||
}
|
|
||||||
progName := filepath.Base(os.Args[0])
|
progName := filepath.Base(os.Args[0])
|
||||||
fmt.Fprintf(os.Stderr, "\n\n%s exit -1: \n%+v\n\n", progName, err)
|
fmt.Fprintf(os.Stderr, "\n\n%s exit -1: \n%+v\n\n", progName, err)
|
||||||
os.Exit(-1)
|
os.Exit(-1)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user