Exemplo n.º 1
0
 protected override bool ReleaseHandle()
 {
     SafeTemporaryKeychainHandle.UntrackItem(handle);
     Interop.CoreFoundation.CFRelease(handle);
     SetHandle(IntPtr.Zero);
     return(true);
 }
Exemplo n.º 2
0
        internal static void TrackKeychain(SafeTemporaryKeychainHandle toTrack)
        {
            if (toTrack.IsInvalid)
            {
                return;
            }

            lock (s_lookup)
            {
                Debug.Assert(!s_lookup.ContainsKey(toTrack.handle));

                s_lookup[toTrack.handle] = toTrack;
            }
        }