Skip to content

Commit

Permalink
patch 9.0.1815: pango_coverage_unref() deprecated in pango > 1.51
Browse files Browse the repository at this point in the history
Problem:  pango_coverage_unref() deprecated in pango > 1.51
Solution: use g_object_unref() instead

closes: #12942

Free PangoCoverage with g_object_unref for Pango >= 1.52

pango_coverage_unref was declared deprecated in Pango 1.52.0 in favor of
g_object_unref.  Adjust the call when building against a new enough
Pango to avoid the deprecation warning.

Signed-off-by: James McCoy <jamessan@jamessan.com>
Co-authored-by: James McCoy <jamessan@jamessan.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
  • Loading branch information
jamessan authored and chrisbra committed Aug 28, 2023
1 parent 2ba9d2e commit fe14636
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/gui_gtk_x11.c
Original file line number Diff line number Diff line change
Expand Up @@ -4845,7 +4845,11 @@ is_cjk_font(PangoFontDescription *font_desc)
{
uc = (cjk_langs[i][0] == 'k') ? 0xAC00 : 0x4E00;
is_cjk = (pango_coverage_get(coverage, uc) == PANGO_COVERAGE_EXACT);
#if PANGO_VERSION_CHECK(1, 52, 0)
g_object_unref(coverage);
#else
pango_coverage_unref(coverage);
#endif
}
}

Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -699,6 +699,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1815,
/**/
1814,
/**/
Expand Down

0 comments on commit fe14636

Please sign in to comment.