]> git.pld-linux.org Git - packages/NuSMV.git/commitdiff
- fix building with -Wformat-security
authorJan Rękorajski <baggins@pld-linux.org>
Wed, 14 Nov 2012 14:03:47 +0000 (15:03 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Wed, 14 Nov 2012 14:03:47 +0000 (15:03 +0100)
- rel 3

NuSMV.spec
format-security.patch [new file with mode: 0644]

index 2fa8b68f7a77b7accd3cc1cb42b4176a3085e112..210aa5cce7bf0660ea6ef1110bace27e1227a063 100644 (file)
@@ -9,7 +9,7 @@ Summary:        New Symbolic Model Verifier
 Summary(pl.UTF-8):     Nowy weryfikator modeli symbolicznych
 Name:          NuSMV
 Version:       2.5.4
-Release:       2
+Release:       3
 License:       LGPL
 Group:         Applications
 Source0:       http://nusmv.irst.itc.it/distrib/%{name}-%{version}.tar.gz
@@ -20,6 +20,7 @@ Source2:      http://www.princeton.edu/~chaff/zchaff/zchaff.%{zchaff_ver}.zip
 # Source2-md5: 7398b3e984a5046755cb3ef6b0e44d2e
 Patch0:                %{name}-build.patch
 Patch1:                %{name}-solvers.patch
+Patch2:                format-security.patch
 URL:           http://nusmv.irst.itc.it/
 BuildRequires: autoconf
 BuildRequires: automake
@@ -103,6 +104,7 @@ install %{SOURCE1} MiniSat/
 install %{SOURCE2} zchaff/
 
 %patch1 -p1
+%patch2 -p1
 
 %build
 ICFLAGS="%{rpmcflags} -fPIC"
diff --git a/format-security.patch b/format-security.patch
new file mode 100644 (file)
index 0000000..d48a2d6
--- /dev/null
@@ -0,0 +1,62 @@
+--- NuSMV-2.5.4/nusmv/src/prop/Prop.c~ 2011-10-21 17:41:39.000000000 +0200
++++ NuSMV-2.5.4/nusmv/src/prop/Prop.c  2012-11-14 14:47:55.753785880 +0100
+@@ -1634,7 +1634,7 @@
+   }
+   indent(file);
+-  fprintf(file, prop);
++  fputs(prop, file);
+   if (len > 40) {
+     fprintf(file, " [...]");
+--- NuSMV-2.5.4/nusmv/src/cinit/cinitData.c~   2011-10-12 11:04:37.000000000 +0200
++++ NuSMV-2.5.4/nusmv/src/cinit/cinitData.c    2012-11-14 14:50:21.413780736 +0100
+@@ -439,7 +439,7 @@
+     else {
+       const char* preps_fmt = "Warning: there are no available preprocessors";
+       preps_tmp = ALLOC(char, strlen(preps_fmt) + 1);
+-      sprintf(preps_tmp, preps_fmt);
++      sprintf(preps_tmp, "%s", preps_fmt);
+     }
+     tmp = ALLOC(char, strlen(fmt) + strlen(preps_tmp) + 1);
+--- NuSMV-2.5.4/nusmv/src/hrc/dumpers/HrcDumper_private.h~     2011-10-12 11:04:37.000000000 +0200
++++ NuSMV-2.5.4/nusmv/src/hrc/dumpers/HrcDumper_private.h      2012-11-14 14:57:59.607097908 +0100
+@@ -106,13 +106,13 @@
+ #define _HRC_DUMP_STR(x)          \
+   {                               \
+     hrc_dumper_dump_indent(self); \
+-    fprintf(self->fout, x);       \
++    fputs(x, self->fout);       \
+   }
+ #define _HRC_DUMP_STR_NL(x)                                           \
+   {                                                                   \
+     hrc_dumper_dump_indent(self);                                     \
+-    fprintf(self->fout, x);                                           \
++    fputs(x, self->fout);                                           \
+     hrc_dumper_nl(self);                                              \
+   }
+--- NuSMV-2.5.4/nusmv/src/hrc/dumpers/HrcDumperXml_private.h~  2011-10-12 11:04:37.000000000 +0200
++++ NuSMV-2.5.4/nusmv/src/hrc/dumpers/HrcDumperXml_private.h   2012-11-14 14:59:17.827095149 +0100
+@@ -92,7 +92,7 @@
+ #define _HRC_DUMP_STR_NL(x)                                           \
+   {                                                                   \
+     hrc_dumper_dump_indent(self);                                     \
+-    fprintf(self->fout, x);                                           \
++    fputs(x, self->fout);                                           \
+     if (self->use_indentation) {                                      \
+       hrc_dumper_nl(self);                                            \
+     }                                                                 \
+--- NuSMV-2.5.4/nusmv/src/addons_core/compass/sigref/sigrefWrite.c~    2011-10-12 11:04:36.000000000 +0200
++++ NuSMV-2.5.4/nusmv/src/addons_core/compass/sigref/sigrefWrite.c     2012-11-14 15:00:08.280426703 +0100
+@@ -509,7 +509,7 @@
+   DdManager* dd = BddEnc_get_dd_manager(enc);
+-  fprintf(file, SIGREF_HEADER);
++  fprintf(file, "%s", SIGREF_HEADER);
+   fprintf(file, "\n<%s ", MODEL_TAG);
+   fprintf(file, MODEL_FM, MODEL_TYPE);
+   fprintf(file, ">\n");
This page took 0.065349 seconds and 4 git commands to generate.