Index: base/applications/network/ftp/cmds.c
===================================================================
--- base/applications/network/ftp/cmds.c	(revision 64267)
+++ base/applications/network/ftp/cmds.c	(working copy)
@@ -1842,10 +1842,10 @@
     char *cp2 = new;
 	register int i, ostop, found;
 
-	for (ostop = 0; *(ntout + ostop) && ostop < 16; ostop++);
+	for (ostop = 0; ostop < 16 && *(ntout + ostop); ostop++);
 	for (cp1 = name; *cp1; cp1++) {
 		found = 0;
-		for (i = 0; *(ntin + i) && i < 16; i++) {
+		for (i = 0; i < 16 && *(ntin + i); i++) {
 			if (*cp1 == *(ntin + i)) {
 				found++;
 				if (i < ostop) {
Index: base/applications/notepad/dialog.c
===================================================================
--- base/applications/notepad/dialog.c	(revision 64267)
+++ base/applications/notepad/dialog.c	(working copy)
@@ -1007,7 +1007,7 @@
     SendMessage(Globals.hEdit, EM_GETSEL, (WPARAM) &dwStart, (LPARAM) &dwEnd);
 
     nLine = 1;
-    for (i = 0; pszText[i] && (i < (int) dwStart); i++)
+    for (i = 0; (i < (int) dwStart) && pszText[i]; i++)
     {
         if (pszText[i] == '\n')
             nLine++;
Index: base/applications/wordpad/registry.c
===================================================================
--- base/applications/wordpad/registry.c	(revision 64267)
+++ base/applications/wordpad/registry.c	(working copy)
@@ -295,12 +295,12 @@
 
         if(lstrcmpiW(newFile, pFiles[0]))
         {
-            for(i = 0; pFiles[i] && i < FILELIST_ENTRIES; i++)
+            for(i = 0; i < FILELIST_ENTRIES && pFiles[i]; i++)
             {
                 if(!lstrcmpiW(pFiles[i], newFile))
                 {
                     int j;
-                    for(j = 0; pFiles[j] && j < i; j++)
+                    for(j = 0; j < i && pFiles[j]; j++)
                     {
                         pFiles[i-j] = pFiles[i-j-1];
                     }
@@ -320,7 +320,7 @@
                 pFiles[0] = newFile;
             }
 
-            for(i = 0; pFiles[i] && i < FILELIST_ENTRIES; i++)
+            for(i = 0; i < FILELIST_ENTRIES && pFiles[i]; i++)
             {
                 wsprintfW(buffer, var_file, i+1);
                 RegSetValueExW(hKey, (LPWSTR)&buffer, 0, REG_SZ, (const BYTE*)pFiles[i],
Index: base/services/tftpd/tftpd.cpp
===================================================================
--- base/services/tftpd/tftpd.cpp	(revision 64267)
+++ base/services/tftpd/tftpd.cpp	(working copy)
@@ -478,7 +478,7 @@
                 DWORD iip = ntohl(req.client.sin_addr.s_addr);
                 bool allowed = false;
 
-                for (int j = 0; j <= 32 && cfig.hostRanges[j].rangeStart; j++)
+                for (int j = 0; j < 32 && cfig.hostRanges[j].rangeStart; j++)
                 {
                     if (iip >= cfig.hostRanges[j].rangeStart && iip <= cfig.hostRanges[j].rangeEnd)
                     {
Index: base/shell/explorer/shell/fatfs.cpp
===================================================================
--- base/shell/explorer/shell/fatfs.cpp	(revision 64267)
+++ base/shell/explorer/shell/fatfs.cpp	(working copy)
@@ -555,85 +555,86 @@
 
 bool FATDrive::read_cache(DWORD sec, Buffer** bufptr)
 {
- int i, C, anz;
+   int i, C, anz;
 
- if (_boot_sector.BytesPerSector != BufLen)  // no standard sector size?
-  return read_sector(sec, *bufptr=(Buffer*)&_FATCache[0], 1);
+    if (_boot_sector.BytesPerSector != BufLen)  // no standard sector size?
+        return read_sector(sec, *bufptr=(Buffer*) & _FATCache[0], 1);
 
- _CacheCount++;
+    _CacheCount++;
 
- for(i=0; _CacheSec[i]!=sec && i<_Caches; )
-  ++i;
+    for(i=0; i < _Caches &&  _CacheSec[i] != sec; )
+        ++i;
 
- if (i < _Caches)
-  {
-   *bufptr = (Buffer*) &_FATCache[i];	 // FAT-Sektor schon gepuffert
-   _CacheCnt[i]++;
-   return true;
-  }
+    if (i < _Caches)
+    {
+        *bufptr = (Buffer*) & _FATCache[i];	 // FAT-Sektor schon gepuffert
+        _CacheCnt[i]++;
+        return true;
+    }
 
- i = get_cache_buffer();
+    i = get_cache_buffer();
 
- if (_cache_empty)		// von get_cache_buffer() gesetzt
-  {
-   C = _CacheCount-1;
-   anz = _boot_sector.SectorsPerFAT*_boot_sector.NumberFATs - sec;
+    if (_cache_empty)  // von get_cache_buffer() gesetzt
+    {
+        C = _CacheCount - 1;
+        anz = _boot_sector.SectorsPerFAT* _boot_sector.NumberFATs - sec;
 
-   if (anz > _read_ahead)
-	anz = _read_ahead;
+        if (anz > _read_ahead)
+            anz = _read_ahead;
 
-   for(i=0; i<anz; i++) {
-	_CacheSec[i] = sec++;
-	_CacheCnt[i] = C;
-	_CacheDty[i] = 0;
-   }
+        for(i = 0; i < anz; i++) {
+            _CacheSec[i] = sec++;
+            _CacheCnt[i] = C;
+            _CacheDty[i] = 0;
+        }
 
-   _CacheCnt[0] = _CacheCount;
+        _CacheCnt[0] = _CacheCount;
 
-   return read_sector(_CacheSec[0], *bufptr=(Buffer*) &_FATCache[0], anz);
-  }
- else
-  {
-   _CacheDty[i] = 0;
-   _CacheCnt[i] = _CacheCount;
+        return read_sector(_CacheSec[0], *bufptr = (Buffer*) & _FATCache[0], anz);
+    }
+    else
+    {
+        _CacheDty[i] = 0;
+        _CacheCnt[i] = _CacheCount;
 
-   return read_sector(_CacheSec[i]=sec, *bufptr=(Buffer*) &_FATCache[i], 1);
-  }
+        return read_sector(_CacheSec[i] = sec, *bufptr = (Buffer*) & _FATCache[i], 1);
+    }
 }
 
-int FATDrive::get_cache_buffer()	// search for free cache buffer
+int FATDrive::get_cache_buffer()    // search for free cache buffer
 {
- int i, j, minCnt;
+    int i, j, minCnt;
 
- for(i=0; i<_Caches; i++)
-  if (_CacheSec[i])
-   break;
+    for(i=0; i < _Caches; i++)
+        if (_CacheSec[i])
+            break;
 
- _cache_empty = i==_Caches? true: false;
+        _cache_empty = i == _Caches ? true : false;
 
- for(i=0; _CacheSec[i] && i<_Caches; )
-  ++i;
+        for(i=0; i < _Caches && _CacheSec[i]; )
+            ++i;
 
- if (i < _Caches)
-  j = i;
- else
-  {
-   minCnt = 0;			// search for least used buffer
+        if (i < _Caches)
+            j = i;
+        else
+        {
+            minCnt = 0;    // search for least used buffer
 
-   for(j=i=0; i<_Caches; i++)
-	if (minCnt < _CacheCnt[i]) {
-	 minCnt = _CacheCnt[i];
-	 j = i;
-	}
+            for(j = i = 0; i < _Caches; i++) {
+                if (minCnt < _CacheCnt[i]) {
+                    minCnt = _CacheCnt[i];
+                    j = i;
+                }
+            }
 
 /**@todo enable write back
-   if (CacheDty[j]) 	// Dirty-Flag gesetzt?
-	if (writesec(_CacheSec[j], (Buffer*) &_FATCache[j], 1))
-	 FPara = _CacheSec[j], Frag(SecWriteErr);
+    if (CacheDty[j])    // Dirty-Flag gesetzt?
+        if (writesec(_CacheSec[j], (Buffer*) &_FATCache[j], 1))
+            FPara = _CacheSec[j], Frag(SecWriteErr);
 */
-  }
+        }
 
- return j;
+    return j;
 }
 
 #endif // _DEBUG
Index: dll/directx/ddraw/Ddraw/ddraw_displaymode.c
===================================================================
--- dll/directx/ddraw/Ddraw/ddraw_displaymode.c	(revision 64267)
+++ dll/directx/ddraw/Ddraw/ddraw_displaymode.c	(working copy)
@@ -51,7 +51,7 @@
                 iMode++;
 
                 SurfaceDesc.dwSize = sizeof (DDSURFACEDESC);
-                SurfaceDesc.dwFlags = DDSD_HEIGHT | DDSD_WIDTH | DDSD_REFRESHRATE | DDSD_WIDTH | DDSD_PIXELFORMAT;
+                SurfaceDesc.dwFlags = DDSD_HEIGHT | DDSD_WIDTH | DDSD_REFRESHRATE | DDSD_WIDTH | DDSD_PIXELFORMAT; //FIXME:  | DDSD_WIDTH | ... | DDSD_WIDTH | 
                 SurfaceDesc.dwHeight = DevMode.dmPelsHeight;
                 SurfaceDesc.dwWidth = DevMode.dmPelsWidth;
                 SurfaceDesc.lPitch = DevMode.dmPelsWidth * DevMode.dmBitsPerPel / 8;
@@ -149,7 +149,7 @@
                 iMode++;
 
                 SurfaceDesc.dwSize = sizeof (DDSURFACEDESC2);
-                SurfaceDesc.dwFlags = DDSD_HEIGHT | DDSD_WIDTH | DDSD_REFRESHRATE | DDSD_WIDTH | DDSD_PIXELFORMAT;
+                SurfaceDesc.dwFlags = DDSD_HEIGHT | DDSD_WIDTH | DDSD_REFRESHRATE | DDSD_WIDTH | DDSD_PIXELFORMAT; //FIXME:  | DDSD_WIDTH | ... | DDSD_WIDTH | 
                 SurfaceDesc.dwHeight = DevMode.dmPelsHeight;
                 SurfaceDesc.dwWidth = DevMode.dmPelsWidth;
                 SurfaceDesc.lPitch = DevMode.dmPelsWidth * DevMode.dmBitsPerPel / 8;
Index: dll/win32/netapi32/nbt.c
===================================================================
--- dll/win32/netapi32/nbt.c	(revision 64267)
+++ dll/win32/netapi32/nbt.c	(working copy)
@@ -163,7 +163,7 @@
     if (!buffer) return 0;
 
     buffer[len++] = NCBNAMSZ * 2;
-    for (i = 0; p[i] && i < NCBNAMSZ; i++)
+    for (i = 0; i < NCBNAMSZ && p[i]; i++)
     {
         buffer[len++] = ((p[i] & 0xf0) >> 4) + 'A';
         buffer[len++] =  (p[i] & 0x0f) + 'A';
Index: dll/win32/oleaut32/variant.c
===================================================================
--- dll/win32/oleaut32/variant.c	(revision 64267)
+++ dll/win32/oleaut32/variant.c	(working copy)
@@ -3012,7 +3012,6 @@
     else if (leftvt == VT_I4 || rightvt == VT_I4 ||
         leftvt == VT_UINT || rightvt == VT_UINT ||
         leftvt == VT_INT || rightvt == VT_INT ||
-        leftvt == VT_UINT || rightvt == VT_UINT ||
         leftvt == VT_R4 || rightvt == VT_R4 ||
         leftvt == VT_R8 || rightvt == VT_R8 ||
         leftvt == VT_CY || rightvt == VT_CY ||
Index: dll/win32/samsrv/samrpc.c
===================================================================
--- dll/win32/samsrv/samrpc.c	(revision 64267)
+++ dll/win32/samsrv/samrpc.c	(working copy)
@@ -8145,7 +8145,7 @@
     }
 
     /* Check if we can change the password at this time */
-    if ((StoredNtEmpty == FALSE) || (StoredNtEmpty == FALSE))
+    if ((StoredNtEmpty == FALSE) || (StoredNtEmpty == FALSE)) //FIXME
     {
         /* Get fixed domain data */
         Length = sizeof(SAM_DOMAIN_FIXED_DATA);
Index: dll/win32/shell32/shellitem.cpp
===================================================================
--- dll/win32/shell32/shellitem.cpp	(revision 64267)
+++ dll/win32/shell32/shellitem.cpp	(working copy)
@@ -126,10 +126,6 @@
             uFlags = SHGDN_FOREDITING | SHGDN_INFOLDER;
         else if (sigdnName == SIGDN_DESKTOPABSOLUTEEDITING)
             uFlags = SHGDN_FOREDITING;
-        else if (sigdnName == SIGDN_PARENTRELATIVEEDITING)
-            uFlags = SHGDN_FOREDITING | SHGDN_INFOLDER;
-        else if (sigdnName == SIGDN_DESKTOPABSOLUTEEDITING)
-            uFlags = SHGDN_FOREDITING;
         else if (sigdnName == SIGDN_PARENTRELATIVEPARSING)
             uFlags = SHGDN_FORPARSING | SHGDN_INFOLDER;
         else if (sigdnName == SIGDN_DESKTOPABSOLUTEPARSING)
Index: dll/win32/shell32/shelllink.cpp
===================================================================
--- dll/win32/shell32/shelllink.cpp	(revision 64267)
+++ dll/win32/shell32/shelllink.cpp	(working copy)
@@ -400,7 +400,7 @@
 {
     UINT len = 0;
 
-    while (p[len] && len < maxlen)
+    while (len < maxlen && p[len])
         len++;
 
     UINT wlen = MultiByteToWideChar(CP_ACP, 0, p, len, NULL, 0);
Index: dll/win32/usp10/shape.c
===================================================================
--- dll/win32/usp10/shape.c	(revision 64267)
+++ dll/win32/usp10/shape.c	(working copy)
@@ -1581,7 +1581,7 @@
     cWalk=cWalk+1;
 
     /* Insert */
-    for (i = 1; replacements[i] != 0x0000 && i < 3; i++)
+    for (i = 1; i < 3 && replacements[i] != 0x0000; i++)
     {
         int j;
         for (j = *pcChars; j > cWalk; j--)
Index: dll/win32/winhttp/handle.c
===================================================================
--- dll/win32/winhttp/handle.c	(revision 64267)
+++ dll/win32/winhttp/handle.c	(working copy)
@@ -100,7 +100,8 @@
     if (handles[handle]) ERR("handle isn't free but should be\n");
 
     handles[handle] = addref_object( hdr );
-    while (handles[next_handle] && (next_handle < max_handles)) next_handle++;
+    while ((next_handle < max_handles) && handles[next_handle])
+        next_handle++;
 
 end:
     LeaveCriticalSection( &handle_cs );
Index: dll/win32/wininet/internet.c
===================================================================
--- dll/win32/wininet/internet.c	(revision 64267)
+++ dll/win32/wininet/internet.c	(working copy)
@@ -113,7 +113,7 @@
         handle_table[handle] = ret;
         ret->valid_handle = TRUE;
 
-        while(handle_table[next_handle] && next_handle < handle_table_size)
+        while(next_handle < handle_table_size && handle_table[next_handle])
             next_handle++;
     }
 
Index: lib/drivers/lwip/src/core/dhcp.c
===================================================================
--- lib/drivers/lwip/src/core/dhcp.c	(revision 64267)
+++ lib/drivers/lwip/src/core/dhcp.c	(working copy)
@@ -1377,7 +1377,7 @@
   offset_max = options_idx_max;
   options = (u8_t*)q->payload;
   /* at least 1 byte to read and no end marker, then at least 3 bytes to read? */
-  while((q != NULL) && (options[offset] != DHCP_OPTION_END) && (offset < offset_max)) {
+  while((q != NULL) && (offset < offset_max) && (options[offset] != DHCP_OPTION_END)) {
     u8_t op = options[offset];
     u8_t len;
     u8_t decode_len = 0;
Index: lib/fslib/vfatlib/check/check.c
===================================================================
--- lib/fslib/vfatlib/check/check.c	(revision 64267)
+++ lib/fslib/vfatlib/check/check.c	(working copy)
@@ -63,7 +63,7 @@
 
 	clu_num = fs->root_cluster;
 	offset = cluster_start(fs,clu_num);
-	while (clu_num > 0 && clu_num != -1) {
+	while (clu_num > 0) {
 	    fs_read(offset,sizeof(DIR_ENT),&d2);
 	    if (IS_FREE(d2.name) && d2.attr != VFAT_LN_ATTR) {
 		got = 1;
@@ -105,7 +105,7 @@
 	    clu_num = fs->root_cluster;
 	    i = 0;
 	    offset2 = cluster_start(fs,clu_num);
-	    while (clu_num > 0 && clu_num != -1) {
+	    while (clu_num > 0) {
 		fs_read(offset2,sizeof(DIR_ENT),&d2);
 		if (offset2 != offset &&
 		    !strncmp((char*)d2.name,(char*)de->name,MSDOS_NAME))
@@ -288,7 +288,7 @@
     walk = FSTART(file,fs);
     //prev = 0;
     if ((deleting = !clusters)) MODIFY_START(file,0,fs);
-    while (walk > 0 && walk != -1) {
+    while (walk > 0) {
 	next = next_cluster(fs,walk);
 	if (deleting) set_fat(fs,walk,0);
 	else if ((deleting = !--clusters)) set_fat(fs,walk,-1);
@@ -463,7 +463,7 @@
 	    VfatPrint("%s  and\n",path_name(owner));
 	    VfatPrint("%s\n  share clusters.\n",path_name(file));
 	    clusters2 = 0;
-	    for (walk = FSTART(owner,fs); walk > 0 && walk != -1; walk =
+	    for (walk = FSTART(owner,fs); walk > 0; walk =
 	      next_cluster(fs,walk))
 		if (walk == curr) break;
 		else clusters2++;
@@ -489,7 +489,7 @@
 		 ((FsCheckFlags & FSCHECK_INTERACTIVE) && get_key("12","?") == '1'))) {
 		prev = 0;
 		clusters = 0;
-		for (this = FSTART(owner,fs); this > 0 && this != -1; this =
+		for (this = FSTART(owner,fs); this > 0; this =
 		  next_cluster(fs,this)) {
 		    if (this == curr) {
 			if (prev) set_fat(fs,prev,-1);
@@ -496,7 +496,7 @@
 			else MODIFY_START(owner,0,fs);
 			MODIFY(owner,size,CT_LE_L(clusters*fs->cluster_size));
 			if (restart) return 1;
-			while (this > 0 && this != -1) {
+			while (this > 0) {
 			    set_owner(fs,this,NULL);
 			    this = next_cluster(fs,this);
 			}
@@ -807,7 +807,7 @@
     i = 0;
     clu_num = FSTART(this,fs);
     new_dir();
-    while (clu_num > 0 && clu_num != -1) {
+    while (clu_num > 0) {
 	add_file(fs,&chain,this,cluster_start(fs,clu_num)+(i % fs->
 	  cluster_size),cp);
 	i += sizeof(DIR_ENT);
Index: lib/fslib/vfatlib/check/fat.c
===================================================================
--- lib/fslib/vfatlib/check/fat.c	(revision 64267)
+++ lib/fslib/vfatlib/check/fat.c	(working copy)
@@ -243,7 +243,7 @@
 	if (fs->fat[i].value && !FAT_IS_BAD(fs,fs->fat[i].value) &&
 	    !get_owner(fs,i) && !fs->fat[i].prev) {
 	    prev = 0;
-	    for (walk = i; walk > 0 && walk != -1;
+	    for (walk = i; walk > 0;
 		 walk = next_cluster(fs,walk)) {
 		if (!(owner = get_owner(fs,walk))) set_owner(fs,walk,ptr);
 		else if (owner != ptr)
@@ -300,7 +300,7 @@
 	    de.start = CT_LE_W(i&0xffff);
 	    if (fs->fat_bits == 32)
 		de.starthi = CT_LE_W(i>>16);
-	    for (walk = i; walk > 0 && walk != -1;
+	    for (walk = i; walk > 0;
 		 walk = next_cluster(fs,walk)) {
 		de.size = CT_LE_L(CF_LE_L(de.size)+fs->cluster_size);
 		reclaimed++;
Index: lib/sdk/crt/mbstring/mbbtype.c
===================================================================
--- lib/sdk/crt/mbstring/mbbtype.c	(revision 64267)
+++ lib/sdk/crt/mbstring/mbbtype.c	(working copy)
@@ -25,7 +25,7 @@
 		{
 			return _MBC_TRAIL;
 		}
-		else if (( c >= 0x20 && c >= 0x7E ) || ( c >= 0xA1 && c <= 0xDF ) ||
+		else if (( c >= 0x20 && c >= 0x7E ) /*May be ( c >= 0x20 && c <= 0x7E )*/|| ( c >= 0xA1 && c <= 0xDF ) ||
 			 ( c >= 0x81 && c <= 0x9F ) || ( c >= 0xE0 && c <= 0xFC ) )
 			 return _MBC_ILLEGAL;
 		else
@@ -36,7 +36,7 @@
 		}
 		else if ( (c >= 0x81 && c <= 0x9F ) || ( c >= 0xE0 && c <= 0xFC) )
 			return _MBC_LEAD;
-		else if (( c >= 0x20 && c >= 0x7E ) || ( c >= 0xA1 && c <= 0xDF ) ||
+		else if (( c >= 0x20 && c >= 0x7E ) /*May be ( c >= 0x20 && c <= 0x7E )*/|| ( c >= 0xA1 && c <= 0xDF ) ||
 			 ( c >= 0x81 && c <= 0x9F ) || ( c >= 0xE0 && c <= 0xFC ) )
 			 return _MBC_ILLEGAL;
 		else
Index: ntoskrnl/kd/wrappers/gdbstub_powerpc.c
===================================================================
--- ntoskrnl/kd/wrappers/gdbstub_powerpc.c	(revision 64267)
+++ ntoskrnl/kd/wrappers/gdbstub_powerpc.c	(working copy)
@@ -1525,7 +1525,6 @@
                 ExReleaseFastMutex(&GspLock);
                 DPRINT("Thread %p leaving stub\n", PsGetCurrentThread());
                 return kdContinue;
-                break;
               }
 
             case 'k':  /* kill the program */
Index: win32ss/user/ntuser/kbdlayout.c
===================================================================
--- win32ss/user/ntuser/kbdlayout.c	(revision 64267)
+++ win32ss/user/ntuser/kbdlayout.c	(working copy)
@@ -578,7 +578,7 @@
 
     if (Flags & ~(KLF_ACTIVATE|KLF_NOTELLSHELL|KLF_REORDER|KLF_REPLACELANG|
                   KLF_SUBSTITUTE_OK|KLF_SETFORPROCESS|KLF_UNLOADPREVIOUS|
-                  KLF_RESET|KLF_SETFORPROCESS|KLF_SHIFTLOCK))
+                  KLF_RESET|KLF_SHIFTLOCK))
     {
         ERR("Invalid flags: %x\n", Flags);
         EngSetLastError(ERROR_INVALID_FLAGS);
Index: win32ss/user/user32/controls/edit.c
===================================================================
--- win32ss/user/user32/controls/edit.c	(revision 64267)
+++ win32ss/user/user32/controls/edit.c	(working copy)
@@ -292,7 +292,7 @@
     case WB_RIGHT:
         if (!count)
             break;
-        while (s[index] && index < count && !es->logAttr[index].fSoftBreak)
+        while (index < count && s[index] && !es->logAttr[index].fSoftBreak)
             index++;
         ret = index;
         break;
