Saturday, October 25, 2003

Managed code gotcha's... 


.NET Framework Security: Using Win32 and Other Libraries (Working with C#)

Just learned a little lesson when working with managed code and P/Invoke. If you are providing a delegate as a callback to a P/Invoke'd Windows API function, make absolutely sure you hold a reference to that delegate for as long as that Windows API needs to call it... ;-) Since the CLR doesn't track references to things that travel off into the unmanaged nether-world, it will blithely garbage collect your delegate. This promptly hangs your unsuspecting API out to dry (think RegisterClass and CreateWindowEx). The absolutely insidious thing about all this is that it will work.. for a while. So take my advice, the oven is hot; wear your oven mitts...

For all the time I've spent working with managed code, COM-interop, and P/Invoke, you'd think I'd know this stuff... But then again, I'm no Don Box, ChrisAn, or Lutz Roeder, et. al.... they've had the luxury of being exposed to this for a few more years ;-) Eventually, this stuff will seep through the several inches of solid rock and touch some grey-matter someplace...
0 comments

Friday, October 24, 2003

Ryan Dawson on Longhorn (in hot water...) 


Ryan Dawson on Longhorn

Whoops... somebody raised a few eyebrows at MS ;-)... Ryan's previous post has been expunged and he doesn't even work for MS. I still have a cached copy though.

0 comments

Thursday, October 23, 2003

Ryan Dawson on Longhorn 


Ryan Dawson on Longhorn

All I can say is... wow... So, Ryan, who peed in your Wheaties? The thing is I agree with a lot of what he said, but you can catch more flies with honey than vinegar.

0 comments

BorCon prep 


Yes, it's been a few days since my last entry.. well I've been up to my eyeballs trying to complete some deliveries. We have got to have a reasonably stable build of stuff available for all those demos at this years' BorCon. This also has to be done before I can begin to prepare for my talks, which is going to be like cramming the night before a test.

I did get my final schedule for my talks. The info is here.



0 comments

Disclaimer:
The opinions expressed here are mine. They should in no way be construed as being the opinion of my employer, Borland Software Corp. If you actually think that my opinions are a reflection of Borland, then I have a bridge I can sell you.

Subscribe to my RSS feed.

This page is powered by Blogger. Isn't yours?