comparison src/screen.c @ 7007:5ea5bd9c18d2 v7.4.821

patch 7.4.821 Problem: Coverity reports a few problems. Solution: Avoid the warnings. (Christian Brabandt)
author Bram Moolenaar <bram@vim.org>
date Tue, 11 Aug 2015 18:53:03 +0200
parents 87cb71d54e8a
children 2c00f6b312bf
comparison
equal deleted inserted replaced
7006:1520ad7bad2f 7007:5ea5bd9c18d2
7799 shl->lnum = lnum; 7799 shl->lnum = lnum;
7800 } 7800 }
7801 } 7801 }
7802 } 7802 }
7803 posmatch->cur = 0; 7803 posmatch->cur = 0;
7804 if (shl->lnum == lnum) 7804 if (shl->lnum == lnum && bot >= 0)
7805 { 7805 {
7806 colnr_T start = posmatch->pos[bot].col == 0 7806 colnr_T start = posmatch->pos[bot].col == 0
7807 ? 0 : posmatch->pos[bot].col - 1; 7807 ? 0 : posmatch->pos[bot].col - 1;
7808 colnr_T end = posmatch->pos[bot].col == 0 7808 colnr_T end = posmatch->pos[bot].col == 0
7809 ? MAXCOL : start + posmatch->pos[bot].len; 7809 ? MAXCOL : start + posmatch->pos[bot].len;