local synctex change: _synctex_error has a printf-like format, so use the proper gcc extensions to check its arguments (doing nothing for other compilers)
add the change as local patch 04-gcc-specify-printf-format.diff svn path=/trunk/KDE/kdegraphics/okular/; revision=1003104remotes/origin/KDE/4.4
parent
bdfcd6e337
commit
fe8ab0045e
3 changed files with 34 additions and 1 deletions
@ -0,0 +1,26 @@ |
||||
Index: synctex/synctex_parser_utils.h
|
||||
===================================================================
|
||||
--- synctex.orig/synctex_parser_utils.h 2009-07-27 19:10:23.000000000 +0200
|
||||
+++ synctex/synctex_parser_utils.h 2009-07-27 19:13:43.000000000 +0200
|
||||
@@ -58,6 +58,12 @@
|
||||
# define SYNCTEX_IS_PATH_SEPARATOR(c) ('/' == c)
|
||||
# endif
|
||||
|
||||
+# ifdef __GNUC__
|
||||
+# define SYNCTEX_PRINTF_FORMAT(si, ftc) __attribute__ ((format (printf, si, ftc)))
|
||||
+# else
|
||||
+# define SYNCTEX_PRINTF_FORMAT(si, ftc)
|
||||
+# endif
|
||||
+
|
||||
/* This custom malloc functions initializes to 0 the newly allocated memory.
|
||||
* There is no bzero function on windows. */
|
||||
void *_synctex_malloc(size_t size);
|
||||
@@ -65,7 +71,7 @@
|
||||
/* This is used to log some informational message to the standard error stream.
|
||||
* On Windows, the stderr stream is not exposed and another method is used.
|
||||
* The return value is the number of characters printed. */
|
||||
-int _synctex_error(const char * reason,...);
|
||||
+int _synctex_error(const char * reason,...) SYNCTEX_PRINTF_FORMAT(1, 2);
|
||||
|
||||
/* strip the last extension of the given string, this string is modified!
|
||||
* This function depends on the OS because the path separator may differ.
|
||||
@ -1,3 +1,4 @@ |
||||
01-fix-win32-define.diff |
||||
02-fix-_synctex_error.diff |
||||
03-fix-_synctex_scan_named.diff |
||||
04-gcc-specify-printf-format.diff |
||||
|
||||
Loading…
Reference in new issue