Unverified Commit 92d80639 authored by Mihai Moldovan's avatar Mihai Moldovan

Merge branch 'sunweaver-pr/version-cmdline-option' into 3.6.x

Attributes GH PR #660: https://github.com/ArcticaProject/nx-libs/pull/660 Fixes: ArcticaProject/nx-libs#653 Fixes: ArcticaProject/nx-libs#639
parents 75176042 0371276f
......@@ -124,7 +124,7 @@ extern int _XGetBitsPerPixel(Display *dpy, int depth);
extern char dispatchExceptionAtReset;
extern const char *__progname;
const char *nxagentProgName;
char nxagentDisplayName[NXAGENTDISPLAYNAMELENGTH];
Bool nxagentSynchronize = False;
......@@ -185,6 +185,8 @@ int ddxProcessArgument(int argc, char *argv[], int i)
* Ensure that the options are set to their defaults.
*/
nxagentProgName = argv[0];
static Bool resetOptions = True;
if (resetOptions == True)
......@@ -336,6 +338,12 @@ int ddxProcessArgument(int argc, char *argv[], int i)
return 0;
}
if (!strcmp(argv[i], "-version"))
{
nxagentShowVersionInfo();
exit(0);
}
/*
* This had to be '-options' since the beginning
* but was '-option' by mistake. Now we have to
......@@ -1179,13 +1187,13 @@ static void nxagentParseOptions(char *name, char *value)
{
#if !defined(PANORAMIX) && !defined(RANDR)
nxagentChangeOption(Xinerama, 0);
fprintf(stderr, "Warning: No Xinerama support compiled into %s.\n", __progname);
fprintf(stderr, "Warning: No Xinerama support compiled into %s.\n", nxagentProgName);
return;
#else
if (PANORAMIX_DISABLED_COND && RRXINERAMA_DISABLED_COND)
{
nxagentChangeOption(Xinerama, 0);
fprintf(stderr, "Warning: XINERAMA extension has been disabled on %s startup.\n", __progname);
fprintf(stderr, "Warning: XINERAMA extension has been disabled on %s startup.\n", nxagentProgName);
return;
}
......@@ -2075,7 +2083,7 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio
return useNXTrans;
}
void ddxUseMsg()
void ddxUseMsg(void)
{
ErrorF("-display string display name of the real server\n");
ErrorF("-sync synchronize with the real server\n");
......@@ -2089,6 +2097,7 @@ void ddxUseMsg()
ErrorF("-install install colormaps directly\n");
ErrorF("The NX system adds the following arguments:\n");
ErrorF("-options file|string file or string containing nx/nx options\n");
ErrorF("-forcenx force use of NX protocol messages assuming communication through nxproxy\n");
ErrorF("-timeout int auto-disconnect timeout in seconds (minimum allowed: 60)\n");
ErrorF("-norootlessexit don't exit if there are no clients in rootless mode\n");
......@@ -2112,9 +2121,10 @@ void ddxUseMsg()
ErrorF("-R enable rootless mode\n");
ErrorF("-S enable shadow mode\n");
ErrorF("-B enable proxy binding mode\n");
ErrorF("-version show version information and exit\n");
}
static int nxagentGetDialogName()
static int nxagentGetDialogName(void)
{
if (*nxagentSessionId != '\0')
{
......@@ -2298,7 +2308,7 @@ void nxagentSetPackMethod(void)
* of involved drawables.
*/
void nxagentSetDeferLevel()
void nxagentSetDeferLevel(void)
{
int deferLevel;
int tileWidth;
......@@ -2478,7 +2488,7 @@ void nxagentSetDeferLevel()
}
}
void nxagentSetBufferSize()
void nxagentSetBufferSize(void)
{
int size;
......@@ -2537,7 +2547,7 @@ void nxagentSetBufferSize()
}
}
void nxagentSetScheduler()
void nxagentSetScheduler(void)
{
/*
* The smart scheduler is the default.
......@@ -2553,7 +2563,7 @@ void nxagentSetScheduler()
}
}
void nxagentSetCoalescence()
void nxagentSetCoalescence(void)
{
int timeout;
......@@ -2609,3 +2619,7 @@ void nxagentSetCoalescence()
nxagentChangeOption(DisplayCoalescence, timeout);
}
void nxagentShowVersionInfo(void)
{
ErrorF("NXAGENT - Version " NX_VERSION_CURRENT_STRING "\n");
}
......@@ -96,6 +96,8 @@ void nxagentSetBufferSize(void);
void nxagentSetScheduler(void);
void nxagentSetCoalescence(void);
void nxagentShowVersionInfo(void);
extern int nxagentUserDefinedFontPath;
extern int nxagentRemoteMajor;
......
......@@ -114,7 +114,7 @@ static void catchAndRedirect(Display* dpy, XErrorEvent* X)
}
}
static void startWMDetection()
static void startWMDetection(void)
{
/*
* We are trying to detect if is there any client
......@@ -420,7 +420,7 @@ static void nxagentWriteAtom(Atom local, Atom remote, const char *string, Bool d
* the Xserver values and the atom names.
*/
void nxagentResetAtomMap()
void nxagentResetAtomMap(void)
{
unsigned i;
......
......@@ -133,7 +133,7 @@ int nxagentCheckBinder(int argc, char *argv[], int i)
return 0;
}
int nxagentBinderLoop()
int nxagentBinderLoop(void)
{
struct timeval timeout;
......
......@@ -253,7 +253,7 @@ void nxagentCheckIfShadowAgent(ClientPtr client)
}
}
void nxagentWakeupByReconnect()
void nxagentWakeupByReconnect(void)
{
int i;
......
......@@ -1027,7 +1027,7 @@ void nxagentNotifySelection(XEvent *X)
* requests from real X clients.
*/
void nxagentResetSelectionOwner()
void nxagentResetSelectionOwner(void)
{
int i;
......
......@@ -50,7 +50,7 @@
int nxagentCompositeEnable = UNDEFINED;
void nxagentCompositeExtensionInit()
void nxagentCompositeExtensionInit(void)
{
/*
* Set the flag only if the initialization
......@@ -115,7 +115,7 @@ void nxagentCompositeExtensionInit()
#endif
}
void nxagentRedirectDefaultWindows()
void nxagentRedirectDefaultWindows(void)
{
int i;
......
......@@ -392,7 +392,7 @@ void nxagentReconnectCursor(void * p0, XID x1, void * p2)
* The parameter is ignored at the moment.
*/
void nxagentReDisplayCurrentCursor()
void nxagentReDisplayCurrentCursor(void)
{
CursorPtr pCursor = GetSpriteCursor();
......@@ -518,7 +518,7 @@ void nxagentDisconnectCursor(void * p0, XID x1, void * p2)
}
}
Bool nxagentDisconnectAllCursor()
Bool nxagentDisconnectAllCursor(void)
{
int i;
Bool r = True;
......
......@@ -525,7 +525,7 @@ void nxagentTerminateDialog(DialogType type)
#endif
}
void nxagentTerminateDialogs()
void nxagentTerminateDialogs(void)
{
DialogType type;
......
......@@ -200,7 +200,7 @@ unsigned long startTime;
extern void RejectWellKnownSockets(void);
extern Bool nxagentReportWindowIds;
int nxagentServerOrder()
int nxagentServerOrder(void)
{
int whichbyte = 1;
......@@ -800,7 +800,7 @@ static int nxagentDisplayErrorPredicate(Display *display, int error)
return error;
}
void nxagentInstallDisplayHandlers()
void nxagentInstallDisplayHandlers(void)
{
/*
* If the display was already opened, be sure
......@@ -849,7 +849,7 @@ void nxagentInstallDisplayHandlers()
NXSetDisplayErrorPredicate(nxagentDisplayErrorPredicate);
}
void nxagentPostInstallDisplayHandlers()
void nxagentPostInstallDisplayHandlers(void)
{
/*
* This is executed after having opened the
......@@ -880,7 +880,7 @@ FIXME: What is the most appropriate number of elements?
XSetErrorHandler(nxagentErrorHandler);
}
void nxagentResetDisplayHandlers()
void nxagentResetDisplayHandlers(void)
{
if (nxagentDisplay != NULL)
{
......@@ -934,7 +934,7 @@ void nxagentResetDisplayHandlers()
nxagentDispatch.start = 0;
}
void nxagentInstallSignalHandlers()
void nxagentInstallSignalHandlers(void)
{
#ifdef TEST
fprintf(stderr, "nxagentInstallSignalHandlers: Installing the agent signal handlers.\n");
......@@ -1040,7 +1040,7 @@ void nxagentInstallSignalHandlers()
}
}
void nxagentPostInstallSignalHandlers()
void nxagentPostInstallSignalHandlers(void)
{
#ifdef TEST
fprintf(stderr, "nxagentPostInstallSignalHandlers: Dealing with the proxy signal handlers.\n");
......@@ -1079,7 +1079,7 @@ void nxagentPostInstallSignalHandlers()
*/
}
void nxagentResetSignalHandlers()
void nxagentResetSignalHandlers(void)
{
struct sigaction newAction;
......@@ -1553,7 +1553,7 @@ void nxagentInitVisuals(void)
nxagentSetDefaultVisual();
}
void nxagentInitDepths()
void nxagentInitDepths(void)
{
#ifdef TEST
int i;
......@@ -1586,7 +1586,7 @@ void nxagentInitDepths()
#endif
}
void nxagentInitPixmapFormats()
void nxagentInitPixmapFormats(void)
{
int i, j;
int depth;
......@@ -1673,7 +1673,7 @@ XXX: Some X server doesn't list 1 among available depths...
#endif
}
void nxagentSetDefaultDrawables()
void nxagentSetDefaultDrawables(void)
{
int i, j;
......@@ -1744,7 +1744,7 @@ void nxagentSetDefaultDrawables()
}
}
void nxagentCloseDisplay()
void nxagentCloseDisplay(void)
{
#ifdef TEST
fprintf(stderr, "nxagentCloseDisplay: Called with full generation [%d] and display [%p].\n",
......@@ -1984,7 +1984,7 @@ Bool nxagentMakeIcon(Display *display, Pixmap *nxIcon, Pixmap *nxMask)
return success;
}
Bool nxagentXServerGeometryChanged()
Bool nxagentXServerGeometryChanged(void)
{
return (WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) !=
WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplayBackup))) ||
......@@ -2124,7 +2124,7 @@ void nxagentDisconnectDisplay(void)
reconnectDisplayState = NOTHING;
}
static int nxagentCheckForDefaultDepthCompatibility()
static int nxagentCheckForDefaultDepthCompatibility(void)
{
/*
* Depending on the (reconnect) tolerance checks value, this
......@@ -2190,7 +2190,7 @@ static int nxagentCheckForDefaultDepthCompatibility()
}
}
static int nxagentCheckForDepthsCompatibility()
static int nxagentCheckForDepthsCompatibility(void)
{
/*
* Depending on the (reconnect) tolerance checks value, this
......@@ -2348,7 +2348,7 @@ static int nxagentCheckForDepthsCompatibility()
return (ret);
}
static int nxagentCheckForPixmapFormatsCompatibility()
static int nxagentCheckForPixmapFormatsCompatibility(void)
{
/*
* Depending on the (reconnect) tolerance checks value, this
......@@ -2881,7 +2881,7 @@ Bool nxagentReconnectDisplay(void *p0)
return True;
}
void nxagentAddXConnection()
void nxagentAddXConnection(void)
{
int fd = XConnectionNumber(nxagentDisplay);
......@@ -2895,7 +2895,7 @@ void nxagentAddXConnection()
SetNotifyFd(XConnectionNumber(nxagentDisplay), nxagentNotifyConnection, X_NOTIFY_READ, NULL);
}
void nxagentRemoveXConnection()
void nxagentRemoveXConnection(void)
{
#ifdef TEST
fprintf(stderr, "nxagentRemoveXConnection: Removing the X connection [%d] "
......@@ -2912,7 +2912,7 @@ void nxagentRemoveXConnection()
* NX transport is terminated first.
*/
void nxagentWaitDisplay()
void nxagentWaitDisplay(void)
{
/*
* Disable the smart scheduler's interrupts.
......@@ -2962,7 +2962,7 @@ void nxagentWaitDisplay()
* the Xlib display connection.
*/
void nxagentAbortDisplay()
void nxagentAbortDisplay(void)
{
/*
* Be sure the X server socket in .X11-unix is
......
......@@ -2593,7 +2593,7 @@ void nxagentCorruptedRegionOnWindow(void *p0, XID x, void *p2)
RegionUninit(&visRegion);
}
void nxagentRegionsOnScreen()
void nxagentRegionsOnScreen(void)
{
FindClientResourcesByType(clients[serverClient -> index], RT_NX_CORR_WINDOW,
nxagentCorruptedRegionOnWindow, NULL);
......@@ -3024,7 +3024,7 @@ void nxagentUnmarkExposedRegion(WindowPtr pWin, RegionPtr pRegion, RegionPtr pOt
}
}
int nxagentSynchronizationPredicate()
int nxagentSynchronizationPredicate(void)
{
if (nxagentCorruptedWindows == 0 &&
nxagentCorruptedBackgrounds == 0 &&
......
......@@ -247,7 +247,7 @@ int nxagentExitHandler(const char *message)
return 0;
}
void nxagentOpenClientsLogFile()
void nxagentOpenClientsLogFile(void)
{
if (*nxagentClientsLogName == '\0')
{
......@@ -577,7 +577,7 @@ char *nxagentGetSessionPath(void)
return sessionPath;
}
void nxagentGetClientsPath()
void nxagentGetClientsPath(void)
{
if (*nxagentClientsLogName == '\0')
......
......@@ -281,7 +281,7 @@ int nxagentCheckWindowConfiguration(XConfigureEvent* X);
void nxagentRemoveDuplicatedKeys(XEvent *X);
void ProcessInputEvents()
void ProcessInputEvents(void)
{
#ifdef NX_DEBUG_INPUT
if (nxagentDebugInput == 1)
......@@ -734,7 +734,7 @@ int nxagentInputEventPredicate(Display *display, XEvent *event, XPointer paramet
}
}
void nxagentInitDefaultEventMask()
void nxagentInitDefaultEventMask(void)
{
Mask mask = NoEventMask;
......@@ -3698,7 +3698,7 @@ int nxagentHandleReparentNotify(XEvent* X)
return 1;
}
void nxagentEnableKeyboardEvents()
void nxagentEnableKeyboardEvents(void)
{
int i;
Mask mask;
......@@ -3719,7 +3719,7 @@ void nxagentEnableKeyboardEvents()
NXAGENT_KEYBOARD_EXTENSION_EVENT_MASK);
}
void nxagentDisableKeyboardEvents()
void nxagentDisableKeyboardEvents(void)
{
int i;
Mask mask;
......@@ -3738,7 +3738,7 @@ void nxagentDisableKeyboardEvents()
XkbSelectEvents(nxagentDisplay, XkbUseCoreKbd, 0x0, 0x0);
}
void nxagentEnablePointerEvents()
void nxagentEnablePointerEvents(void)
{
int i;
Mask mask;
......@@ -3755,7 +3755,7 @@ void nxagentEnablePointerEvents()
}
}
void nxagentDisablePointerEvents()
void nxagentDisablePointerEvents(void)
{
int i;
Mask mask;
......@@ -3793,7 +3793,7 @@ void nxagentSendFakeKey(int key)
mieqEnqueue(&fake);
}
int nxagentInitXkbKeyboardState()
int nxagentInitXkbKeyboardState(void)
{
XEvent X;
......@@ -3954,7 +3954,7 @@ void nxagentUngrabPointerAndKeyboard(XEvent *X)
XUngrabPointer(nxagentDisplay, now);
}
void nxagentDeactivatePointerGrab()
void nxagentDeactivatePointerGrab(void)
{
GrabPtr grab = inputInfo.pointer -> grab;
......@@ -4595,7 +4595,7 @@ void nxagentGuessDumpInputInfo(ClientPtr client, Atom property, char *data)
}
}
void nxagentDeactivateInputDevicesGrabs()
void nxagentDeactivateInputDevicesGrabs(void)
{
fprintf(stderr, "Info: Deactivating input devices grabs.\n");
......
......@@ -82,7 +82,7 @@ void DarwinHandleGUI(int argc, char *argv[])
{
}
void DarwinGlxExtensionInit()
void DarwinGlxExtensionInit(void)
{
GlxExtensionInit();
}
......
......@@ -1252,7 +1252,7 @@ static void nxagentFailedFontReconnect(FontPtr pFont, XID param1, void * param2)
return;
}
static void nxagentFreeFailedToReconnectFonts()
static void nxagentFreeFailedToReconnectFonts(void)
{
free(nxagentFailedToReconnectFonts.font);
nxagentFailedToReconnectFonts.font = NULL;
......@@ -1371,7 +1371,7 @@ Bool nxagentReconnectFailedFonts(void *p0)
return True;
}
Bool nxagentDisconnectAllFonts()
Bool nxagentDisconnectAllFonts(void)
{
int cid;
Bool fontSuccess = True;
......
......@@ -962,7 +962,7 @@ static void nxagentAddGCToList(GCPtr pGC)
nxagentGCList.size++;
}
void nxagentFreeGCList()
void nxagentFreeGCList(void)
{
struct nxagentGCRec *tempGC;
......@@ -977,7 +977,7 @@ void nxagentFreeGCList()
}
}
static void nxagentRestoreGCList()
static void nxagentRestoreGCList(void)
{
struct nxagentGCRec *tempGC;
......@@ -1215,7 +1215,7 @@ void nxagentDisconnectGC(void * p0, XID x1, void * p2)
}
}
Bool nxagentDisconnectAllGCs()
Bool nxagentDisconnectAllGCs(void)
{
int cid;
Bool success = True;
......
......@@ -1616,7 +1616,7 @@ void nxagentGetImage(DrawablePtr pDrawable, int x, int y, int w, int h,
* to the new proxy.
*/
void nxagentResetVisualCache()
void nxagentResetVisualCache(void)
{
int i;
......@@ -1626,7 +1626,7 @@ void nxagentResetVisualCache()
}
}
void nxagentResetAlphaCache()
void nxagentResetAlphaCache(void)
{
int i;
......
......@@ -85,9 +85,6 @@ is" without express or implied warranty.
#undef DEBUG
#undef DUMP
#define NXAGENT_VERSION NX_VERSION_CURRENT
#define NXAGENT_VERSION_STRING NX_VERSION_CURRENT_STRING
/*
* ProcVector array defined in tables.c.
*/
......@@ -197,8 +194,8 @@ int nxagentX2go;
void checkX2goAgent()
{
extern const char *__progname;
if( strcasecmp(__progname,"x2goagent") == 0)
extern const char *nxagentProgName;
if( strcasecmp(nxagentProgName,"x2goagent") == 0)
{
fprintf(stderr, "\nrunning as X2Go Agent\n");
nxagentX2go=1;
......@@ -234,7 +231,7 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[])
if (serverGeneration <= 1)
{
fprintf(stderr, "\nNXAGENT - Version " NXAGENT_VERSION_STRING "\n\n");
fprintf(stderr, "\nNXAGENT - Version " NX_VERSION_CURRENT_STRING "\n\n");
fprintf(stderr, "Copyright (c) 2001, 2011 NoMachine (http://www.nomachine.com)\n");
fprintf(stderr, "Copyright (c) 2008-2014 Oleksandr Shneyder <o.shneyder@phoca-gmbh.de>\n");
fprintf(stderr, "Copyright (c) 2011-2016 Mike Gabriel <mike.gabriel@das-netzwerkteam.de>\n");
......@@ -473,7 +470,7 @@ void InitInput(argc, argv)
* by FatalError().
*/
void AbortDDX()
void AbortDDX(void)
{
nxagentDoFullGeneration = True;
......@@ -495,7 +492,7 @@ void AbortDDX()
* Called by GiveUp().
*/
void ddxGiveUp()
void ddxGiveUp(void)
{
AbortDDX();
}
......@@ -504,12 +501,12 @@ void ddxBeforeReset(void)
{
}
void OsVendorInit()
void OsVendorInit(void)
{
return;
}
void OsVendorFatalError()
void OsVendorFatalError(void)
{
/*
* Let the session terminate gracely
......@@ -541,12 +538,12 @@ void OsVendorVErrorFFunction(const char *f, va_list args)
}
}
void OsVendorStartRedirectErrorFFunction()
void OsVendorStartRedirectErrorFFunction(void)
{
nxagentStartRedirectToClientsLog();
}
void OsVendorEndRedirectErrorFFunction()
void OsVendorEndRedirectErrorFFunction(void)
{
nxagentEndRedirectToClientsLog();
}
......
......@@ -1435,7 +1435,7 @@ void nxagentCheckModifierMasks(CARD8 keycode, int j)
}
void nxagentCheckRemoteKeycodes()
void nxagentCheckRemoteKeycodes(void)
{
nxagentCapsLockKeycode = XKeysymToKeycode(nxagentDisplay, XK_Caps_Lock);
nxagentNumLockKeycode = XKeysymToKeycode(nxagentDisplay, XK_Num_Lock);
......
......@@ -56,7 +56,7 @@ unsigned int nxagentPrintGeometryFlags = 0;
* the options repository to the default values.
*/
void nxagentInitOptions()
void nxagentInitOptions(void)
{
nxagentOptions.LinkType = UNDEFINED;
......@@ -183,7 +183,7 @@ void nxagentInitOptions()
* ting.
*/
void nxagentResetOptions()
void nxagentResetOptions(void)
{
if (nxagentLockDeferLevel == 0)
{
......@@ -201,12 +201,12 @@ void nxagentResetOptions()
nxagentOptions.KeycodeConversion = DEFAULT_KEYCODE_CONVERSION;
}
void nxagentSaveOptions()
void nxagentSaveOptions(void)
{
memcpy(&nxagentOptionsBackup, &nxagentOptions, sizeof(AgentOptionsRec));
}
void nxagentRestoreOptions()
void nxagentRestoreOptions(void)
{
nxagentOptions.DeferLevel = nxagentOptionsBackup.DeferLevel;
nxagentOptions.DeferTimeout = nxagentOptionsBackup.DeferTimeout;
......
......@@ -788,7 +788,7 @@ void nxagentDisconnectPixmap(void *p0, XID x1, void *p2)
}
}
Bool nxagentDisconnectAllPixmaps()
Bool nxagentDisconnectAllPixmaps(void)
{
int r = 1;
int i;
......@@ -1185,7 +1185,7 @@ Bool nxagentCheckPixmapIntegrity(PixmapPtr pPixmap)
return integrity;
}
Bool nxagentCheckAllPixmapIntegrity()
Bool nxagentCheckAllPixmapIntegrity(void)
{
int i;
Bool imageIsGood = True;
......@@ -1445,7 +1445,7 @@ FIXME: If the pixmap has a different depth from the window, the
return True;
}
Bool nxagentFbOnShadowDisplay()
Bool nxagentFbOnShadowDisplay(void)
{
static Display *shadow;
static Window win;
......@@ -1608,7 +1608,7 @@ Bool nxagentFbOnShadowDisplay()
#ifdef DEBUG
void nxagentPrintResourceTypes()
void nxagentPrintResourceTypes(void)
{
fprintf(stderr, "nxagentPrintResourceTypes: RT_PIXMAP [%lu].\n", (unsigned long) RT_PIXMAP);
fprintf(stderr, "nxagentPrintResourceTypes: RT_NX_PIXMAP [%lu].\n", (unsigned long) RT_NX_PIXMAP);
......@@ -1627,7 +1627,7 @@ void nxagentPrintResourcePredicate(void *value, XID id, XID type, void *cdata)
(void *) value, (unsigned long) id, (unsigned long) type);
}
void nxagentPrintResources()
void nxagentPrintResources(void)
{
Bool result;
int i;
......
......@@ -321,7 +321,7 @@ TODO: This should be reset only when
return 0;
}
void nxagentInitializeRecLossyLevel()
void nxagentInitializeRecLossyLevel(void)
{
*(int *)reconnectLossyLevel[DISPLAY_STEP] = 0;
*(int *)reconnectLossyLevel[SCREEN_STEP] = 0;
......@@ -805,7 +805,7 @@ static char* nxagentGetReconnectError()
return nxagentReconnectErrorMessage;
}
void nxagentHandleConnectionChanges()
void nxagentHandleConnectionChanges(void)
{
#ifdef TEST
fprintf(stderr, "nxagentHandleConnectionChanges: Called.\n");
......
......@@ -447,7 +447,7 @@ nxagentCleanGlyphs(xGlyphInfo *gi,
#endif /* #ifdef NXAGENT_RENDER_CLEANUP */
void nxagentRenderExtensionInit()
void nxagentRenderExtensionInit(void)
{
int first_event, first_error;
int major_version, minor_version;
......@@ -2303,7 +2303,7 @@ void nxagentTriFan(CARD8 op, PicturePtr pSrc, PicturePtr pDst,
#endif
}
void nxagentQueryFormats()
void nxagentQueryFormats(void)
{
XRenderInfo *xri;
XExtDisplayInfo *info = NULL;
......@@ -3006,7 +3006,7 @@ void nxagentDisconnectPicture(void * p0, XID x1, void* p2)
nxagentPicture(pPicture) = None;
}
Bool nxagentDisconnectAllPicture()
Bool nxagentDisconnectAllPicture(void)
{
int i;
Bool r;
......
......@@ -118,7 +118,7 @@ static void nxagentRemovePropertyFromList(void);
static void nxagentPrintRootlessTopLevelWindowMap(void);
void nxagentPrintRootlessTopLevelWindowMap()
void nxagentPrintRootlessTopLevelWindowMap(void)
{
int i;
......@@ -245,7 +245,7 @@ void nxagentCirculateRootlessWindows(int direction)
#ifdef DEBUG
Bool nxagentRootlessTreesMatch()
Bool nxagentRootlessTreesMatch(void)
{
Window root_return;
Window parent_return;
......@@ -1178,7 +1178,7 @@ static struct{
* Removing first element from list.
*/
void nxagentRemovePropertyFromList()
void nxagentRemovePropertyFromList(void)
{
struct nxagentPropertyRec *tmp = nxagentPropertyList.first;
......@@ -1242,7 +1242,7 @@ void nxagentAddPropertyToList(Atom property, WindowPtr pWin)
nxagentPropertyList.size++;
}
void nxagentFreePropertyList()
void nxagentFreePropertyList(void)
{
while (nxagentPropertyList.size != 0)
{
......
......@@ -367,7 +367,7 @@ FIXME: We'll check for ReparentNotify and LeaveNotify events after XReparentWind
}
}
Window nxagentCreateIconWindow()
Window nxagentCreateIconWindow(void)
{
XSetWindowAttributes attributes;
unsigned long valuemask;
......@@ -4547,7 +4547,7 @@ void nxagentShadowAdaptToRatio(void)
RegionUninit(&region);
}
void nxagentPrintGeometry()
void nxagentPrintGeometry(void)
{
int i;
......
......@@ -71,7 +71,7 @@ DrawablePtr nxagentSplitDrawable(DrawablePtr pDrawable)
}
}
void nxagentInitSplitResources()
void nxagentInitSplitResources(void)
{
int resource;
......@@ -93,7 +93,7 @@ void nxagentInitSplitResources()
}
}
SplitResourcePtr nxagentAllocSplitResource()
SplitResourcePtr nxagentAllocSplitResource(void)
{
int resource;
......@@ -193,14 +193,14 @@ void nxagentFreeSplitResource(SplitResourcePtr pResource)
pResource -> gc = NULL;
}
void nxagentInitUnpackResources()
void nxagentInitUnpackResources(void)
{
/*
FIXME: This must be implemented.
*/
}
UnpackResourcePtr nxagentAllocUnpackResource()
UnpackResourcePtr nxagentAllocUnpackResource(void)
{
/*
FIXME: This must be implemented.
......@@ -1173,7 +1173,7 @@ FIXME: Implementing the valid region policy
#endif
}
void nxagentHandleEmptySplitEvent()
void nxagentHandleEmptySplitEvent(void)
{
/*
FIXME: Should run a consistency check here.
......
......@@ -145,7 +145,7 @@ Visual *nxagentVisualFromDepth(ScreenPtr pScreen, int depth)
* of the remote display.
*/
void nxagentInitAlphaVisual()
void nxagentInitAlphaVisual(void)
{
nxagentAlphaVisual.visualid = XAllocID(nxagentDisplay);
......
......@@ -548,7 +548,7 @@ void nxagentSetVersionProperty(WindowPtr pWin)
#endif
}
Bool nxagentSomeWindowsAreMapped()
Bool nxagentSomeWindowsAreMapped(void)
{
WindowPtr pWin = screenInfo.screens[0]->root -> firstChild;
......@@ -2524,7 +2524,7 @@ void nxagentUnmapWindows(void)
NXFlushDisplay(nxagentDisplay, NXFlushLink);
}
void nxagentMapDefaultWindows()
void nxagentMapDefaultWindows(void)
{
int i;
......@@ -3930,7 +3930,7 @@ int nxagentRemoveItemBSPixmapList(unsigned long pixmapId)
return 0;
}
int nxagentEmptyBSPixmapList()
int nxagentEmptyBSPixmapList(void)
{
int i;
......
......@@ -239,7 +239,7 @@ int ZDeflate(char *dest, unsigned int *destLen, const char *source, unsigned int
return result;
}
int ZInitEncoder()
int ZInitEncoder(void)
{
if (zInitialized == 0)
{
......@@ -284,7 +284,7 @@ int ZInitEncoder()
return zInitialized;
}
int ZResetEncoder()
int ZResetEncoder(void)
{
int result;
......
......@@ -449,6 +449,9 @@ enable shadow mode
.B \-B
enable proxy binding mode
.TP 8
.B \-version
show version information and exit
.TP 8
.B \-options \fIfilename\fP
path to an options file containing nx/nx options (see below).
.PP
......
......@@ -556,7 +556,12 @@ AdjustWaitForDelay (void * waitTime, unsigned long newdelay)
void UseMsg(void)
{
#ifdef NXAGENT_SERVER
extern const char *nxagentProgName;
ErrorF("Usage: %s [<options>] [:<display>]\n\n", nxagentProgName);
#else
ErrorF("use: X [:<display>] [option]\n");
#endif
ErrorF("-a # mouse acceleration (pixels)\n");
ErrorF("-ac disable access control restrictions\n");
#ifdef MEMBUG
......
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