[gtk-vnc-devel] [PATCH 1/4] Use WIN32 instead of __MINGW32__



It's bad practice to use #if{,n}def __MINGW32__ sections unless the
code really is MinGW-specific. (ie. Pretty unlikely).

In fact, this code is Win32-specific, so use #if{,n}def WIN32 instead.

Rich.

-- 
Richard Jones, Emerging Technologies, Red Hat  http://et.redhat.com/~rjones
virt-top is 'top' for virtual machines.  Tiny program with many
powerful monitoring features, net stats, disk stats, logging, etc.
http://et.redhat.com/~rjones/virt-top
diff -r 47135c91cd9c src/vncdisplay.c
--- a/src/vncdisplay.c	Thu Oct 09 11:23:09 2008 -0400
+++ b/src/vncdisplay.c	Wed Oct 29 14:52:28 2008 +0000
@@ -1892,7 +1903,7 @@
 {
 	char file[PATH_MAX];
 	char sysdir[PATH_MAX];
-#ifndef __MINGW32__
+#ifndef WIN32
 	char userdir[PATH_MAX];
 	struct passwd *pw;
 	char *dirs[] = { sysdir, userdir };
@@ -1903,7 +1914,7 @@
 	strncpy(sysdir, SYSCONFDIR "/pki", PATH_MAX-1);
 	sysdir[PATH_MAX-1] = '\0';
 
-#ifndef __MINGW32__
+#ifndef WIN32
 	if (!(pw = getpwuid(getuid())))
 		return TRUE;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]