]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
libcpp: fix typos in iconv_close [PR124930]
authorMarek Polacek <polacek@redhat.com>
Mon, 20 Apr 2026 22:01:28 +0000 (18:01 -0400)
committerMarek Polacek <polacek@redhat.com>
Tue, 21 Apr 2026 14:06:12 +0000 (10:06 -0400)
This patch fixes two typos: the reverse_ prefix is missing in the
iconv_close calls.

PR preprocessor/124930

libcpp/ChangeLog:

* charset.cc (_cpp_destroy_iconv): Correct two calls to
iconv_close.

Reviewed-by: Jakub Jelinek <jakub@redhat.com>
libcpp/charset.cc

index f07052087a8da4233c0aff79b8a6dfe011006a4a..563b7c55f7965a0fbdd7a45b4b87ed6a1064ee90 100644 (file)
@@ -841,9 +841,9 @@ _cpp_destroy_iconv (cpp_reader *pfile)
       if (pfile->wide_cset_desc.func == convert_using_iconv)
        iconv_close (pfile->wide_cset_desc.cd);
       if (pfile->reverse_narrow_cset_desc.func == convert_using_iconv)
-       iconv_close (pfile->narrow_cset_desc.cd);
+       iconv_close (pfile->reverse_narrow_cset_desc.cd);
       if (pfile->reverse_utf8_cset_desc.func == convert_using_iconv)
-       iconv_close (pfile->utf8_cset_desc.cd);
+       iconv_close (pfile->reverse_utf8_cset_desc.cd);
     }
 }