[Python-checkins] python/dist/src/Modules _tkinter.c,1.166,1.167

tim_one at users.sourceforge.net tim_one at users.sourceforge.net
Wed Aug 4 04:16:51 CEST 2004


Update of /cvsroot/python/python/dist/src/Modules
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28069/Modules

Modified Files:
	_tkinter.c 
Log Message:
Tkapp_New():  Rewrite in C so it compiles again.


Index: _tkinter.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/_tkinter.c,v
retrieving revision 1.166
retrieving revision 1.167
diff -C2 -d -r1.166 -r1.167
*** _tkinter.c	3 Aug 2004 18:45:31 -0000	1.166
--- _tkinter.c	4 Aug 2004 02:16:48 -0000	1.167
***************
*** 581,584 ****
--- 581,585 ----
  	TkappObject *v;
  	char *argv0;
+ 
  	v = PyObject_New(TkappObject, &Tkapp_Type);
  	if (v == NULL)
***************
*** 647,651 ****
--- 648,654 ----
  	/* some initial arguments need to be in argv */
  	if (sync || use) {
+ 		char *args;
  		int len = 0;
+ 
  		if (sync)
  			len += sizeof "-sync";
***************
*** 653,657 ****
  			len += strlen(use) + sizeof "-use ";
  
! 		char *args = (char*)ckalloc(len);
  		if (!args) {
  			PyErr_NoMemory();
--- 656,660 ----
  			len += strlen(use) + sizeof "-use ";
  
! 		args = (char*)ckalloc(len);
  		if (!args) {
  			PyErr_NoMemory();



More information about the Python-checkins mailing list