summaryrefslogtreecommitdiff
path: root/src/ops.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2005-03-18 20:25:31 +0000
committerBram Moolenaar <Bram@vim.org>2005-03-18 20:25:31 +0000
commit4317d9b4867621ec572a3a4010587d59ecc51813 (patch)
treeda053bbf9f210d8c406c070b6e8bafe01faeb5b3 /src/ops.c
parenta5319aed9bad7cd9094d2a8ba34e99270ccdbc0f (diff)
downloadvim-4317d9b4867621ec572a3a4010587d59ecc51813.zip
updated for version 7.0061
Diffstat (limited to 'src/ops.c')
-rw-r--r--src/ops.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/ops.c b/src/ops.c
index 31c23bfb1..9a257ee47 100644
--- a/src/ops.c
+++ b/src/ops.c
@@ -648,6 +648,13 @@ op_reindent(oap, how)
linenr_T last_changed = 0;
linenr_T start_lnum = curwin->w_cursor.lnum;
+ /* Don't even try when 'modifiable' is off. */
+ if (!curbuf->b_p_ma)
+ {
+ EMSG(_(e_modifiable));
+ return;
+ }
+
for (i = oap->line_count; --i >= 0 && !got_int; )
{
/* it's a slow thing to do, so give feedback so there's no worry that