Revision: 13898
http://sourceforge.net/p/skim-app/code/13898
Author: hofman
Date: 2023-12-12 16:38:52 +0000 (Tue, 12 Dec 2023)
Log Message:
-----------
use CFHash to get hash of CFString
Modified Paths:
--------------
trunk/NSPointerFunctions_SKExtensions.m
Modified: trunk/NSPointerFunctions_SKExtensions.m
===================================================================
--- trunk/NSPointerFunctions_SKExtensions.m 2023-12-12 16:02:32 UTC (rev
13897)
+++ trunk/NSPointerFunctions_SKExtensions.m 2023-12-12 16:38:52 UTC (rev
13898)
@@ -74,7 +74,7 @@
// If we create the string with external characters,
CFStringGetCharactersPtr is guaranteed to succeed; since we're going to call
CFStringGetCharacters anyway in fastHash if CFStringGetCharactsPtr fails, let's
do it now when we lowercase the string
CFMutableStringRef mutableString =
CFStringCreateMutableWithExternalCharactersNoCopy(allocator, buffer, len, len +
10, (buffer != stackBuffer ? allocator : kCFAllocatorNull));
CFStringLowercase(mutableString, NULL);
- hash = [(id)mutableString hash];
+ hash = CFHash(mutableString);//[(id)mutableString hash];
// if we used the allocator, this should free the buffer for us
CFRelease(mutableString);
return hash;
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit