forked from External/mediamtx
confwatcher: remove redundant code (#2592)
This commit is contained in:
parent
88dd8d23f4
commit
f11f39f023
1 changed files with 1 additions and 8 deletions
|
|
@ -29,16 +29,9 @@ type ConfWatcher struct {
|
|||
|
||||
// New allocates a ConfWatcher.
|
||||
func New(confPath string) (*ConfWatcher, error) {
|
||||
if _, err := os.Stat(confPath); err != nil {
|
||||
if confPath == "mediamtx.yml" {
|
||||
confPath = "rtsp-simple-server.yml"
|
||||
if _, err := os.Stat(confPath); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
} else {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
|
||||
inner, err := fsnotify.NewWatcher()
|
||||
if err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue