[EMAIL PROTECTED] (Christoph Egger) writes:
> On 17 Nov 2000, Marcus Sundberg wrote:
> > > diff -uNr 20001115/degas/lib/libggi/extensions/misc/display/X/init.c
>degas/lib/libggi/extensions/misc/display/X/init.c
> > > --- 20001115/degas/lib/libggi/extensions/misc/display/X/init.c Tue Apr 25
>07:07:28 2000
> > > +++ degas/lib/libggi/extensions/misc/display/X/init.c Fri Nov 17 13:35:06
>2000
> > > @@ -62,7 +62,7 @@
> > >
> > > me->setsplitline = GGI_x_setsplitline;
> > >
> > > - *dlret = GGI_DL_EXTENSION;
> > > + *dlret = GGI_DL_OPDISPLAY;
> > > return 0;
> > > }
> >
> > No, where did you get this idea?
>
> On Tue, 7 Nov 2000, Jon M. Taylor wrote to me in a PM:
> -------------------------------------------------------------------------
> > I hacked libxmi since two days.
> > The demos runs without segfaults.
>
> MUCH better! I too got it to run without segfaults, and the X
> target code looks OK. Nice job!
At a quick glance the code looks completely bogus, I'll have a look at
it this weekend. The extension-segfault problems are the major reason
why I said the extension system should be re-designed a while ago.
[snip]
> > I did the hack in the X-target as you said.
> > The XMI_X_getapi() is called, but not the XMI_X_setmode() one.
> > I don't know why. Maybe I got you wrong in some aspects you gave?
> >
> > Patch is attached. Please have a look at it and give me feedback.
>
> The problem is that your GGIopen() function is returning
> GGI_DL_EXTENSION, when it should be returning GGI_DL_OPDISPLAY. This
> return type tells GGI what type of library it is, so it knows what actions
> to take. The X-target is a display target, not an extension.
Extension sublibs are are always extensionsublibs and should return
GGI_DL_EXTENSION. If they change any pointers in vis->opdisplay
they should *also* return GGI_DL_OPDISPLAY. Note that the return is
a mask.
> -------------------------------------------------------------------------
>
>
> > GGI_DL_EXTENSION is correct.
>
> In the misc extension or in the libedemo?
Both, as neither touch anything in vis->opdisplay.
//Marcus
--
-------------------------------+------------------------------------
Marcus Sundberg | http://www.stacken.kth.se/~mackan
Royal Institute of Technology | Phone: +46 707 452062
Stockholm, Sweden | E-Mail: [EMAIL PROTECTED]