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:
authorCampbell Barton <ideasman42@gmail.com>2015-06-17 08:53:35 +0300
committerCampbell Barton <ideasman42@gmail.com>2015-06-17 08:53:35 +0300
commit5b833de521f26c6f4af2e852ccf420f3661fb02a (patch)
tree8ff848ff532d8655fc4e9921d920a7007cb877a6 /source/blender/imbuf/intern/writeimage.c
parentc03dcc5421e2115ad48d0d407dd57a50a30793a1 (diff)
ImBuf: Assert when read/write gets relative paths
We _never_ want this, so better not fail silently.
Diffstat (limited to 'source/blender/imbuf/intern/writeimage.c')
-rw-r--r--source/blender/imbuf/intern/writeimage.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/imbuf/intern/writeimage.c b/source/blender/imbuf/intern/writeimage.c
index 2f688803804..28710fba823 100644
--- a/source/blender/imbuf/intern/writeimage.c
+++ b/source/blender/imbuf/intern/writeimage.c
@@ -33,6 +33,10 @@
#include <stdio.h>
+#include <stdlib.h>
+
+#include "BLI_utildefines.h"
+#include "BLI_path_util.h"
#include "IMB_imbuf_types.h"
#include "IMB_imbuf.h"
@@ -50,6 +54,8 @@ short IMB_saveiff(struct ImBuf *ibuf, const char *name, int flags)
{
const ImFileType *type;
+ BLI_assert(!BLI_path_is_rel(name));
+
if (ibuf == NULL) return (false);
ibuf->flags = flags;