This commit is contained in:
simon.kagstrom 2010-02-06 16:22:52 +00:00
parent 43070ad2d9
commit c8c231ebb2
2 changed files with 3 additions and 2 deletions

View File

@ -969,8 +969,8 @@ bool Network::AppendScreenshot(NetworkUpdatePeerInfo *pi)
data = DataStore::ds->embedData(png, sz);
if (!data)
goto out_png;
ud = InitNetworkUpdate(this->ud, 0, sizeof(NetworkUpdate) +
sizeof(NetworkUpdateDataStore) + sz);
ud = InitNetworkUpdate(this->ud, REGISTER_DATA,
sizeof(NetworkUpdate) + sizeof(NetworkUpdateDataStore) + sz);
dsu = (NetworkUpdateDataStore *)ud->data;
dsu->key = data->key;
dsu->metadata = data->metadata;

View File

@ -34,6 +34,7 @@ typedef enum
ACK = 94, /* Answer to broker */
BANDWIDTH_PING = 92, /* Large packet to calculate bandwidth */
BANDWIDTH_ACK = 91, /* Answer to BANDWIDTH_PING */
REGISTER_DATA = 90, /* Register data (screenshots typically) */
/* Non-data messages */
STOP = 55, /* End of this update sequence */
/* Data transfer of various kinds */