It seems like a bug in the way the Process Manager or whatever (CPS)
packs the PSN into the CFDictionary.
Since it seems like a bug or oversight to me, I'd get the pid from
the CFDictionary and call GetProcessForPID() to get the PSN.
And of course, there are better ways to get the current PSN. Like
GetProcessForPID(0) or GetCurrentProcess() unless I am missing
something.
Ack, at 3/14/07, Sean McBride said:
>It seems to me that the real problem is that the NSDictionary stores
the PSN as a UInt64 instead of as a pair of UInt32s.
I guess. Or that the dictionary is storing it as a big endian UInt64
instead of native endianness. So I suppose the solution is to use
CFSwapInt64BigToHost() like so:
unsigned long long temp =
[[currDict objectForKey:@"PSN"] unsignedLongLongValue];
temp = CFSwapInt64BigToHost (temp); // NEW
Does that seem best?
--
Sincerely,
Rosyna Keller
Technical Support/Carbon troll/Always needs a hug
Unsanity: Unsane Tools for Insanely Great People
It's either this, or imagining Phil Schiller in a thong.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden