File: fix-format-not-a-string-literal-error.patch

package info (click to toggle)
vodovod 1.10-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid, trixie
  • size: 1,040 kB
  • sloc: cpp: 2,821; ansic: 236; makefile: 28
file content (30 lines) | stat: -rw-r--r-- 1,070 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
From: Markus Koschany <apo@debian.org>
Date: Tue, 5 Mar 2013 01:24:33 +0100
Subject: fix format not a string literal error

---
 njamfont.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/njamfont.cpp b/njamfont.cpp
index 0948a1a..d72d828 100644
--- a/njamfont.cpp
+++ b/njamfont.cpp
@@ -37,7 +37,7 @@ NjamFont::NjamFont(const char *Filename, int CharWidth, int CharHeight)
     if (!temp)
     {
         printf("FAILED.\n");
-        printf((const char *)SDL_GetError());
+        printf((const char *)SDL_GetError(),"%s");
         return;
     }
     printf("OK.\n");
@@ -133,7 +133,7 @@ bool NjamFont::WriteTextXY(SDL_Surface *Destination, int x, int y, const char *T
                 if (0 != SDL_BlitSurface(m_Surface, &src, Destination, &dest))
                 {
                     printf("Failed to blit font character image.\n");
-                    printf((const char *)SDL_GetError());
+                    printf((const char *)SDL_GetError(),"%s");
                     return false;
                 }
                 break;