Skip to content

Commit 290e5bd

Browse files
committed
Modified Tcl procedure registration and command prototype to work around
changes to the command prototype between Tcl8.3 and Tcl8.4. svn path=/trunk/matplotlib/; revision=196
1 parent fbd1a0c commit 290e5bd

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

src/_tkagg.cpp

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,9 @@ typedef struct {
2828
Tcl_Interp* interp;
2929
} TkappObject;
3030

31-
// const on win32
32-
#ifdef WIN32
33-
#define argv_t const char
34-
#else
35-
#define argv_t char
36-
#endif
3731
static int
3832
PyAggImagePhoto(ClientData clientdata, Tcl_Interp* interp,
39-
int argc, argv_t **argv)
33+
int argc, char **argv)
4034
{
4135
Tk_PhotoHandle photo;
4236
Tk_PhotoImageBlock block;
@@ -130,7 +124,8 @@ _tkinit(PyObject* self, PyObject* args)
130124

131125
/* This will bomb if interp is invalid... */
132126

133-
Tcl_CreateCommand(interp, "PyAggImagePhoto", PyAggImagePhoto,
127+
Tcl_CreateCommand(interp, "PyAggImagePhoto",
128+
(Tcl_CmdProc *) PyAggImagePhoto,
134129
(ClientData) 0, (Tcl_CmdDeleteProc*) NULL);
135130

136131
Py_INCREF(Py_None);

0 commit comments

Comments
 (0)