225 |
expanding file names. This can be bound to / or \. */ |
expanding file names. This can be bound to / or \. */ |
226 |
Lisp_Object Vdirectory_sep_char; |
Lisp_Object Vdirectory_sep_char; |
227 |
|
|
228 |
|
#ifdef HAVE_FSYNC |
229 |
|
/* Nonzero means skip the call to fsync in Fwrite-region. */ |
230 |
|
int write_region_inhibit_fsync; |
231 |
|
#endif |
232 |
|
|
233 |
extern Lisp_Object Vuser_login_name; |
extern Lisp_Object Vuser_login_name; |
234 |
|
|
235 |
#ifdef WINDOWSNT |
#ifdef WINDOWSNT |
5301 |
Disk full in NFS may be reported here. */ |
Disk full in NFS may be reported here. */ |
5302 |
/* mib says that closing the file will try to write as fast as NFS can do |
/* mib says that closing the file will try to write as fast as NFS can do |
5303 |
it, and that means the fsync here is not crucial for autosave files. */ |
it, and that means the fsync here is not crucial for autosave files. */ |
5304 |
if (!auto_saving && fsync (desc) < 0) |
if (!auto_saving && !write_region_inhibit_fsync && fsync (desc) < 0) |
5305 |
{ |
{ |
5306 |
/* If fsync fails with EINTR, don't treat that as serious. */ |
/* If fsync fails with EINTR, don't treat that as serious. */ |
5307 |
if (errno != EINTR) |
if (errno != EINTR) |
6747 |
a non-nil value. */); |
a non-nil value. */); |
6748 |
Vauto_save_list_file_name = Qnil; |
Vauto_save_list_file_name = Qnil; |
6749 |
|
|
6750 |
|
#ifdef HAVE_FSYNC |
6751 |
|
DEFVAR_BOOL ("write-region-inhibit-fsync", &write_region_inhibit_fsync, |
6752 |
|
doc: /* *Non-nil means don't call fsync after saving files. |
6753 |
|
Enabling this variable may result in data loss! */); |
6754 |
|
write_region_inhibit_fsync = 0; |
6755 |
|
#endif |
6756 |
|
|
6757 |
defsubr (&Sfind_file_name_handler); |
defsubr (&Sfind_file_name_handler); |
6758 |
defsubr (&Sfile_name_directory); |
defsubr (&Sfile_name_directory); |
6759 |
defsubr (&Sfile_name_nondirectory); |
defsubr (&Sfile_name_nondirectory); |