[Python-checkins] python/dist/src/Mac/OSX/PythonLauncher main.m, 1.1, 1.2

jackjansen at users.sourceforge.net jackjansen at users.sourceforge.net
Thu Jun 3 10:15:52 EDT 2004


Update of /cvsroot/python/python/dist/src/Mac/OSX/PythonLauncher
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9517

Modified Files:
	main.m 
Log Message:
On startup, attempt to set the working directory to $HOME.

Fixes #913581.


Index: main.m
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/OSX/PythonLauncher/main.m,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** main.m	29 Jul 2002 21:36:35 -0000	1.1
--- main.m	3 Jun 2004 14:15:50 -0000	1.2
***************
*** 8,14 ****
--- 8,17 ----
  
  #import <Cocoa/Cocoa.h>
+ #include <unistd.h>
  
  int main(int argc, const char *argv[])
  {
+ 	char *home = getenv("HOME");
+ 	if (home) chdir(home);
      return NSApplicationMain(argc, argv);
  }




More information about the Python-checkins mailing list