Skip to content

Modified condition from gt to gte for distinguishing OK Packet from EOF Packet #594

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sql/protocol_classic.cc
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ bool net_send_error(NET *net, uint sql_errno, const char *err) {
</table>

These rules distinguish whether the packet represents OK or EOF:
- OK: header = 0 and length of packet > 7
- OK: header = 0 and length of packet >= 7
- EOF: header = 0xfe and length of packet < 9

To ensure backward compatibility between old (prior to 5.7.5) and
Expand Down