core: update play-rfx to work with async-updates

This commit is contained in:
Bernhard Miklautz 2013-06-13 16:38:31 +02:00
parent c96cbb7f74
commit 0c2f6d59dd

View File

@ -126,7 +126,6 @@ BOOL freerdp_connect(freerdp* instance)
update = instance->update; update = instance->update;
s = StreamPool_Take(rdp->transport->ReceivePool, 0);
update->pcap_rfx = pcap_open(settings->PlayRemoteFxFile, FALSE); update->pcap_rfx = pcap_open(settings->PlayRemoteFxFile, FALSE);
if (!update->pcap_rfx) if (!update->pcap_rfx)
@ -139,7 +138,7 @@ BOOL freerdp_connect(freerdp* instance)
pcap_get_next_record_header(update->pcap_rfx, &record); pcap_get_next_record_header(update->pcap_rfx, &record);
Stream_EnsureCapacity(s, record.length); s = StreamPool_Take(rdp->transport->ReceivePool, record.length);
record.data = Stream_Buffer(s); record.data = Stream_Buffer(s);
pcap_get_next_record_content(update->pcap_rfx, &record); pcap_get_next_record_content(update->pcap_rfx, &record);
@ -149,9 +148,9 @@ BOOL freerdp_connect(freerdp* instance)
update->BeginPaint(update->context); update->BeginPaint(update->context);
update_recv_surfcmds(update, Stream_Length(s) , s); update_recv_surfcmds(update, Stream_Length(s) , s);
update->EndPaint(update->context); update->EndPaint(update->context);
Stream_Release(s);
} }
Stream_Release(s);
return TRUE; return TRUE;
} }
} }