Mercurial > hg > xemacs-beta
comparison src/fileio.c @ 367:a4f53d9b3154 r21-1-13
Import from CVS: tag r21-1-13
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:01:07 +0200 |
parents | 972bbb6d6ca2 |
children | cc15677e0335 |
comparison
equal
deleted
inserted
replaced
366:83d76f480a59 | 367:a4f53d9b3154 |
---|---|
2052 INTP (ok_if_already_exists), 0); | 2052 INTP (ok_if_already_exists), 0); |
2053 /* Syncing with FSF 19.34.6 note: FSF does not report a file error | 2053 /* Syncing with FSF 19.34.6 note: FSF does not report a file error |
2054 on NT here. --marcpa */ | 2054 on NT here. --marcpa */ |
2055 /* But FSF #defines link as sys_link which is supplied in nt.c. We can't do | 2055 /* But FSF #defines link as sys_link which is supplied in nt.c. We can't do |
2056 that because sysfile.h defines sys_link depending on ENCAPSULATE_LINK. | 2056 that because sysfile.h defines sys_link depending on ENCAPSULATE_LINK. |
2057 Reverted to previous behaviour pending a working fix. (jhar) */ | 2057 Reverted to previous behavior pending a working fix. (jhar) */ |
2058 #if defined(WINDOWSNT) | 2058 #if defined(WINDOWSNT) |
2059 /* Windows does not support this operation. */ | 2059 /* Windows does not support this operation. */ |
2060 report_file_error ("Adding new name", Flist (2, &filename)); | 2060 report_file_error ("Adding new name", Flist (2, &filename)); |
2061 #else /* not defined(WINDOWSNT) */ | 2061 #else /* not defined(WINDOWSNT) */ |
2062 | 2062 |
2777 | 2777 |
2778 if (!NILP (replace) || !NILP (beg) || !NILP (end)) | 2778 if (!NILP (replace) || !NILP (beg) || !NILP (end)) |
2779 { | 2779 { |
2780 end_multiple_change (buf, mc_count); | 2780 end_multiple_change (buf, mc_count); |
2781 | 2781 |
2782 return Fsignal (Qfile_error, | 2782 RETURN_UNGCPRO (Fsignal (Qfile_error, |
2783 list2 (build_translated_string("not a regular file"), | 2783 list2 (build_translated_string("not a regular file"), |
2784 filename)); | 2784 filename))); |
2785 } | 2785 } |
2786 } | 2786 } |
2787 #endif /* S_IFREG */ | 2787 #endif /* S_IFREG */ |
2788 | 2788 |
2789 if (!NILP (beg)) | 2789 if (!NILP (beg)) |
3420 { | 3420 { |
3421 if (visiting_other) | 3421 if (visiting_other) |
3422 message ("Wrote %s", XSTRING_DATA (visit_file)); | 3422 message ("Wrote %s", XSTRING_DATA (visit_file)); |
3423 else | 3423 else |
3424 { | 3424 { |
3425 Lisp_Object fsp; | 3425 Lisp_Object fsp = Qnil; |
3426 struct gcpro nngcpro1; | 3426 struct gcpro nngcpro1; |
3427 | 3427 |
3428 NNGCPRO1 (fsp); | 3428 NNGCPRO1 (fsp); |
3429 fsp = Ffile_symlink_p (fn); | 3429 fsp = Ffile_symlink_p (fn); |
3430 if (NILP (fsp)) | 3430 if (NILP (fsp)) |
3755 lisp_to_time (time_list, &the_time); | 3755 lisp_to_time (time_list, &the_time); |
3756 current_buffer->modtime = (int) the_time; | 3756 current_buffer->modtime = (int) the_time; |
3757 } | 3757 } |
3758 else | 3758 else |
3759 { | 3759 { |
3760 Lisp_Object filename; | 3760 Lisp_Object filename = Qnil; |
3761 struct stat st; | 3761 struct stat st; |
3762 Lisp_Object handler; | 3762 Lisp_Object handler; |
3763 struct gcpro gcpro1, gcpro2, gcpro3; | 3763 struct gcpro gcpro1, gcpro2, gcpro3; |
3764 | 3764 |
3765 GCPRO3 (filename, time_list, current_buffer->filename); | 3765 GCPRO3 (filename, time_list, current_buffer->filename); |