Mercurial > vim
comparison src/edit.c @ 2047:85da03763130 v7.2.333
updated for version 7.2.333
Problem: Warnings from static code analysis.
Solution: Small changes to various lines. (Dominique Pelle)
author | Bram Moolenaar <bram@zimbu.org> |
---|---|
date | Tue, 19 Jan 2010 14:59:56 +0100 |
parents | d06a461924a3 |
children | 4a4287c09953 |
comparison
equal
deleted
inserted
replaced
2046:d433f43849ba | 2047:85da03763130 |
---|---|
4046 case CTRL_X_TAGS: | 4046 case CTRL_X_TAGS: |
4047 /* set p_ic according to p_ic, p_scs and pat for find_tags(). */ | 4047 /* set p_ic according to p_ic, p_scs and pat for find_tags(). */ |
4048 save_p_ic = p_ic; | 4048 save_p_ic = p_ic; |
4049 p_ic = ignorecase(compl_pattern); | 4049 p_ic = ignorecase(compl_pattern); |
4050 | 4050 |
4051 /* Find up to TAG_MANY matches. Avoids that an enourmous number | 4051 /* Find up to TAG_MANY matches. Avoids that an enormous number |
4052 * of matches is found when compl_pattern is empty */ | 4052 * of matches is found when compl_pattern is empty */ |
4053 if (find_tags(compl_pattern, &num_matches, &matches, | 4053 if (find_tags(compl_pattern, &num_matches, &matches, |
4054 TAG_REGEXP | TAG_NAMES | TAG_NOIC | | 4054 TAG_REGEXP | TAG_NAMES | TAG_NOIC | |
4055 TAG_INS_COMP | (ctrl_x_mode ? TAG_VERBOSE : 0), | 4055 TAG_INS_COMP | (ctrl_x_mode ? TAG_VERBOSE : 0), |
4056 TAG_MANY, curbuf->b_ffname) == OK && num_matches > 0) | 4056 TAG_MANY, curbuf->b_ffname) == OK && num_matches > 0) |
4217 == NULL | 4217 == NULL |
4218 && (IObuff[len - 2] == '?' | 4218 && (IObuff[len - 2] == '?' |
4219 || IObuff[len - 2] == '!')))) | 4219 || IObuff[len - 2] == '!')))) |
4220 IObuff[len++] = ' '; | 4220 IObuff[len++] = ' '; |
4221 } | 4221 } |
4222 /* copy as much as posible of the new word */ | 4222 /* copy as much as possible of the new word */ |
4223 if (tmp_ptr - ptr >= IOSIZE - len) | 4223 if (tmp_ptr - ptr >= IOSIZE - len) |
4224 tmp_ptr = ptr + IOSIZE - len - 1; | 4224 tmp_ptr = ptr + IOSIZE - len - 1; |
4225 STRNCPY(IObuff + len, ptr, tmp_ptr - ptr); | 4225 STRNCPY(IObuff + len, ptr, tmp_ptr - ptr); |
4226 len += (int)(tmp_ptr - ptr); | 4226 len += (int)(tmp_ptr - ptr); |
4227 flags |= CONT_S_IPOS; | 4227 flags |= CONT_S_IPOS; |
5825 #ifdef FEAT_COMMENTS | 5825 #ifdef FEAT_COMMENTS |
5826 && leader_len == 0 | 5826 && leader_len == 0 |
5827 #endif | 5827 #endif |
5828 && !has_format_option(FO_WRAP)) | 5828 && !has_format_option(FO_WRAP)) |
5829 | 5829 |
5830 { | |
5831 textwidth = 0; | |
5832 break; | 5830 break; |
5833 } | |
5834 if ((startcol = curwin->w_cursor.col) == 0) | 5831 if ((startcol = curwin->w_cursor.col) == 0) |
5835 break; | 5832 break; |
5836 | 5833 |
5837 /* find column of textwidth border */ | 5834 /* find column of textwidth border */ |
5838 coladvance((colnr_T)textwidth); | 5835 coladvance((colnr_T)textwidth); |