diff --git a/src/main/java/org/mariadb/jdbc/internal/common/packet/PacketOutputStream.java b/src/main/java/org/mariadb/jdbc/internal/common/packet/PacketOutputStream.java
index <HASH>..<HASH> 100644
--- a/src/main/java/org/mariadb/jdbc/internal/common/packet/PacketOutputStream.java
+++ b/src/main/java/org/mariadb/jdbc/internal/common/packet/PacketOutputStream.java
@@ -10,7 +10,7 @@ public class PacketOutputStream extends OutputStream{
     private static final int MAX_PACKET_LENGTH = 0x00ffffff;

     private static final int SEQNO_OFFSET = 3;

     private static final int HEADER_LENGTH = 4;

-    private static final int MAX_SEQNO = 0xff;

+    private static final int MAX_SEQNO = 0xffff;

 

 

     OutputStream baseStream;
Fixed "MySQL Protocol limit reached" error (when sending data > 2GB) by setting
MAX_SEQNO to max integer value.