Skip to content

Commit e362c3d

Browse files
committed
patch 8.0.0215: NULL pointer use if cscope line looks like emacs tag
Problem: When a Cscope line contains CTRL-L a NULL pointer may be used. (Coverity) Solution: Don't check for an emacs tag in a cscope line.
1 parent d7a9615 commit e362c3d

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

src/tag.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1752,8 +1752,9 @@ find_tags(
17521752
/*
17531753
* Emacs tags line with CTRL-L: New file name on next line.
17541754
* The file name is followed by a ','.
1755+
* Remember etag file name in ebuf.
17551756
*/
1756-
if (*lbuf == Ctrl_L) /* remember etag file name in ebuf */
1757+
if (*lbuf == Ctrl_L && !use_cscope)
17571758
{
17581759
is_etag = 1; /* in case at the start */
17591760
state = TS_LINEAR;

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,8 @@ static char *(features[]) =
764764

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
215,
767769
/**/
768770
214,
769771
/**/

0 commit comments

Comments
 (0)