Wrong bracketing in FieldPacket.write

The argument should be converted to an integer, not the (ignored) result