From d2c49fa407eaed3ac5cabe20800e307a8393327d Mon Sep 17 00:00:00 2001 From: Than Ngo Date: Thu, 28 Jul 2022 10:29:24 +0200 Subject: [PATCH] Fixed FTBFS, error: format not a string literal --- ppc64-diag-gcc12.patch | 30 ++++++++++++++++++++++++++++++ ppc64-diag.spec | 6 +++++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 ppc64-diag-gcc12.patch diff --git a/ppc64-diag-gcc12.patch b/ppc64-diag-gcc12.patch new file mode 100644 index 0000000..a3f00c6 --- /dev/null +++ b/ppc64-diag-gcc12.patch @@ -0,0 +1,30 @@ +diff --git a/lpd/lp_diag.c b/lpd/lp_diag.c +index 8dd92e6..988a021 100644 +--- a/lpd/lp_diag.c ++++ b/lpd/lp_diag.c +@@ -653,11 +653,11 @@ UI_help(MENU *my_menu) + } + + if (!strcmp(desc, "ident")) +- mvwprintw(my_text_win, 0, 0, help1); ++ mvwprintw(my_text_win, 0, 0, "%s", help1); + else if (!strcmp(desc, "attn")) +- mvwprintw(my_text_win, 0, 0, help2); ++ mvwprintw(my_text_win, 0, 0, "%s", help2); + else +- mvwprintw(my_text_win, 0, 0, help3); ++ mvwprintw(my_text_win, 0, 0, "%s", help3); + + wrefresh(my_text_win); + +@@ -1127,8 +1127,8 @@ startup_window(void) + } + + mvprintw(0, 0, "SERVICE INDICATORS VERSION %s", VERSION); +- mvprintw(2, 0, msg1); +- mvprintw(5, 0, msg2); ++ mvprintw(2, 0, "%s", msg1); ++ mvprintw(5, 0, "%s", msg2); + mvprintw(9, 0, "Press the F3 key to exit or press Enter to continue."); + + while ((c = getch()) != KEY_F(3)) { diff --git a/ppc64-diag.spec b/ppc64-diag.spec index 8a97c50..e6effb3 100644 --- a/ppc64-diag.spec +++ b/ppc64-diag.spec @@ -1,6 +1,6 @@ Name: ppc64-diag Version: 2.7.8 -Release: 3%{?dist} +Release: 4%{?dist} Summary: PowerLinux Platform Diagnostics URL: https://github.com/power-ras/%{name} License: GPLv2 @@ -34,6 +34,7 @@ Source5: rtas_errd.8 # fix paths and permissions Patch0: ppc64-diag-fedora.patch Patch1: ppc64-diag-2.7.8-opal-dump-parse-getopt.patch +Patch2: ppc64-diag-gcc12.patch %description This package contains various diagnostic tools for PowerLinux. @@ -168,6 +169,9 @@ if [ "$1" = "0" ]; then # last uninstall fi %changelog +* Thu Jul 28 2022 Than Ngo - 2.7.8-4 +- Fixed FTBFS, error: format not a string literal + * Fri Jul 22 2022 Fedora Release Engineering - 2.7.8-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild