diff options
author | Karoly Lorentey <lorentey@elte.hu> | 2006-07-14 05:56:32 +0000 |
---|---|---|
committer | Karoly Lorentey <lorentey@elte.hu> | 2006-07-14 05:56:32 +0000 |
commit | 99715bbc447eb633e45ffa23b87284771ce3ac74 (patch) | |
tree | 3a8a53dfe3dbdd9f8e36965e9f043eae522d3c0e /src/fileio.c | |
parent | 556b89447234f15d1784a23dadbfe429464463a8 (diff) | |
parent | 763bb2d43615bc3ae816422f965d76d5e1ae4bdd (diff) | |
download | emacs-99715bbc447eb633e45ffa23b87284771ce3ac74.tar.gz emacs-99715bbc447eb633e45ffa23b87284771ce3ac74.tar.bz2 emacs-99715bbc447eb633e45ffa23b87284771ce3ac74.zip |
Merged from emacs@sv.gnu.org.
Patches applied:
* emacs@sv.gnu.org/emacs--devo--0--patch-331
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-332
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-333
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-334
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-335
Add note about "link" button-class to etc/TODO
* emacs@sv.gnu.org/emacs--devo--0--patch-336
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-337
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-338
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-339
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-340
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-341
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-342
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-343
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-344
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-345
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-346
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-347
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-348
Update for ERC 5.1.3.
* emacs@sv.gnu.org/emacs--devo--0--patch-349
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-350
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/gnus--rel--5.10--patch-111
Update from CVS: texi/gnus.texi (Summary Buffer Lines): Fix typo.
* emacs@sv.gnu.org/gnus--rel--5.10--patch-112
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-113
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-114
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-572
Diffstat (limited to 'src/fileio.c')
-rw-r--r-- | src/fileio.c | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/src/fileio.c b/src/fileio.c index e5b81ddfd7b..58b1863f225 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -77,6 +77,7 @@ extern int errno; #include "charset.h" #include "coding.h" #include "window.h" +#include "blockinput.h" #include "frame.h" #include "dispextern.h" @@ -1388,7 +1389,9 @@ See also the function `substitute-in-file-name'. */) bcopy ((char *) nm, o, p - nm); o [p - nm] = 0; + BLOCK_INPUT; pw = (struct passwd *) getpwnam (o + 1); + UNBLOCK_INPUT; if (pw) { newdir = (unsigned char *) pw -> pw_dir; @@ -1919,7 +1922,9 @@ See also the function `substitute-in-file-name'.") o[len] = 0; /* Look up the user name. */ + BLOCK_INPUT; pw = (struct passwd *) getpwnam (o + 1); + UNBLOCK_INPUT; if (!pw) error ("\"%s\" isn't a registered user", o + 1); @@ -2113,10 +2118,11 @@ search_embedded_absfilename (nm, endp) /* If we have ~user and `user' exists, discard everything up to ~. But if `user' does not exist, leave ~user alone, it might be a literal file name. */ - if ((pw = getpwnam (o + 1))) + BLOCK_INPUT; + pw = getpwnam (o + 1); + UNBLOCK_INPUT; + if (pw) return p; - else - xfree (pw); } else return p; @@ -5855,7 +5861,11 @@ static Lisp_Object do_auto_save_make_dir (dir) Lisp_Object dir; { - return call2 (Qmake_directory, dir, Qt); + Lisp_Object mode; + + call2 (Qmake_directory, dir, Qt); + XSETFASTINT (mode, 0700); + return Fset_file_modes (dir, mode); } static Lisp_Object @@ -6053,7 +6063,7 @@ A non-nil CURRENT-ONLY argument means save only current buffer. */) { /* If we are going to restore an old message, give time to read ours. */ - sit_for (1, 0, 0, 0, 0); + sit_for (make_number (1), 0, 0); restore_message (); } else |