summaryrefslogtreecommitdiffstats
path: root/libqdb
diff options
context:
space:
mode:
authorKari Oikarinen <kari.oikarinen@qt.io>2016-06-27 15:48:11 +0300
committerKari Oikarinen <kari.oikarinen@qt.io>2016-08-23 08:12:56 +0000
commit178198621734906e6a5c40274058d6435277fb4f (patch)
treed7bfa02b8995719ad69b0e501305e83b3d3d92a8 /libqdb
parent1adcf3d43554d3601e8e998d3993ed36c0fff3b0 (diff)
Introduce version number to the protocol
Version number is sent as uint32 in the payload of the initial Connect message. For now Server always responds to the Connect message with the only protocol version that it knows, but also prints a warning if the asked for protocol version was not the same. Connection checks the version in the response and transitions to Connected state only if the version matches. Change-Id: I937af5a7e1f6bb5056efc03777178bed86b451d4 Reviewed-by: Kimmo Ollila <kimmo.ollila@theqtcompany.com>
Diffstat (limited to 'libqdb')
-rw-r--r--libqdb/protocol/protocol.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/libqdb/protocol/protocol.h b/libqdb/protocol/protocol.h
index c27e072..42a3081 100644
--- a/libqdb/protocol/protocol.h
+++ b/libqdb/protocol/protocol.h
@@ -29,5 +29,6 @@ const uint8_t qdbUsbProtocolId = 0x1;
const int qdbHeaderSize = 4*sizeof(uint32_t);
const int qdbMessageSize = 16*1024;
const int qdbMaxPayloadSize = qdbMessageSize - qdbHeaderSize;
+const uint32_t qdbProtocolVersion = 0;
#endif