comparison src/fileio.c @ 696:f0a9ef4db025

updated for version 7.0210
author vimboss
date Tue, 28 Feb 2006 23:52:23 +0000
parents 07d199fe02ed
children 0f9f4761ad9c
comparison
equal deleted inserted replaced
695:653eeb31bad6 696:f0a9ef4db025
2355 */ 2355 */
2356 curbuf->b_op_start.lnum = from + 1; 2356 curbuf->b_op_start.lnum = from + 1;
2357 curbuf->b_op_start.col = 0; 2357 curbuf->b_op_start.col = 0;
2358 curbuf->b_op_end.lnum = from + linecnt; 2358 curbuf->b_op_end.lnum = from + linecnt;
2359 curbuf->b_op_end.col = 0; 2359 curbuf->b_op_end.col = 0;
2360
2361 #ifdef WIN32
2362 /*
2363 * Work around a weird problem: When a file has two links (only
2364 * possible on NTFS) and we write through one link, then stat() it
2365 * throught the other link, the timestamp information may be wrong.
2366 * It's correct again after reading the file, thus reset the timestamp
2367 * here.
2368 */
2369 if (newfile && !read_stdin && !read_buffer
2370 && mch_stat((char *)fname, &st) >= 0)
2371 {
2372 buf_store_time(curbuf, &st, fname);
2373 curbuf->b_mtime_read = curbuf->b_mtime;
2374 }
2375 #endif
2360 } 2376 }
2361 msg_scroll = msg_save; 2377 msg_scroll = msg_save;
2362 2378
2363 #ifdef FEAT_VIMINFO 2379 #ifdef FEAT_VIMINFO
2364 /* 2380 /*
3261 || st.st_gid != st_old.st_gid 3277 || st.st_gid != st_old.st_gid
3262 # endif 3278 # endif
3263 ) 3279 )
3264 backup_copy = TRUE; 3280 backup_copy = TRUE;
3265 else 3281 else
3282 # else
3283 # ifdef WIN32
3284 /* On NTFS file systems hard links are possible. */
3285 if (mch_is_linked(fname))
3286 backup_copy = TRUE;
3287 else
3288 # endif
3266 # endif 3289 # endif
3267 { 3290 {
3268 /* 3291 /*
3269 * Check if we can create a file and set the owner/group to 3292 * Check if we can create a file and set the owner/group to
3270 * the ones from the original file. 3293 * the ones from the original file.