channels: cliprdr: remove formatDataResp.dwFlags
authorkubistika <kmizrachi18@gmail.com>
Sun, 15 Sep 2019 10:51:32 +0000 (13:51 +0300)
committerakallabeth <akallabeth@users.noreply.github.com>
Fri, 18 Oct 2019 12:20:26 +0000 (14:20 +0200)
According to the channel docs, this field is only used in format data
request. Therefore, there's no need to hold it in the response. cliprdr
server code was copy-pasted from client code, therefore this must be
some leftover.

client/Wayland/wlf_cliprdr.c
client/X11/xf_cliprdr.c
include/freerdp/channels/cliprdr.h

index 7f6e307..cfd2c06 100644 (file)
@@ -796,7 +796,6 @@ static UINT wlf_cliprdr_clipboard_file_size_success(wClipboardDelegate* delegate
        wfClipboard* clipboard = delegate->custom;
        response.msgFlags = CB_RESPONSE_OK;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_SIZE;
        response.cbRequested = sizeof(UINT64);
        response.requestedData = (BYTE*) &fileSize;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
@@ -810,7 +809,6 @@ static UINT wlf_cliprdr_clipboard_file_size_failure(wClipboardDelegate* delegate
        WINPR_UNUSED(errorCode);
        response.msgFlags = CB_RESPONSE_FAIL;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_SIZE;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
 }
 
@@ -821,7 +819,6 @@ static UINT wlf_cliprdr_clipboard_file_range_success(wClipboardDelegate* delegat
        wfClipboard* clipboard = delegate->custom;
        response.msgFlags = CB_RESPONSE_OK;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_RANGE;
        response.cbRequested = size;
        response.requestedData = (const BYTE*) data;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
@@ -835,7 +832,6 @@ static UINT wlf_cliprdr_clipboard_file_range_failure(wClipboardDelegate* delegat
        WINPR_UNUSED(errorCode);
        response.msgFlags = CB_RESPONSE_FAIL;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_RANGE;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
 }
 
index 1f041fb..befc112 100644 (file)
@@ -1517,7 +1517,6 @@ static UINT xf_cliprdr_send_file_contents_failure(CliprdrClientContext* context,
        CLIPRDR_FILE_CONTENTS_RESPONSE response = { 0 };
        response.msgFlags = CB_RESPONSE_FAIL;
        response.streamId = fileContentsRequest->streamId;
-       response.dwFlags = fileContentsRequest->dwFlags;
        return context->ClientFileContentsResponse(context, &response);
 }
 
@@ -1560,7 +1559,6 @@ static UINT xf_cliprdr_clipboard_file_size_success(wClipboardDelegate* delegate,
        xfClipboard* clipboard = delegate->custom;
        response.msgFlags = CB_RESPONSE_OK;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_SIZE;
        response.cbRequested = sizeof(UINT64);
        response.requestedData = (BYTE*) &fileSize;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
@@ -1575,7 +1573,6 @@ static UINT xf_cliprdr_clipboard_file_size_failure(wClipboardDelegate* delegate,
 
        response.msgFlags = CB_RESPONSE_FAIL;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_SIZE;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
 }
 
@@ -1586,7 +1583,6 @@ static UINT xf_cliprdr_clipboard_file_range_success(wClipboardDelegate* delegate
        xfClipboard* clipboard = delegate->custom;
        response.msgFlags = CB_RESPONSE_OK;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_RANGE;
        response.cbRequested = size;
        response.requestedData = (BYTE*) data;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
@@ -1601,7 +1597,6 @@ static UINT xf_cliprdr_clipboard_file_range_failure(wClipboardDelegate* delegate
 
        response.msgFlags = CB_RESPONSE_FAIL;
        response.streamId = request->streamId;
-       response.dwFlags = FILECONTENTS_RANGE;
        return clipboard->context->ClientFileContentsResponse(clipboard->context, &response);
 }
 
index d341438..de1ff7f 100644 (file)
@@ -227,7 +227,6 @@ struct _CLIPRDR_FILE_CONTENTS_RESPONSE
        DEFINE_CLIPRDR_HEADER_COMMON();
 
        UINT32 streamId;
-       UINT32 dwFlags;
        UINT32 cbRequested;
        const BYTE* requestedData;
 };