patch 9.2.0005: Coverity reports unreachable code

Commit: 
https://github.com/vim/vim/commit/e0b10ce95a6a2e8f379940dccb747cddd58d3fb6
Author: Christian Brabandt <[email protected]>
Date:   Sun Feb 15 16:07:27 2026 +0000

    patch 9.2.0005: Coverity reports unreachable code
    
    Problem:  Coverity reports unreachable code, CID: 1681310
    Solution: Drop the ternary checking for non-NULL of from_encoding_raw.
    
    closes: #19402
    
    Signed-off-by: Christian Brabandt <[email protected]>

diff --git a/src/strings.c b/src/strings.c
index f2176f1c4..8b44a2d2b 100644
--- a/src/strings.c
+++ b/src/strings.c
@@ -1469,7 +1469,8 @@ f_blob2str(typval_T *argvars, typval_T *rettv)
        vimconv_T vimconv;
        vimconv.vc_type = CONV_NONE;
        // Use raw encoding name for iconv to preserve endianness (utf-16be vs 
utf-16)
-       if (convert_setup_ext(&vimconv, from_encoding_raw ? from_encoding_raw : 
from_encoding, FALSE, p_enc, FALSE) == FAIL)
+       // from_encoding_raw is guaranteed non-NULL whenever from_encoding != 
NULL
+       if (convert_setup_ext(&vimconv, from_encoding_raw, FALSE, p_enc, FALSE) 
== FAIL)
        {
            ga_clear(&blob_ga);
            semsg(_(e_str_encoding_from_failed), from_encoding);
@@ -1497,8 +1498,8 @@ f_blob2str(typval_T *argvars, typval_T *rettv)
 
            if (from_encoding != NULL)
            {
-               char_u *converted = convert_string(str,
-                       from_encoding_raw ? from_encoding_raw : from_encoding, 
p_enc);
+               // from_encoding_raw is guaranteed non-NULL whenever 
from_encoding != NULL
+               char_u *converted = convert_string(str, from_encoding_raw, 
p_enc);
                vim_free(str);
                str = converted;
            }
diff --git a/src/version.c b/src/version.c
index 12365dc35..2c6404fb0 100644
--- a/src/version.c
+++ b/src/version.c
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    5,
 /**/
     4,
 /**/

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/vim_dev/E1vrem1-00DgUK-Ad%40256bit.org.

Raspunde prin e-mail lui