mirror of
https://git.freebsd.org/ports.git
synced 2025-04-28 01:26:39 -04:00
textproc/sdcv: Fix build with newer glib20
PR: 281083
This commit is contained in:
parent
55bddb6f7c
commit
c0b1343ec0
2 changed files with 20 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
||||||
PORTNAME= sdcv
|
PORTNAME= sdcv
|
||||||
DISTVERSIONPREFIX= v
|
DISTVERSIONPREFIX= v
|
||||||
DISTVERSION= 0.5.5
|
DISTVERSION= 0.5.5
|
||||||
|
PORTREVISION= 1
|
||||||
CATEGORIES= textproc
|
CATEGORIES= textproc
|
||||||
|
|
||||||
MAINTAINER= citrin@citrin.ru
|
MAINTAINER= citrin@citrin.ru
|
||||||
|
|
19
textproc/sdcv/files/patch-src_stardict__lib.cpp
Normal file
19
textproc/sdcv/files/patch-src_stardict__lib.cpp
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
--- src/stardict_lib.cpp.orig 2023-04-18 18:47:55 UTC
|
||||||
|
+++ src/stardict_lib.cpp
|
||||||
|
@@ -1047,12 +1047,12 @@ bool Libs::LookupSimilarWord(const gchar *sWord, std::
|
||||||
|
}
|
||||||
|
// Upper the first character and lower others.
|
||||||
|
if (!bFound) {
|
||||||
|
- gchar *nextchar = g_utf8_next_char(sWord);
|
||||||
|
+ const gchar *nextchar = g_utf8_next_char(sWord);
|
||||||
|
gchar *firstchar = g_utf8_strup(sWord, nextchar - sWord);
|
||||||
|
- nextchar = g_utf8_strdown(nextchar, -1);
|
||||||
|
- casestr = g_strdup_printf("%s%s", firstchar, nextchar);
|
||||||
|
+ gchar *nextDownchar = g_utf8_strdown(nextchar, -1);
|
||||||
|
+ casestr = g_strdup_printf("%s%s", firstchar, nextDownchar);
|
||||||
|
g_free(firstchar);
|
||||||
|
- g_free(nextchar);
|
||||||
|
+ g_free(nextDownchar);
|
||||||
|
if (strcmp(casestr, sWord)) {
|
||||||
|
if (oLib[iLib]->Lookup(casestr, iWordIndices))
|
||||||
|
bFound = true;
|
Loading…
Add table
Reference in a new issue