From df91bec4b63472d19fcb4de17990b4d6e5078a42 Mon Sep 17 00:00:00 2001 From: Marcin Banasiak Date: Wed, 13 Feb 2013 22:32:12 +0100 Subject: [PATCH] Fix build with -Werror=format-security --- tcsh-format-security.patch | 11 +++++++++++ tcsh.spec | 3 +++ 2 files changed, 14 insertions(+) create mode 100644 tcsh-format-security.patch diff --git a/tcsh-format-security.patch b/tcsh-format-security.patch new file mode 100644 index 0000000..0743798 --- /dev/null +++ b/tcsh-format-security.patch @@ -0,0 +1,11 @@ +--- tcsh-6.18.01/sh.func.c.formatsec 2013-02-13 22:26:11.659476651 +0100 ++++ tcsh-6.18.01/sh.func.c 2013-02-13 22:28:13.118818644 +0100 +@@ -2317,7 +2317,7 @@ setlim(struct limits *lp, int hard, RLIM + if (setrlimit(lp->limconst, &rlim) < 0) { + if ( ( lp->limconst == RLIMIT_LOCKS ) && + ( errno == EINVAL ) ) { +- xprintf(CGETS(15, 5, "cannot set it on the current kernel\n")); ++ xprintf("%s", CGETS(15, 5, "cannot set it on the current kernel\n")); + return(0); + } + # else /* BSDLIMIT */ diff --git a/tcsh.spec b/tcsh.spec index fd83f6c..c8a5aab 100644 --- a/tcsh.spec +++ b/tcsh.spec @@ -31,6 +31,7 @@ Patch2: %{name}-no-timestamp-history.patch Patch3: %{name}-time.patch Patch4: %{name}-rlimit_locks.patch Patch5: %{name}-no_TERMCAP.patch +Patch6: %{name}-format-security.patch URL: http://www.tcsh.org/Home BuildRequires: autoconf >= 2.59 BuildRequires: automake @@ -120,8 +121,10 @@ W tym pakiecie jest statycznie skonsolidowany tcsh. %patch3 -p1 %patch4 -p1 %patch5 -p1 +%patch6 -p1 %build +mkdir m4 cp /usr/share/automake/config.sub . %{__aclocal} %{__autoconf} -- 2.44.0