Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrea Weikert <elubie@gmx.net>2007-03-19 22:34:04 +0300
committerAndrea Weikert <elubie@gmx.net>2007-03-19 22:34:04 +0300
commit7f2d1f651ca77e472a7b66b8c0eb8dbffe94ff34 (patch)
tree52592236942e5b65ba2a945e644737d262031919 /source/blender/blenlib/BLI_blenlib.h
parent261120236b1c07d6c17d210f9012fb85bafe5497 (diff)
==== blenlib ====
- added replacement BLI_snprintf for snprintf to avoid MSVC specific #defines for snprintf. - BLI_snprintf also ensures trailing zero, so helps preventing buffer overflows
Diffstat (limited to 'source/blender/blenlib/BLI_blenlib.h')
-rw-r--r--source/blender/blenlib/BLI_blenlib.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/blenlib/BLI_blenlib.h b/source/blender/blenlib/BLI_blenlib.h
index 7b60aa178a7..464b851413f 100644
--- a/source/blender/blenlib/BLI_blenlib.h
+++ b/source/blender/blenlib/BLI_blenlib.h
@@ -69,6 +69,8 @@
because fillfacebase and fillvertbase are used outside */
#include "DNA_listBase.h"
+#include <stdlib.h>
+
extern ListBase fillfacebase;
extern ListBase fillvertbase;
/**
@@ -196,6 +198,11 @@ char* BLI_strdupn(char *str, int len);
*/
char* BLI_strncpy(char *dst, const char *src, int maxncpy);
+ /*
+ * Replacement for snprintf
+ */
+int BLI_snprintf(char *buffer, size_t count, const char *format, ...);
+
/**
* Compare two strings
*