[vim/vim] Refactor the compile_lhs() function (PR #16245)

10 views
Skip to first unread message

Yegappan Lakshmanan

unread,
Dec 18, 2024, 12:30:10 AM12/18/24
to vim/vim, Subscribed

You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/16245

Commit Summary

  • 2e76ec9 Refactor the compile_lhs function

File Changes

(1 file)

Patch Links:


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/16245@github.com>

Christian Brabandt

unread,
Dec 18, 2024, 2:16:40 PM12/18/24
to vim/vim, Subscribed

thanks!


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/16245/c2552086859@github.com>

Christian Brabandt

unread,
Dec 18, 2024, 2:39:14 PM12/18/24
to vim/vim, Subscribed

Closed #16245 via d0186c5.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/16245/issue_event/15708090498@github.com>

Christian Brabandt

unread,
Dec 19, 2024, 2:48:42 AM12/19/24
to vim/vim, Subscribed

@yegappan coverity complains about this part here:

Please find the latest report on new defect(s) introduced to vim found with Coverity Scan.

1 new defect(s) introduced to vim found with Coverity Scan.


New defect(s) Reported-by: Coverity Scan
Showing 1 of 1 defect(s)


** CID 1636846:  Memory - illegal accesses  (UNINIT)


________________________________________________________________________________________________________
*** CID 1636846:  Memory - illegal accesses  (UNINIT)
/src/vim9compile.c: 2287 in compile_lhs()
2281         int        oplen,
2282         cctx_T        *cctx)
2283     {
2284         char_u    *var_end;
2285         int        is_decl = is_decl_command(cmdidx);
2286     
    CID 1636846:  Memory - illegal accesses  (UNINIT)
    Using uninitialized value "var_end" when calling "lhs_init".
2287         if (lhs_init(lhs, var_start, is_decl, heredoc, &var_end) == FAIL)
2288         return FAIL;
2289     
2290         if (cctx->ctx_skip != SKIP_YES)
2291         {
2292         // compile the LHS destination


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/16245/c2552992352@github.com>

Yegappan Lakshmanan

unread,
Dec 19, 2024, 10:47:36 AM12/19/24
to vim...@googlegroups.com, reply+ACY5DGFMADZWOZG4U7...@reply.github.com, vim/vim, Subscribed
Hi Christian,

On Wed, Dec 18, 2024 at 11:48 PM Christian Brabandt <vim-dev...@256bit.org> wrote:

@yegappan coverity complains about this part here:


I have created the PR https://github.com/vim/vim/pull/16256 to address this.

Regards,
Yegappan

vim-dev ML

unread,
Dec 19, 2024, 10:48:05 AM12/19/24
to vim/vim, vim-dev ML, Your activity

Hi Christian,

On Wed, Dec 18, 2024 at 11:48 PM Christian Brabandt <
***@***.***> wrote:

> @yegappan <https://github.com/yegappan> coverity complains about this


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/16245/c2554727402@github.com>

Reply all
Reply to author
Forward
0 new messages