Juanma Barranquero
80bad45fc8
(Fread_file_name): Use empty_unibyte_string.
2007-06-08 20:12:52 +00:00
Kenichi Handa
2f868094f4
(Fcopy_file): Call barf_or_query_if_file_exists with
...
non-encoded file name.
(Frename_file): Likewise.
(Fadd_name_to_file): Likewise.
(Fmake_symbolic_link): Likewise.
2007-03-22 12:15:04 +00:00
YAMAMOTO Mitsuharu
aab12958c6
(do_auto_save_unwind): Add BLOCK_INPUT around fclose.
...
(Fdo_auto_save): Add BLOCK_INPUT around fwrite.
2007-03-20 08:49:53 +00:00
Glenn Morris
4e6835dbc4
Add 2007 to copyright years.
2007-01-21 04:57:37 +00:00
Richard M. Stallman
aaf469fc3d
(Fread_file_name_internal): Pass Vread_file_name_predicate
...
to Ffile_name_completion.
2006-12-17 20:11:16 +00:00
YAMAMOTO Mitsuharu
697c17a298
[__NetBSD__]: Don't define `unix'.
...
(Funix_sync, syms_of_fileio): Use `#ifdef HAVE_SYNC' instead of
`#ifdef unix'.
2006-12-04 08:16:47 +00:00
Richard M. Stallman
994a72627c
Break line before &&, not after.
2006-11-21 01:34:30 +00:00
Kenichi Handa
3e892ae354
(Fread_file_name_internal): Use SBYTES (not SCHARS) to
...
check the tailing slash of a filename.
2006-11-20 12:14:46 +00:00
Kim F. Storm
a9f2aeaeed
(Fmake_directory_internal, Fdelete_directory)
...
(Fdelete_file): Simplify; use list1.
(Frename_file, Fadd_name_to_file, Fmake_symbolic_link):
Simplify; remove NO_ARG_ARRAY stuff, use list2.
2006-08-25 23:33:12 +00:00
Kenichi Handa
29cbc48294
(choose_write_coding_system): Use LF for end-of-line
...
in auto-saving.
2006-08-16 00:20:53 +00:00
Kim F. Storm
24b1ddad0b
(report_file_error): Use xsignal.
...
(barf_or_query_if_file_exists, Fcopy_file, Fdelete_file)
(Finsert_file_contents): Use xsignal2.
(syms_of_fileio): Use list2, list3.
2006-07-18 13:27:48 +00:00
YAMAMOTO Mitsuharu
67c08d6c72
Include blockinput.h.
...
(Fexpand_file_name, search_embedded_absfilename): Add BLOCK_INPUT
around getpwnam.
(search_embedded_absfilename): Remove spurious xfree.
2006-07-12 08:37:45 +00:00
Kim F. Storm
83f8d90363
(Fdo_auto_save): Update/simplify sit_for calls.
2006-07-11 20:11:10 +00:00
Stephen Gildea
26816cbf78
fileio.c (do_auto_save_make_dir): Make the auto-save-list-file
...
directory unreadable for better user privacy.
2006-07-08 11:42:40 +00:00
Eli Zaretskii
f83caf703c
(Frename_file) [DOS_NT]: Don't try to move directory to itself on DOS_NT
...
platforms, if the old and new names are identical but for the letter-case.
2006-06-23 10:19:11 +00:00
Chong Yidong
795c20df7a
* fileio.c (Fcopy_file): Delete argument MUSTBENEW. Incorporate
...
the exclusive file-opening functionality into the behavior when
OK-IF-ALREADY-EXISTS is nil.
(Frename_file): Call Fcopy_file without MUSTBENEW argument.
2006-05-26 15:18:28 +00:00
Kenichi Handa
17ad716ac4
(Finsert_file_contents): Fix for the case of IO error
...
while handling replace operation.
2006-05-11 04:13:33 +00:00
Kenichi Handa
452dd0bed5
(choose_write_coding_system): Use system_eol_type for
...
encoding if eol_type is not yet decided.
2006-05-08 05:20:16 +00:00
Kenichi Handa
95c1c9018e
(Fwrite_region): Set visit_file to Qnil before GCPRO
...
it.
2006-03-20 06:26:23 +00:00
Kenichi Handa
77343e1d1c
(Finsert_file_contents): When a text is replaced
...
partially, be sure to set point before the inserted characters.
2006-02-24 06:46:54 +00:00
Stefan Monnier
b8f7f3be80
(Fexpand_file_name): Remove redundant tests. Fix elimination of // so that
...
it doesn't prevent elimination of an immediately following /. or /..
2006-01-10 17:46:41 +00:00
Richard M. Stallman
83c1cf6df6
(Finsert_file_contents): Set Vdeactivate_mark when we change the buffer.
2005-12-11 05:08:18 +00:00
Ken Raeburn
a3911e8c0a
(internal_delete_file, Fread_file_name_internal): Avoid dangerous side effects in NILP argument.
2005-12-06 07:39:37 +00:00
Lars Hansen
19a9c3b741
(file-regular-p): Doc fix.
2005-11-10 11:57:35 +00:00
Kim F. Storm
e01f77736e
(auto_save_error): Call SAFE_FREE.
2005-10-20 15:03:10 +00:00
Romain Francoise
e3f509dd6e
(syms_of_fileio): Clarify docstring of `write-region-inhibit-fsync'.
2005-09-16 06:50:06 +00:00
Romain Francoise
ccf6179595
(write_region_inhibit_fsync): New variable.
...
(Fwrite_region): Use it to skip call to fsync.
(syms_of_fileio): Initialize it.
2005-09-14 20:19:39 +00:00
Kenichi Handa
2b046a720b
(Fexpand_file_name): Check multibyteness of
...
default_directory.
2005-09-14 02:18:49 +00:00
Kim F. Storm
dfc22242b5
(auto_save_error): Pass copy of lisp string to message2.
2005-09-12 13:42:49 +00:00
Thien-Thi Nguyen
0b5538bd85
Update years in copyright notice; nfc.
2005-08-07 12:33:19 +00:00
Kim F. Storm
fff7e9825a
(Fdo_auto_save, do_auto_save_unwind):
...
Use make_save_value to unwind protect stream.
2005-07-20 14:39:35 +00:00
Lute Kamstra
4fc5845fe8
Update FSF's address.
2005-07-04 16:49:24 +00:00
Eli Zaretskii
b016179b58
(Fcopy_file): Rearrange the code that calls fchown and
...
fchmod so that chmod doesn't get called on MSDOS before the file
is closed.
2005-07-02 08:16:24 +00:00
Richard M. Stallman
586702ceeb
(Fcopy_file): New arg PRESERVE_UID_GID.
...
Use fchmod to copy the file modes.
(Frename_file): Don't copy UID and GID here;
instead, specify t for PRESERVE_UID_GID when calling Fcopy_file.
2005-06-25 22:37:49 +00:00
Eli Zaretskii
90296dd36c
(Frename_file): Undo last change: no need to ifdef away
...
chown on DOS_NT platforms.
2005-06-24 10:41:19 +00:00
Juanma Barranquero
c4f6ca2474
(Frename_file)[!DOS_NT]: Don't call chown on MSDOS/Windows.
2005-06-24 09:04:15 +00:00
Richard M. Stallman
d550c42590
(Frename_file): Preserve owner and group, if possible.
2005-06-23 21:29:26 +00:00
Stefan Monnier
490ee85358
(Finsert_file_contents): Lisp_Object/int mixup.
2005-05-31 21:54:43 +00:00
Eli Zaretskii
aa4060b96f
(Fexpand_file_name) [DOS_NT]: Don't try to support "superroot"
...
on DOS_NT systems.
2005-05-21 15:28:57 +00:00
Richard M. Stallman
6840d3505d
(Finsert_file_contents): Fix previous change.
2005-05-13 23:09:41 +00:00
Richard M. Stallman
68780e2abd
(Ffind_file_name_handler): Handle lambda-exp as handler.
...
(Finsert_file_contents): If we read 0 bytes from a special file,
unlock the visited file if we locked it.
(Fmake_symbolic_link, Frecent_auto_save_p): Doc fixes.
(Ffile_exists_p, Ffile_symlink_p): Doc fixes.
2005-05-13 13:34:23 +00:00
Juanma Barranquero
a4e03fe5e2
(Fexpand_file_name, Frename_file, Fadd_name_to_file, Fmake_symbolic_link,
...
Faccess_file, Frecent_auto_save_p): Doc fixes.
2005-05-08 23:40:34 +00:00
Richard M. Stallman
f6c9b68362
(Ffind_file_name_handler): Handle the `operations'
...
property of the file name handler.
(Qoperations): New variable.
(syms_of_fileio): Initialize and staticpro it.
2005-04-30 20:12:13 +00:00
Eli Zaretskii
7fce7dfe69
(Fcopy_file): Doc fix.
...
[MSDOS]: Fix call to emacs_open: buffer_file_type not defined and
not needed.
2005-04-24 09:19:10 +00:00
Richard M. Stallman
c50f15d05a
(Fcopy_file): New arg MUSTBENEW.
...
(Frename_file): Pass new arg to Fcopy_file.
2005-04-23 16:19:37 +00:00
Thien-Thi Nguyen
5b9c0a1d12
Remove reference to defunct vms-pwd.h.
...
For pwd.h, use HAVE_PWD_H, not !VMS.
2005-04-20 15:07:03 +00:00
Stefan Monnier
f34574c6d5
(search_embedded_absfilename): Fix last change.
2005-03-30 22:33:00 +00:00
Stefan Monnier
c70a4df6d2
(Fexpand_file_name): Use IS_DEVICE_SEP.
...
(file_name_absolute_p): New fun, extracted from Ffile_name_absolute_p.
(Ffile_name_absolute_p): Use it.
(search_embedded_absfilename): New fun, extracted from Fsubstitute_in_file_name.
Use file_name_absolute_p. Free the pw data after use.
(Fsubstitute_in_file_name): Use it.
After cutting a prefix, re-check file-name-handler.
2005-03-28 21:31:14 +00:00
Richard M. Stallman
7c0f6118c3
(Fcopy_file, Frename_file, Fadd_name_to_file)
...
(Fmake_symbolic_link): Use G to read the new file name.
2005-03-17 23:36:03 +00:00
Stefan Monnier
dac24db404
(Fmake_symbolic_link): Fix last change.
2005-03-12 01:37:51 +00:00