Added client bandwidth measurement result callback.
This commit is contained in:
parent
1810656199
commit
e239c10fb9
@ -29,6 +29,7 @@ typedef BOOL (*pBandwidthMeasureStart)(rdpContext* context, UINT16 sequenceNumbe
|
||||
typedef BOOL (*pBandwidthMeasureStop)(rdpContext* context, UINT16 sequenceNumber);
|
||||
typedef BOOL (*pBandwidthMeasureResults)(rdpContext* context, UINT16 sequenceNumber);
|
||||
typedef BOOL (*pNetworkCharacteristicsResult)(rdpContext* context, UINT16 sequenceNumber);
|
||||
typedef BOOL (*pClientBandwidthMeasureResult)(rdpContext* context, rdpAutoDetect* data);
|
||||
|
||||
struct rdp_autodetect
|
||||
{
|
||||
@ -52,7 +53,8 @@ struct rdp_autodetect
|
||||
ALIGN64 pBandwidthMeasureStop BandwidthMeasureStop; /* 19 */
|
||||
ALIGN64 pBandwidthMeasureResults BandwidthMeasureResults; /* 20 */
|
||||
ALIGN64 pNetworkCharacteristicsResult NetworkCharacteristicsResult; /* 21 */
|
||||
UINT64 paddingB[32 - 22]; /* 22 */
|
||||
ALIGN64 pClientBandwidthMeasureResult ClientBandwidthMeasureResult; /* 22 */
|
||||
UINT64 paddingB[32 - 23]; /* 23 */
|
||||
};
|
||||
|
||||
|
||||
|
@ -224,6 +224,7 @@ BOOL autodetect_send_connecttime_bandwidth_measure_stop(rdpContext* context, UIN
|
||||
|
||||
static BOOL autodetect_send_bandwidth_measure_results(rdpRdp* rdp, UINT16 responseType, UINT16 sequenceNumber)
|
||||
{
|
||||
BOOL success = TRUE;
|
||||
wStream* s;
|
||||
UINT32 timeDelta;
|
||||
|
||||
@ -246,6 +247,12 @@ static BOOL autodetect_send_bandwidth_measure_results(rdpRdp* rdp, UINT16 respon
|
||||
Stream_Write_UINT32(s, timeDelta); /* timeDelta (4 bytes) */
|
||||
Stream_Write_UINT32(s, rdp->autodetect->bandwidthMeasureByteCount); /* byteCount (4 bytes) */
|
||||
|
||||
IFCALLRET(rdp->autodetect->ClientBandwidthMeasureResult, success,
|
||||
rdp->context, rdp->autodetect);
|
||||
|
||||
if (!success)
|
||||
return FALSE;
|
||||
|
||||
return rdp_send_message_channel_pdu(rdp, s, SEC_AUTODETECT_RSP);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user