Commit f76c8194 authored by Wouter Van Meir's avatar Wouter Van Meir Committed by Johannes Schindelin

Call MallocFrameBuffer before SetFormatAndEncodings

The hook is still called after InitialiseRFBConnection() so we can choose
the color settings depending on the vnc server (or settings) in that hook.

This way one can use the "VNC server default format" pixelformat if the
client supports it, or perform a workaround (Intel AMT KVM "classic vnc"
server only works using 8bit colors in RFB3.8)
Signed-off-by: 's avatarWouter Van Meir <wouter.vanmeir@pandora.be>
Signed-off-by: 's avatarJohannes Schindelin <johannes.schindelin@gmx.de>
parent 09f7c684
......@@ -221,13 +221,13 @@ static rfbBool rfbInitConnection(rfbClient* client)
if (!InitialiseRFBConnection(client))
return FALSE;
if (!SetFormatAndEncodings(client))
return FALSE;
client->width=client->si.framebufferWidth;
client->height=client->si.framebufferHeight;
client->MallocFrameBuffer(client);
if (!SetFormatAndEncodings(client))
return FALSE;
if (client->updateRect.x < 0) {
client->updateRect.x = client->updateRect.y = 0;
client->updateRect.w = client->width;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment