]> git.pld-linux.org Git - packages/xephem.git/commitdiff
- fix building with -Werror=format-security auto/th/xephem-3.7.4-4
authorKacper Kornet <draenog@pld-linux.org>
Mon, 4 Nov 2013 22:05:31 +0000 (22:05 +0000)
committerKacper Kornet <draenog@pld-linux.org>
Mon, 4 Nov 2013 22:05:31 +0000 (22:05 +0000)
xephem-format.patch [new file with mode: 0644]
xephem.spec

diff --git a/xephem-format.patch b/xephem-format.patch
new file mode 100644 (file)
index 0000000..2cfdb64
--- /dev/null
@@ -0,0 +1,52 @@
+diff --git a/GUI/xephem/compiler.c b/GUI/xephem/compiler.c
+index 63a0065..16bf565 100644
+--- a/GUI/xephem/compiler.c
++++ b/GUI/xephem/compiler.c
+@@ -208,7 +208,7 @@ next_token ()
+ {
+       static char toomv[] = "More than %d variables";
+       static char toomc[] = "More than %d constants";
+-      static char badop[] = "Illegal operator";
++      static const char badop[] = "Illegal operator";
+       int tok = ERR;  /* just something illegal */
+       char c;
+diff --git a/GUI/xephem/obslog.c b/GUI/xephem/obslog.c
+index e3912e2..7deb5a6 100644
+--- a/GUI/xephem/obslog.c
++++ b/GUI/xephem/obslog.c
+@@ -915,7 +915,7 @@ ol_writeLB()
+       fprintf (fp, "    </%s>\n", lbetag);
+       /* finished */
+-      fprintf (fp, cltag);
++      fprintf (fp, "%s", cltag);
+       xe_msg (1, "Added new log entry");
+       fclose (fp);
+ }
+diff --git a/GUI/xephem/tools/indi/compiler.c b/GUI/xephem/tools/indi/compiler.c
+index 2e16d93..736f2a1 100644
+--- a/GUI/xephem/tools/indi/compiler.c
++++ b/GUI/xephem/tools/indi/compiler.c
+@@ -268,7 +268,7 @@ next_token ()
+ {
+       static char toomv[] = "More than %d variables";
+       static char toomc[] = "More than %d constants";
+-      static char badop[] = "Illegal operator";
++      static const char badop[] = "Illegal operator";
+       int tok = ERR;  /* just something illegal */
+       char c;
+diff --git a/GUI/xephem/tools/lx200xed/lx200xed.c b/GUI/xephem/tools/lx200xed/lx200xed.c
+index 34bdb33..4c6e5b0 100644
+--- a/GUI/xephem/tools/lx200xed/lx200xed.c
++++ b/GUI/xephem/tools/lx200xed/lx200xed.c
+@@ -657,7 +657,7 @@ trace(int iLevel, char *szpFormat, char *szpArg)
+ {
+    if(iLevel<=config.iTrace) {
+       if(szpArg==NULL)
+-      printf(szpFormat);
++      printf("%s", szpFormat);
+       else
+       printf(szpFormat,szpArg);
+    }
index 47b0a1d1127adc44ff4daf4afc142ff721230958..582359dc6850bd24aafce981534e9830b6f8d2a9 100644 (file)
@@ -8,7 +8,7 @@ Summary:        Interactive astronomy program
 Summary(pl.UTF-8):     Interaktywny program astronomiczny
 Name:          xephem
 Version:       3.7.4
-Release:       3
+Release:       4
 License:       distributable with free-unices distros, free for non-profit non-commercial purposes
 Group:         X11/Applications/Science
 Source0:       http://97.74.56.125/free/%{name}-%{version}.tar.gz
@@ -17,6 +17,7 @@ Source1:      %{name}.desktop
 Source2:       %{name}.png
 Source3:       %{name}_sites
 Patch0:                %{name}-makefile.patch
+Patch1:                %{name}-format.patch
 URL:           http://www.clearskyinstitute.com/xephem/
 BuildRequires: groff
 BuildRequires: libpng-devel
@@ -68,6 +69,7 @@ XEphemdbd - filtr do odnajdywania obiektów astronomicznych wg zadanych
 %prep
 %setup -q
 %patch0 -p1
+%patch1 -p1
 
 sed -i "s#X11R6/lib#X11R6/%{_lib}#g" GUI/xephem/Makefile
 sed -i "s#/usr/local#%{_datadir}#g" GUI/xephem/tools/xephemdbd/start-xephemdbd.pl
This page took 0.140074 seconds and 4 git commands to generate.