summaryrefslogtreecommitdiff
path: root/src/diff.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/diff.c')
-rw-r--r--src/diff.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/diff.c b/src/diff.c
index bb95d5ed6..753d089b6 100644
--- a/src/diff.c
+++ b/src/diff.c
@@ -775,7 +775,7 @@ diff_write(buf_T *buf, diffin_T *din)
{
int r;
char_u *save_ff;
- int save_lockmarks;
+ int save_cmod_flags;
if (din->din_fname == NULL)
return diff_write_buffer(buf, din);
@@ -783,14 +783,14 @@ diff_write(buf_T *buf, diffin_T *din)
// Always use 'fileformat' set to "unix".
save_ff = buf->b_p_ff;
buf->b_p_ff = vim_strsave((char_u *)FF_UNIX);
- save_lockmarks = cmdmod.lockmarks;
+ save_cmod_flags = cmdmod.cmod_flags;
// Writing the buffer is an implementation detail of performing the diff,
// so it shouldn't update the '[ and '] marks.
- cmdmod.lockmarks = TRUE;
+ cmdmod.cmod_flags |= CMOD_LOCKMARKS;
r = buf_write(buf, din->din_fname, NULL,
(linenr_T)1, buf->b_ml.ml_line_count,
NULL, FALSE, FALSE, FALSE, TRUE);
- cmdmod.lockmarks = save_lockmarks;
+ cmdmod.cmod_flags = save_cmod_flags;
free_string_option(buf->b_p_ff);
buf->b_p_ff = save_ff;
return r;
@@ -1187,13 +1187,13 @@ ex_diffpatch(exarg_T *eap)
#endif
#ifdef FEAT_BROWSE
char_u *browseFile = NULL;
- int browse_flag = cmdmod.browse;
+ int save_cmod_flags = cmdmod.cmod_flags;
#endif
stat_T st;
char_u *esc_name = NULL;
#ifdef FEAT_BROWSE
- if (cmdmod.browse)
+ if (cmdmod.cmod_flags & CMOD_BROWSE)
{
browseFile = do_browse(0, (char_u *)_("Patch file"),
eap->arg, NULL, NULL,
@@ -1201,7 +1201,7 @@ ex_diffpatch(exarg_T *eap)
if (browseFile == NULL)
return; // operation cancelled
eap->arg = browseFile;
- cmdmod.browse = FALSE; // don't let do_ecmd() browse again
+ cmdmod.cmod_flags &= ~CMOD_BROWSE; // don't let do_ecmd() browse again
}
#endif
@@ -1310,7 +1310,7 @@ ex_diffpatch(exarg_T *eap)
need_mouse_correct = TRUE;
#endif
// don't use a new tab page, each tab page has its own diffs
- cmdmod.tab = 0;
+ cmdmod.cmod_tab = 0;
if (win_split(0, (diff_flags & DIFF_VERTICAL) ? WSP_VERT : 0) != FAIL)
{
@@ -1355,7 +1355,7 @@ theend:
vim_free(esc_name);
#ifdef FEAT_BROWSE
vim_free(browseFile);
- cmdmod.browse = browse_flag;
+ cmdmod.cmod_flags = save_cmod_flags;
#endif
}
@@ -1377,7 +1377,7 @@ ex_diffsplit(exarg_T *eap)
set_fraction(curwin);
// don't use a new tab page, each tab page has its own diffs
- cmdmod.tab = 0;
+ cmdmod.cmod_tab = 0;
if (win_split(0, (diff_flags & DIFF_VERTICAL) ? WSP_VERT : 0) != FAIL)
{