mirror of https://bitbucket.org/ausocean/av.git
rtmp: remove unused C_AMF_DecodeArray
This commit is contained in:
parent
d88f0601bb
commit
e649a94612
20
rtmp/amf.go
20
rtmp/amf.go
|
@ -557,26 +557,6 @@ func C_AMF_EncodeArray(obj *C_AMFObject, dst []byte) []byte {
|
|||
return dst
|
||||
}
|
||||
|
||||
// int AMF_DecodeArray(AMFObject *obj, const char *pBuffer, int nSize, int nArrayLen, int bDecodeName);
|
||||
// amf.c +993
|
||||
func C_AMF_DecodeArray(obj *C_AMFObject, data []byte, nArrayLen, bDecodeName int32) int32 {
|
||||
nOriginalSize := len(data)
|
||||
|
||||
obj.o_props = obj.o_props[:0]
|
||||
for ; nArrayLen > 0 && len(data) != 0; nArrayLen-- {
|
||||
|
||||
var prop C_AMFObjectProperty
|
||||
nRes := C_AMFProp_Decode(&prop, data, bDecodeName)
|
||||
if nRes == -1 {
|
||||
return -1
|
||||
}
|
||||
data = data[nRes:]
|
||||
obj.o_props = append(obj.o_props, prop)
|
||||
}
|
||||
|
||||
return int32(nOriginalSize - len(data))
|
||||
}
|
||||
|
||||
// int AMF_Decode(AMFObject *obj, const char* pBuffer, int nSize, int bDecodeName);
|
||||
// amf.c +1180
|
||||
func C_AMF_Decode(obj *C_AMFObject, pBuffer *byte, nSize, bDecodeName int32) int32 {
|
||||
|
|
Loading…
Reference in New Issue