diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-08-28 06:14:24 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-08-28 06:14:24 +0400 |
commit | 9e561a641ecd8db55a7bb67abe961b4f2eb1734d (patch) | |
tree | 6019a8e853243b65c7fc1df31360d1968874f1cd /source/blender/blenlib/intern/scanfill.c | |
parent | 27df6a3b546bf4188b0f29bcb90df201a6730574 (diff) |
remove callback BLI_localErrorCallBack from scanfill, was here for years and only ever wrapped printf.
Diffstat (limited to 'source/blender/blenlib/intern/scanfill.c')
-rw-r--r-- | source/blender/blenlib/intern/scanfill.c | 39 |
1 files changed, 3 insertions, 36 deletions
diff --git a/source/blender/blenlib/intern/scanfill.c b/source/blender/blenlib/intern/scanfill.c index ae9f36b957c..39d1378afdd 100644 --- a/source/blender/blenlib/intern/scanfill.c +++ b/source/blender/blenlib/intern/scanfill.c @@ -44,41 +44,6 @@ #include "BLI_scanfill.h" #include "BLI_utildefines.h" -/* callbacks for errors and interrupts and some goo */ -static void (*BLI_localErrorCallBack)(const char *) = NULL; - -/** - * Set a function taking a (char *) as argument to flag errors. If the - * callback is not set, the error is discarded. - * \param f The function to use as callback - * \attention used in creator.c - */ -void BLI_setErrorCallBack(void (*f)(const char *)) -{ - BLI_localErrorCallBack = f; -} - -/* just flush the error to /dev/null if the error handler is missing */ -void callLocalErrorCallBack(const char *msg) -{ - if (BLI_localErrorCallBack) { - BLI_localErrorCallBack(msg); - } -} - -#if 0 -/* ignore if the interrupt wasn't set */ -static int callLocalInterruptCallBack(void) -{ - if (BLI_localInterruptCallBack) { - return BLI_localInterruptCallBack(); - } - else { - return 0; - } -} -#endif - /* local types */ typedef struct PolyFill { int edges, verts; @@ -989,7 +954,9 @@ int BLI_scanfill_calc_ex(ScanFillContext *sf_ctx, const int flag, const float no } if (eed) { /* otherwise it's impossible to be sure you can clear vertices */ - callLocalErrorCallBack("No vertices with 250 edges allowed!"); +#ifdef DEBUG + printf("No vertices with 250 edges allowed!\n"); +#endif return 0; } |