From: Adam Tkac Date: Wed, 8 Dec 2010 16:26:29 +0000 (+0000) Subject: [Bugfix] Fix various compilation warnings. X-Git-Tag: v1.0.90~94 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=76ffb8ef1cb8d5e9419d6d7f6c07234e74fbd69b;p=tigervnc.git [Bugfix] Fix various compilation warnings. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4224 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- diff --git a/unix/xserver/hw/vnc/Input.cc b/unix/xserver/hw/vnc/Input.cc index e23f3d37..c0e28bcc 100644 --- a/unix/xserver/hw/vnc/Input.cc +++ b/unix/xserver/hw/vnc/Input.cc @@ -325,9 +325,8 @@ public: void press() { - int state, index, maxKeysPerMod, keycode; + int state, maxKeysPerMod, keycode; #if XORG >= 17 - int ret; KeyCode *modmap = NULL; state = XkbStateFieldFromRec(&dev->u.master->key->xkbInfo->state); @@ -360,7 +359,6 @@ public: int state, maxKeysPerMod; KeyClassPtr keyc; #if XORG >= 17 - int ret; KeyCode *modmap = NULL; keyc = dev->u.master->key; @@ -511,7 +509,9 @@ static struct altKeysym_t { void InputDevice::keyEvent(rdr::U32 keysym, bool down) { +#if XORG < 17 DeviceIntPtr master; +#endif KeyClassPtr keyc; KeySymsPtr keymap = NULL; KeySym *map = NULL; @@ -795,6 +795,7 @@ static KeyCode KeysymToKeycode(KeySymsPtr keymap, KeySym ks, int* col) return 0; } +#if XORG < 17 /* Fairly standard US PC Keyboard */ #define MIN_KEY 8 @@ -962,6 +963,7 @@ static Bool GetMappings(KeySymsPtr pKeySyms, CARD8 *pModMap) return TRUE; } +#endif static void keyboardBell(int percent, DeviceIntPtr device, pointer ctrl, int class_) @@ -972,8 +974,10 @@ static void keyboardBell(int percent, DeviceIntPtr device, pointer ctrl, static int keyboardProc(DeviceIntPtr pDevice, int onoff) { +#if XORG < 17 KeySymsRec keySyms; CARD8 modMap[MAP_LENGTH]; +#endif DevicePtr pDev = (DevicePtr)pDevice; switch (onoff) { diff --git a/unix/xserver/hw/vnc/xvnc.cc b/unix/xserver/hw/vnc/xvnc.cc index cc15d79f..56912f90 100644 --- a/unix/xserver/hw/vnc/xvnc.cc +++ b/unix/xserver/hw/vnc/xvnc.cc @@ -166,7 +166,6 @@ static int lastScreen = -1; static Bool Render = TRUE; static bool displaySpecified = false; -static bool wellKnownSocketsCreated = false; static char displayNumStr[16]; char *listenaddr = NULL; @@ -838,7 +837,6 @@ static miPointerScreenFuncRec vfbPointerCursorFuncs = { static Bool vncRandRGetInfo (ScreenPtr pScreen, Rotation *rotations) { - vfbScreenInfoPtr pvfb = &vfbScreens[pScreen->myNum]; Bool ret, gotCurrent = FALSE; int i;