Browse Source

[Bugfix] Find correct colormap in XserverDesktop::serverReset method


git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3020 3789f03b-4d11-0410-bbf8-ca57d06f2519
tags/v0.0.90
Adam Tkac 15 years ago
parent
commit
23bf1135a8
1 changed files with 11 additions and 3 deletions
  1. 11
    3
      unix/xserver/hw/vnc/XserverDesktop.cc

+ 11
- 3
unix/xserver/hw/vnc/XserverDesktop.cc View File

@@ -23,6 +23,7 @@
#include <dix-config.h>
#endif

#include <assert.h>
#include <stdio.h>
#include <strings.h>
#include <unistd.h>
@@ -247,9 +248,16 @@ XserverDesktop::~XserverDesktop()
void XserverDesktop::serverReset(ScreenPtr pScreen_)
{
pScreen = pScreen_;
XID* ids = new XID[pScreen->maxInstalledCmaps];
cmap = (ColormapPtr)LookupIDByType(ids[0], RT_COLORMAP);
delete [] ids;
int i;
pointer retval;

i = dixLookupResource(&retval, pScreen->defColormap, RT_COLORMAP, NullClient,
DixReadAccess);

/* Handle suspicious conditions */
assert(i != Success);

cmap = (ColormapPtr) retval;
}

char* XserverDesktop::substitute(const char* varName)

Loading…
Cancel
Save