RE: [Gtk1-win-developers] Progress - decloaked GDK pointers
Brought to you by:
robinrowe
From: Donald M. <do...@dr...> - 2004-03-17 12:50:06
|
Do you have a patch for these changes/bug-fixes? Donald. > -----Original Message----- > From: gtk...@li... > [mailto:gtk...@li...] On > Behalf Of Robin Rowe > Sent: 04 March 2004 07:03 > To: gtk...@li... > Subject: [Gtk1-win-developers] Progress - decloaked GDK pointers > > Hi. Hadn't found time to touch GTK1 for a couple months. Been > busy on other > things. > > My attempt to use GDK2 with GTK1 didn't work out. Am back > working on GDK1. > That has serious problems with releasing HDC handles with > live resources in > them, causing random crashes inside Windows. Same problem > we've known about > since last year. That GDK by design casts objects all over > the place defeats > debugging. This pointer cloaking had me a bit discouraged. > > Changed GTK1 this week to have all the by-design GTK pointer > cloaking turned > off so I can see clearly now what is going on. What that means is that > GdkWhatever, GdkWhateverPrivate, and GdkWhateverPrivateWin32 > are all the > same struct type now. In making that change I discovered one > place where an > up-cast was converting to a type larger than had been > allocated in memory. > One bug fixed. > > Testing with HelloGtk, my new decloaked GDK1 immediately > hurled on g_free, > which puzzled me a bit. Rewrote the basic g_... glib memory > handlers to > streamline them, but it still crashed. Then I realized that > for Windows apps > and dlls there are separate heaps, that you have to keep > malloc/free calls > symmetric to the caller's address space. In other words, no > calling local > free on a pointer malloc-ed inside a dll. Inadvertently, a > header file macro > was doing that. Making all g_... memory functions exported > dll functions > fixed it. > > Am encouraged that I seem to be back on the right track and > can see what's > going on while crawling around in the VC++ debugger and > BoundsChecker. Looks > like quite a few repairs ahead, but making progress. > > After the GTK1 HDC bugs are fixed I would like to work on > tablet support and > a new macro recorder feature. Been wanting to work on both of > those a long > time. > > Cheers, > > Robin > ------------------------------------------------------------------- > Rob...@Mo... Hollywood, California > www.CinePaint.org Open source digital motion picture film software > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: IBM Linux Tutorials > Free Linux tutorial presented by Daniel Robbins, President and CEO of > GenToo technologies. Learn everything from fundamentals to system > administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click > _______________________________________________ > Gtk1-win-developers mailing list > Gtk...@li... > https://lists.sourceforge.net/lists/listinfo/gtk1-win-developers > |