On Jul 22, 2008, at 1:41 PM, Glynn Clements wrote:


Michael Barton wrote:

togl and togl->aglCtx are known to be non-NULL (otherwise it would
have crashed before then). Can you try the following:

        print ((MacDrawable *) (window))
        print ((MacDrawable *) (window))->toplevel
        print ((MacDrawable *) (window))->toplevel->grafPtr

I'm assuming that you mean to enter these lines in gdb. Here is the
result.

(gdb) print ((MacDrawable *) (window))
No symbol "MacDrawable" in current context.

Hmm; does this work:

        print ((struct TkWindowPrivate *) (window))
        print ((struct TkWindowPrivate *) (window))->toplevel
        print ((struct TkWindowPrivate *) (window))->toplevel->grafPtr
?

Failing that, just:

        print window

might provide a clue.

OTOH, I'm not sure if any of this will actually help in the end. The
conclusion may well just be "Togl doesn't work with 8.5". I can't see
any references to 8.5 on the Togl site (it isn't a particularly active
project).

This actually produced some results.

(gdb) run -f $GISBASE/etc/nviz2.2/scripts/nviz2.2_script -q
Starting program: /Applications/Grass/GRASS-7.0.app/Contents/MacOS/etc/ nviz2.2/nviz -f $GISBASE/etc/nviz2.2/scripts/nviz2.2_script -q Reading symbols for shared libraries ++++++++++++++++++++++ + ...................................................................................... done
Reading symbols for shared libraries . done
Reading symbols for shared libraries ....... done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x0000002c
0x0001702d in Togl_CreateWindow (tkwin=0x1fcb608, parent=30918536, instanceData=0x757ce0) at togl.c:2338
2338            if (!aglSetDrawable(togl->aglCtx,
(gdb) print ((struct TkWindowPrivate *) (window))
$1 = (struct TkWindowPrivate *) 0x1d7c648
(gdb) print ((struct TkWindowPrivate *) (window))->toplevel
$2 = (struct TkWindowPrivate *) 0x28
(gdb) print ((struct TkWindowPrivate *) (window))->toplevel->grafPtr
Cannot access memory at address 0x2c
(gdb) print window
$3 = 30918216
(gdb)

Michael

_______________________________________________
grass-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/grass-dev

Reply via email to