From: Adrian Robert Date: Tue, 5 Aug 2008 17:33:05 +0000 (+0000) Subject: emacs.c (main): Under NS, set working dir to HOME when get a 'psn' argument. X-Git-Tag: emacs-pretest-23.0.90~3643 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=95889848e895a3da6a97531b4e778dfaec185b72;p=emacs.git emacs.c (main): Under NS, set working dir to HOME when get a 'psn' argument. --- diff --git a/src/ChangeLog b/src/ChangeLog index ce5e7a3a04a..73f93df544f 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,6 +1,6 @@ 2008-08-04 Adrian Robert - * emacs.c (main): Under NS, set working dir to $HOME when get a "psn" + * emacs.c (main): Under NS, set working dir to HOME when get a "psn" argument. 2008-08-05 Juanma Barranquero diff --git a/src/emacs.c b/src/emacs.c index 0f9d3fd5554..21c57f045df 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -1337,10 +1337,9 @@ main (int argc, char **argv) skip_args += 1; chdir (getenv ("HOME")); } - else + else if (skip_args+1 < argc && !strncmp(argv[skip_args+1], "-psn", 4)) { - if (skip_args+1 < argc && !strncmp(argv[skip_args+1], "-psn", 4)) - skip_args += 2; + skip_args += 2; chdir (getenv ("HOME")); } }