2023-08-09 16:00:21 +05:00
|
|
|
package rtmp
|
|
|
|
|
|
|
|
import (
|
|
|
|
"net"
|
2023-08-10 03:24:00 +05:00
|
|
|
"fmt"
|
2023-08-09 16:00:21 +05:00
|
|
|
)
|
|
|
|
|
2023-08-10 01:02:22 +05:00
|
|
|
func NegotiateConnect(conn net.Conn) (bool) {
|
2023-08-10 12:49:26 +05:00
|
|
|
open_chnkstrms, open_msgs, chunk_bufs := OpenStreamsMapInit()
|
|
|
|
full_msg_ptr, err := ReadChunk(conn, open_chnkstrms, open_msgs, 4096, chunk_bufs)
|
2023-08-10 03:24:00 +05:00
|
|
|
if err != nil {
|
|
|
|
return false
|
|
|
|
}
|
|
|
|
fmt.Printf("%08b\n", full_msg_ptr.data)
|
2023-08-10 12:49:26 +05:00
|
|
|
full_msg_ptr, err = ReadChunk(conn, open_chnkstrms, open_msgs, 4096, chunk_bufs)
|
2023-08-10 03:24:00 +05:00
|
|
|
if err != nil {
|
|
|
|
return false
|
|
|
|
}
|
|
|
|
fmt.Printf("%08b\n", full_msg_ptr.data)
|
2023-08-10 01:02:22 +05:00
|
|
|
return false
|
2023-08-09 16:00:21 +05:00
|
|
|
}
|