mirror of https://bitbucket.org/ausocean/av.git
revid-cli: allow setting of udp address through revid-cli options
This commit is contained in:
parent
2ff7e6318d
commit
8be3c4de23
|
@ -316,5 +316,9 @@ func (c *Config) Validate(r *Revid) error {
|
|||
return errors.New("quantisation not unsigned integer or is over threshold")
|
||||
}
|
||||
}
|
||||
|
||||
if c.UdpAddress == "" {
|
||||
c.UdpAddress = defaultUdpAddr
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
|
|
@ -228,7 +228,7 @@ func (r *Revid) reset(config Config) error {
|
|||
case Http:
|
||||
r.destination = newHttpSender(r.ns, r.config.Logger.Log)
|
||||
case Udp:
|
||||
s, err := newUdpSender(defaultUdpAddr, r.config.Logger.Log)
|
||||
s, err := newUdpSender(r.config.UdpAddress, r.config.Logger.Log)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue