Stream_Write_UINT8(data_out, 0x10 | cbChId);
Stream_SetPosition(s, 1);
- Stream_Copy(data_out, s, pos - 1);
-
+ Stream_Copy(s, data_out, pos - 1);
+
if (channel_status == CHANNEL_RC_OK)
{
WLog_DBG(TAG, "channel created");
if (!Stream_EnsureRemainingCapacity(ifman->output, ifman->input_size + 4))
return ERROR_OUTOFMEMORY;
pos = Stream_GetPosition(ifman->output);
- Stream_Copy(ifman->output, ifman->input, ifman->input_size);
+ Stream_Copy(ifman->input, ifman->output, ifman->input_size);
Stream_SetPosition(ifman->output, pos);
if (Stream_GetRemainingLength(ifman->output) < 4)
* Fast-Path packet format is defined in [MS-RDPBCGR] 2.2.9.1.2, which revises
* server output packets from the first byte with the goal of improving
* bandwidth.
- *
+ *
* Slow-Path packet always starts with TPKT header, which has the first
* byte 0x03, while Fast-Path packet starts with 2 zero bits in the first
* two less significant bits of the first byte.
if (!fastpath_recv_update_synchronize(fastpath, s))
WLog_ERR(TAG, "fastpath_recv_update_synchronize failure but we continue");
else
- IFCALL(update->Synchronize, context);
+ IFCALL(update->Synchronize, context);
break;
case FASTPATH_UPDATETYPE_SURFCMDS:
Stream_SetPosition(fastpath->updateData, 0);
- Stream_Copy(fastpath->updateData, cs, size);
+ Stream_Copy(cs, fastpath->updateData, size);
}
else if (fragmentation == FASTPATH_FRAGMENT_NEXT)
{
goto out_fail;
}
- Stream_Copy(fastpath->updateData, cs, size);
+ Stream_Copy(cs, fastpath->updateData, size);
}
else if (fragmentation == FASTPATH_FRAGMENT_LAST)
{
goto out_fail;
}
- Stream_Copy(fastpath->updateData, cs, size);
+ Stream_Copy(cs, fastpath->updateData, size);
Stream_SealLength(fastpath->updateData);
Stream_SetPosition(fastpath->updateData, 0);
out_fail:
if (cs != s) {
- Stream_Release(cs);
+ Stream_Release(cs);
}
return -1;
if (!wParam)
return FALSE;
- Stream_Copy(wParam, s, Stream_GetRemainingLength(s));
+ Stream_Copy(s, wParam, Stream_GetRemainingLength(s));
Stream_SetPosition(wParam, 0);
return MessageQueue_Post(context->update->queue, (void*) context,
Stream_Seek(_s, _n);
}
-static INLINE void Stream_Copy(wStream* _dst, wStream* _src, size_t _n)
+static INLINE void Stream_Copy(wStream* _src, wStream* _dst, size_t _n)
{
memcpy(_dst->pointer, _src->pointer, _n);
Stream_Seek(_dst, _n);