games-board/mt_ncurses_client: Fix compile with -Wformat-security. Bug #546406
authorTupone Alfredo <tupone@gentoo.org>
Wed, 21 Oct 2015 12:30:09 +0000 (14:30 +0200)
committerTupone Alfredo <tupone@gentoo.org>
Wed, 21 Oct 2015 12:31:07 +0000 (14:31 +0200)
Package-Manager: portage-2.2.20.1

games-board/mt_ncurses_client/files/mt_ncurses_client-0.1.98-format.patch [new file with mode: 0644]
games-board/mt_ncurses_client/mt_ncurses_client-0.1.98.ebuild

diff --git a/games-board/mt_ncurses_client/files/mt_ncurses_client-0.1.98-format.patch b/games-board/mt_ncurses_client/files/mt_ncurses_client-0.1.98-format.patch
new file mode 100644 (file)
index 0000000..e070a23
--- /dev/null
@@ -0,0 +1,11 @@
+--- src/player_client.c.old    2015-10-21 14:21:04.317896103 +0200
++++ src/player_client.c        2015-10-21 14:21:40.001225103 +0200
+@@ -38,7 +38,7 @@
+ {
+   player->nick[0] = g_string_new (config->player_name->str);
+-  g_printerr (player->nick[0]->str);
++  g_printerr ("%s", player->nick[0]->str);
+   return 0;
+ }
index 6341f8c3fd2e4e4bdcdb6912138f3c1bea89c79f..a92f4356a2e134492ee9ffff3825a1562ef0c39f 100644 (file)
@@ -3,7 +3,7 @@
 # $Id$
 
 EAPI=5
-inherit games
+inherit games eutils
 
 DESCRIPTION="client for the french tarot game maitretarot"
 HOMEPAGE="http://www.nongnu.org/maitretarot/"
@@ -21,6 +21,10 @@ DEPEND="dev-libs/glib:2
        sys-libs/ncurses"
 RDEPEND=${DEPEND}
 
+src_prepare() {
+       epatch "${FILESDIR}"/${P}-format.patch
+}
+
 src_install() {
        default
        prepgamesdirs