mirror of https://bitbucket.org/ausocean/av.git
Merge branch 'RevidCLI' of https://bitbucket.org/ausocean/av/src into RevidCLI
This commit is contained in:
commit
bf5a2075bb
|
@ -30,7 +30,7 @@ package main
|
|||
import (
|
||||
"flag"
|
||||
"strconv"
|
||||
"revid"
|
||||
"bitbucket.org/ausocean/av/revid"
|
||||
|
||||
"bitbucket.org/ausocean/IoT/pi/netsender"
|
||||
)
|
||||
|
|
|
@ -199,7 +199,7 @@ func (config *Config) Validate(r *revid) error {
|
|||
return errors.New("Bad packetization option defined in config!")
|
||||
}
|
||||
|
||||
if fpcAsInt, err := strconv.Aoit(config.FramesPerClip); fpc > 0 || err != nil {
|
||||
if fpcAsInt, err := strconv.Atoi(config.FramesPerClip); fpcAsInt > 0 || err != nil {
|
||||
return errors.New("Bad frames per clip in config!")
|
||||
} else {
|
||||
if fpcAsInt == 0 {
|
||||
|
|
|
@ -301,7 +301,8 @@ func (r *revid) packClips() {
|
|||
for {
|
||||
// Get some memory from the ring buffer for out clip
|
||||
var clip []byte
|
||||
if clip, err := r.ringBuffer.Get(); err != nil {
|
||||
var err error
|
||||
if clip, err = r.ringBuffer.Get(); err != nil {
|
||||
r.Log(Error, err.Error())
|
||||
r.Log(Warning, "Clearing output chan!")
|
||||
r.flushData()
|
||||
|
|
Loading…
Reference in New Issue