- Timestamp:
- Apr 8, 2000, 10:09:42 PM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/KERNEL32.CPP
r2802 r3352 1 /* $Id: KERNEL32.CPP,v 1.4 2 2000-02-16 14:25:29sandervl Exp $ */1 /* $Id: KERNEL32.CPP,v 1.43 2000-04-08 20:09:42 sandervl Exp $ */ 2 2 3 3 /* … … 418 418 char *string1 = (char *)lpString1, *string2 = (char *)lpString2; 419 419 420 SetLastError(0); 421 420 422 #ifdef DEBUG 421 423 if(fdwStyle & SORT_STRINGSORT) … … 426 428 dprintf(("KERNEL32: NORM_IGNORESYMBOLS not supported!\n")); 427 429 #endif 430 431 if(lpString1 == NULL || lpString2 == NULL) 432 { 433 dprintf(("CompareStringA: (s1=%s,s2=%s): Invalid NULL string\n", lpString1, lpString2)); 434 SetLastError(ERROR_INVALID_PARAMETER); 435 return 0; 436 } 428 437 429 438 if(cch1 == -1) cch1 = strlen(string1); … … 463 472 int i; 464 473 int fEqual = TRUE; 465 char *string1 = UnicodeToAsciiString((LPWSTR)lpString1); 466 char *string2 = UnicodeToAsciiString((LPWSTR)lpString2); 467 468 dprintf2(("KERNEL32: OS2CompareStringW '%s' - '%s'\n", string1, string2)); 469 470 fEqual = CompareStringA(lcid, fdwStyle, string1, cch1, string2, cch2); 471 FreeAsciiString(string1); 472 FreeAsciiString(string2); 473 474 return(fEqual); 474 char *string1; 475 char *string2; 476 477 dprintf2(("KERNEL32: OS2CompareStringW '%s' - '%s'\n", string1, string2)); 478 479 if(lpString1 == NULL || lpString2 == NULL) 480 { 481 dprintf(("CompareStringW: (s1=%s,s2=%s): Invalid NULL string\n", lpString1, lpString2)); 482 SetLastError(ERROR_INVALID_PARAMETER); 483 return 0; 484 } 485 486 if(cch1 == -1) cch1 = lstrlenW(lpString1); 487 if(cch2 == -1) cch2 = lstrlenW(lpString2); 488 489 string1 = UnicodeToAsciiStringN((LPWSTR)lpString1, cch1); 490 string2 = UnicodeToAsciiStringN((LPWSTR)lpString2, cch2); 491 492 fEqual = CompareStringA(lcid, fdwStyle, string1, cch1, string2, cch2); 493 FreeAsciiString(string1); 494 FreeAsciiString(string2); 495 496 return(fEqual); 475 497 } 476 498 //******************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.