Pavlin Radoslavov

Updated the IpAddress serialization/deserialization

inside class IpAddressSerializer to exclude reading/writing
the prefix length for IpAddress, because it is not applicable.
...@@ -24,7 +24,6 @@ public class IpAddressSerializer extends Serializer<IpAddress> { ...@@ -24,7 +24,6 @@ public class IpAddressSerializer extends Serializer<IpAddress> {
24 byte[] octs = object.toOctets(); 24 byte[] octs = object.toOctets();
25 output.writeInt(octs.length); 25 output.writeInt(octs.length);
26 output.writeBytes(octs); 26 output.writeBytes(octs);
27 - output.writeInt(object.prefixLength());
28 } 27 }
29 28
30 @Override 29 @Override
...@@ -32,8 +31,7 @@ public class IpAddressSerializer extends Serializer<IpAddress> { ...@@ -32,8 +31,7 @@ public class IpAddressSerializer extends Serializer<IpAddress> {
32 final int octLen = input.readInt(); 31 final int octLen = input.readInt();
33 byte[] octs = new byte[octLen]; 32 byte[] octs = new byte[octLen];
34 input.readBytes(octs); 33 input.readBytes(octs);
35 - int prefLen = input.readInt(); 34 + return IpAddress.valueOf(octs);
36 - return IpAddress.valueOf(octs, prefLen);
37 } 35 }
38 36
39 } 37 }
......