Commit Graph

470 Commits

Author SHA1 Message Date
Saxon 8606320731 revid: ignoring rtmp.ErrInvalidFlvTag error and checking that rtmp conn is not closed before we try to close it 2019-03-03 18:24:54 +10:30
scruzin 89d9bf3eef Return errors from the loop in connect() rather than breaking. 2019-01-20 10:28:05 +10:30
scruzin a362d1d2ab connect() now closes c.link.conn upon an error. 2019-01-20 09:50:51 +10:30
scruzin fbad21bc76 connect() now constructs its packet with a buf to avoid needless packet resizing later. 2019-01-20 08:52:58 +10:30
scruzin 42be87d98a sendConnectPacket() now encodes required link info in one go using amf.Encode(). 2019-01-20 07:33:43 +10:30
scruzin de07f1ae40 dStreamId renamed streamID. 2019-01-19 17:20:34 +10:30
scruzin b77283aa3b packet.header renamed buf. 2019-01-19 16:38:40 +10:30
scruzin 998d41c96f Session now Conn, init() moved into Dial(), and connectStream() merged into connect(). 2019-01-19 13:12:24 +10:30
scruzin 974d9a484b Fixed packetTypeBytesReadReport case in handlePacket and added debug logging. 2019-01-19 11:30:59 +10:30
scruzin 9e6d875089 Remove ! after Dan. 2019-01-15 14:59:30 +10:30
scruzin 3ab2c1f69a Reverted Session.clientBW2 to uint8. 2019-01-14 10:31:42 +10:30
scruzin e778488aba Session.inChunkSize, outChunkSize, nBytesIn, nBytesInSent, serverBW, clientBW and clientBW2 now all uint32 to avoid needless conversions. 2019-01-14 10:17:47 +10:30
scruzin 82c010b6f7 packet.read/write -> readFrom/writeTo. 2019-01-13 13:09:29 +10:30
scruzin bef7177c5a Removed used Session.checkCounter and link.token. 2019-01-13 13:04:05 +10:30
scruzin 60af77017d Remove superfluous error declarations. 2019-01-13 12:52:06 +10:30
scruzin 40ce3357eb Removed unused code for unwritable links, and collapsed unhandled cases in switch statments. 2019-01-13 09:47:04 +10:30
scruzin 8898ee3add setupURL() now a method on Session and renamed init(). 2019-01-13 09:18:52 +10:30
scruzin f1e46461c3 Removed unused swfUrl, pageUrl, swfAge and flashVer from link and renamed tcUrl to url. 2019-01-13 09:12:41 +10:30
scruzin 2219a26890 Removed unused Session.encoding and sendEncoding. 2019-01-13 07:29:36 +10:30
scruzin 40806d4de7 Removed unused extras from rtmp.link. 2019-01-13 07:11:25 +10:30
scruzin 32c281d2dc Added type-specific wrappers for amf.Object.GetProperty, namely GetNumber, GetString and GetObject. 2019-01-12 18:43:51 +10:30
scruzin 5b94ddfbe9 Renamed Object.Props to Properties. 2019-01-12 18:04:04 +10:30
scruzin 2105339657 Export Property members so getters are no longer required and made amf.GetProp a method on Object. 2019-01-12 16:10:09 +10:30
scruzin f7de9526c8 Removed Reset and PropReset which are not required. 2019-01-12 15:29:58 +10:30
scruzin 1fe1849393 amf.Decode and amf.PropDecode now return an error. 2019-01-12 14:55:12 +10:30
scruzin b79a035d0f Added error return value to all encoding functions. 2019-01-12 14:18:50 +10:30
scruzin 255464d85a amf.AMF now amf.Object, amf type consts now prefixed with type and vu struct merged into Property. 2019-01-12 08:56:57 +10:30
scruzin f13d4010cc Moved AMF functions into a new rtmp/amf package; names otherwise unchanged. 2019-01-12 07:13:27 +10:30
scruzin 19f245ae76 First cut at AMF refactoring; use idiomatic names. 2019-01-12 06:42:34 +10:30
scruzin e78cc93432 minDataSize is out and flvTagheaderSize is in! 2019-01-11 16:00:00 +10:30
scruzin 22b76b5bda Session.read()/write() both now return (int, error). 2019-01-11 10:35:20 +10:30
scruzin 5be5aad6cf Idiomatic names for constants (1st pass). 2019-01-11 09:52:21 +10:30
scruzin 94446beddb Split remaining code in rtmp_headers across rtmp.go and session.go. 2019-01-11 00:19:50 +10:30
scruzin 7bb9fcc2c7 Remove superfluous call to handlePacket() from connectStream(). 2019-01-11 00:10:29 +10:30
scruzin b388f5374f Removed superfluous url param from setupURL() and obtain it from the Session object instead. 2019-01-11 00:06:44 +10:30
scruzin 53bccaaaa7 Simplifed connectStream(). 2019-01-11 00:01:26 +10:30
scruzin f635be6712 Propagate errors from handleInvoke(). 2019-01-10 23:48:11 +10:30
scruzin 058cc41356 readPacket(), sendPacket() and resizePacket() now Packet methods read(), write() and resize() respectively. 2019-01-10 23:29:51 +10:30
scruzin 6a8e78a256 readN()/writeN() now Session.read()/write() respectfully. 2019-01-10 23:16:20 +10:30
scruzin 26e8133a6e Merge Session.write() into Session.Write(). 2019-01-10 23:05:24 +10:30
scruzin 56a3bf8b26 Simplified Session.write(). 2019-01-10 22:52:43 +10:30
scruzin 3dbaa810fc Additional logging. 2019-01-10 12:49:52 +10:30
scruzin 076a9c030a Better field names. 2019-01-09 22:51:07 +10:30
scruzin c386f45bbd Removed out of date comment. 2019-01-09 22:25:10 +10:30
scruzin 0a69c59f50 Additional logging. 2019-01-09 17:33:19 +10:30
scruzin 88e1415b10 Include pkg name in fatal log messages. 2019-01-09 16:08:02 +10:30
scruzin cbe6149c8f Added proper logging. 2019-01-07 23:59:41 +10:30
Alan Noble c4bc4f7c61 Set debugMode false by default. 2019-01-07 11:49:14 +00:00
scruzin 04679e4757 Removed used fields and initalize packets lazily. 2019-01-07 21:45:00 +10:30
scruzin 0b869523b4 Removed packet member from Session. 2019-01-07 20:16:11 +10:30