use log.Print instead of fmt.Print in examples

This commit is contained in:
aler9
2022-01-31 18:39:36 +01:00
parent 8251fe3556
commit 79fdb2b7b4
15 changed files with 40 additions and 39 deletions

View File

@@ -1,7 +1,7 @@
package main
import (
"fmt"
"log"
"github.com/aler9/gortsplib"
"github.com/aler9/gortsplib/pkg/base"
@@ -71,7 +71,7 @@ func main() {
return
}
// decode H264 NALUs from RTP packets
// decode H264 NALUs from the RTP packet
nalus, _, err := dec.Decode(&pkt)
if err != nil {
return
@@ -79,7 +79,7 @@ func main() {
// print NALUs
for _, nalu := range nalus {
fmt.Printf("received H264 NALU of size %d\n", len(nalu))
log.Printf("received H264 NALU of size %d\n", len(nalu))
}
}