diff src/win_gaim.c @ 11469:d83e1fe99d69

[gaim-migrate @ 13709] Patch from Steve L?posi so that the version information is displayed if the -v flag is specified and so the single instance stuff doesn't kick in when -v or -h is specified. committer: Tailor Script <tailor@pidgin.im>
author Daniel Atallah <daniel.atallah@gmail.com>
date Fri, 09 Sep 2005 00:24:22 +0000
parents 9f6df41df587
children 4da9e0d4e8d2
line wrap: on
line diff
--- a/src/win_gaim.c	Thu Sep 08 22:22:39 2005 +0000
+++ b/src/win_gaim.c	Fri Sep 09 00:24:22 2005 +0000
@@ -333,8 +333,8 @@
         char gaimdir[MAX_PATH];
         HMODULE hmod;
 
-	/* If debug or help flag used, create console for output */
-	if (strstr(lpszCmdLine, "-d") || strstr(lpszCmdLine, "-h")) {
+	/* If debug or help or version flag used, create console for output */
+	if (strstr(lpszCmdLine, "-d") || strstr(lpszCmdLine, "-h") || strstr(lpszCmdLine, "-v")) {
 		LPFNATTACHCONSOLE MyAttachConsole = NULL;
 		if ((hmod = GetModuleHandle("kernel32.dll"))) {
 			MyAttachConsole =
@@ -371,8 +371,10 @@
                 dll_prep();
 
 	wgaim_set_locale();
-	if(!getenv("GAIM_MULTI_INST") && !wgaim_set_running())
-		return 0;
+	/* If help or version flag used, do not check Mutex */
+	if(!strstr(lpszCmdLine, "-h") && !strstr(lpszCmdLine, "-v"))
+		if(!getenv("GAIM_MULTI_INST") && !wgaim_set_running())
+			return 0;
 
 	wgaim_set_proxy();