diff options
Diffstat (limited to 'src/if_cscope.c')
-rw-r--r-- | src/if_cscope.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/if_cscope.c b/src/if_cscope.c index 2b4ba0813..4c3e2bd31 100644 --- a/src/if_cscope.c +++ b/src/if_cscope.c @@ -1076,8 +1076,8 @@ err_closing: /* * PRIVATE: cs_find * - * query cscope using command line interface. parse the output and use tselect - * to allow choices. like Nvi, creates a pipe to send to/from query/cscope. + * Query cscope using command line interface. Parse the output and use tselect + * to allow choices. Like Nvi, creates a pipe to send to/from query/cscope. * * returns TRUE if we jump to a tag or abort, FALSE if not. */ @@ -1214,7 +1214,10 @@ cs_find_common(opt, pat, forceit, verbose, use_ll, cmdline) nummatches = (int *)alloc(sizeof(int)*csinfo_size); if (nummatches == NULL) + { + vim_free(cmd); return FALSE; + } /* Send query to all open connections, then count the total number * of matches so we can alloc all in one swell foop. */ @@ -1289,7 +1292,7 @@ cs_find_common(opt, pat, forceit, verbose, use_ll, cmdline) # ifdef FEAT_WINDOWS if (postponed_split != 0) { - win_split(postponed_split > 0 ? postponed_split : 0, + (void)win_split(postponed_split > 0 ? postponed_split : 0, postponed_split_flags); RESET_BINDING(curwin); postponed_split = 0; @@ -2085,6 +2088,8 @@ cs_print_tags_priv(matches, cntxts, num_matches) strcpy(tbuf, matches[0]); ptag = strtok(tbuf, "\t"); + if (ptag == NULL) + return; newsize = (int)(strlen(cstag_msg) + strlen(ptag)); buf = (char *)alloc(newsize); |