mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-28 07:58:08 +01:00
fix crash on 64-bit system
This commit is contained in:
parent
29d5cc5d13
commit
12932bf788
1 changed files with 3 additions and 3 deletions
|
@ -1313,12 +1313,12 @@ gtkDrawCtxtMake( GtkWidget* drawing_area, GtkGameGlobals* globals )
|
||||||
GtkDrawCtx* dctx = g_malloc0( sizeof(GtkDrawCtx) );
|
GtkDrawCtx* dctx = g_malloc0( sizeof(GtkDrawCtx) );
|
||||||
GdkColormap* map;
|
GdkColormap* map;
|
||||||
|
|
||||||
short i;
|
short ii;
|
||||||
|
|
||||||
dctx->vtable = g_malloc( sizeof(*(((GtkDrawCtx*)dctx)->vtable)) );
|
dctx->vtable = g_malloc( sizeof(*(((GtkDrawCtx*)dctx)->vtable)) );
|
||||||
|
|
||||||
for ( i = 0; i < sizeof(*dctx->vtable)/4; ++i ) {
|
for ( ii = 0; ii < VSIZE(dctx->vtable); ++ii ) {
|
||||||
((void**)(dctx->vtable))[i] = draw_doNothing;
|
((void**)(dctx->vtable))[ii] = draw_doNothing; /* bad? */
|
||||||
}
|
}
|
||||||
|
|
||||||
SET_VTABLE_ENTRY( dctx->vtable, draw_clearRect, gtk );
|
SET_VTABLE_ENTRY( dctx->vtable, draw_clearRect, gtk );
|
||||||
|
|
Loading…
Add table
Reference in a new issue