[gnome-software/localize-strings: 3/3] Use g_snprintf
- From: Jordi Mas <jmas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/localize-strings: 3/3] Use g_snprintf
- Date: Fri, 24 May 2019 19:10:35 +0000 (UTC)
commit 56761f6786655e7d2144a9335664b83cc0051c8c
Merge: a6f54fbf f963b9a6
Author: Jordi Mas <jmas softcatala org>
Date: Fri May 24 21:10:02 2019 +0200
Use g_snprintf
.gitlab-ci.yml | 7 +-
plugins/snap/gs-plugin-snap.c | 32 +++
po/ca.po | 522 +++++++++++++++++++++---------------------
src/gs-common.c | 28 +++
src/gs-common.h | 1 +
src/gs-content-rating.c | 4 +-
src/gs-page.c | 7 +
src/gs-updates-section.c | 14 +-
8 files changed, 335 insertions(+), 280 deletions(-)
---
diff --cc src/gs-content-rating.c
index 609b73ce,609b73ce..6c563f90
--- a/src/gs-content-rating.c
+++ b/src/gs-content-rating.c
@@@ -358,7 -358,7 +358,7 @@@ gs_content_rating_key_value_to_str (con
return NULL;
}
--static gchar translated[128][5];
++static gchar translated[6][128];
static const char* get_esrb_string(gchar* output, gchar* source, gchar* translate) {
@@@ -366,7 -366,7 +366,7 @@@
if (equal == 0)
return source;
-- g_sprintf (output, _("%s (%s)"), source, translate);
++ g_snprintf (output, sizeof(translated[0]), _("%s (%s)"), source, translate);
return output;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]