Skip to content

Sending a payload of (2^24−1) bytes #514

Closed
@BohuTANG

Description

@BohuTANG

Issue description

By reference:
https://dev.mysql.com/doc/internals/en/sending-more-than-16mbyte.html
Sending a payload of 16 777 215 (2^24−1) bytes looks like:

ff ff ff 00 ...
00 00 00 01

In this case, readPacket will get an unexpected error in:
https://github.com/go-sql-driver/mysql/blob/master/packets.go#L41

		if pktLen < 1 {
			errLog.Print(ErrMalformPkt)
			mc.Close()
			return nil, driver.ErrBadConn
		}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions