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>2010-10-23 20:03:31 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-10-23 20:03:31 +0400
commit2d9be2226a7b8ec35f3055743f3d6e381fe78757 (patch)
treed3103047e0822c31cfd06b059317c98a12a3dc6d /source/blender
parent05b297c52f025b8d2068b742d944ecd92c402256 (diff)
warning fixes.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenkernel/intern/constraint.c1
-rw-r--r--source/blender/editors/object/object_constraint.c5
-rw-r--r--source/blender/editors/space_script/script_edit.c4
-rw-r--r--source/blender/editors/space_text/text_ops.c2
-rw-r--r--source/blender/editors/space_view3d/view3d_draw.c2
-rw-r--r--source/blender/modifiers/CMakeLists.txt2
-rw-r--r--source/blender/render/intern/raytrace/rayobject.cpp6
-rw-r--r--source/blender/windowmanager/intern/wm_init_exit.c5
8 files changed, 22 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c
index 5dad01a126f..c3f05e497f1 100644
--- a/source/blender/blenkernel/intern/constraint.c
+++ b/source/blender/blenkernel/intern/constraint.c
@@ -2015,6 +2015,7 @@ static void pycon_get_tarmat (bConstraint *con, bConstraintOb *cob, bConstraintT
static void pycon_evaluate (bConstraint *con, bConstraintOb *cob, ListBase *targets)
{
#ifdef DISABLE_PYTHON
+ (void)con; (void)cob; (void)targets; /* unused */
return;
#else
bPythonConstraint *data= con->data;
diff --git a/source/blender/editors/object/object_constraint.c b/source/blender/editors/object/object_constraint.c
index 02c88d4149b..09760a8f51b 100644
--- a/source/blender/editors/object/object_constraint.c
+++ b/source/blender/editors/object/object_constraint.c
@@ -200,7 +200,10 @@ char *buildmenu_pyconstraints (Text *con_text, int *pyconindex)
/* this callback gets called when the 'refresh' button of a pyconstraint gets pressed */
void update_pyconstraint_cb (void *arg1, void *arg2)
{
-#ifndef DISABLE_PYTHON
+#ifdef DISABLE_PYTHON
+ (void)arg1; /* unused */
+ (void)arg2; /* unused */
+#else
Object *owner= (Object *)arg1;
bConstraint *con= (bConstraint *)arg2;
if (owner && con)
diff --git a/source/blender/editors/space_script/script_edit.c b/source/blender/editors/space_script/script_edit.c
index 7e3b14ca04a..23bc385c758 100644
--- a/source/blender/editors/space_script/script_edit.c
+++ b/source/blender/editors/space_script/script_edit.c
@@ -60,6 +60,8 @@ static int run_pyfile_exec(bContext *C, wmOperator *op)
ED_region_tag_redraw(ar);
return OPERATOR_FINISHED;
}
+#else
+ (void)C; /* unused */
#endif
return OPERATOR_CANCELLED; /* FAIL */
}
@@ -89,6 +91,8 @@ static int script_reload_exec(bContext *C, wmOperator *UNUSED(op))
BPY_eval_string(C, "__import__('bpy').utils.load_scripts(reload_scripts=True)");
WM_cursor_wait(0);
return OPERATOR_FINISHED;
+#else
+ (void)C; /* unused */
#endif
return OPERATOR_CANCELLED;
}
diff --git a/source/blender/editors/space_text/text_ops.c b/source/blender/editors/space_text/text_ops.c
index 8d4f3f87f66..af29e575482 100644
--- a/source/blender/editors/space_text/text_ops.c
+++ b/source/blender/editors/space_text/text_ops.c
@@ -558,6 +558,8 @@ static int run_script_poll(bContext *C)
static int run_script_exec(bContext *C, wmOperator *op)
{
#ifdef DISABLE_PYTHON
+ (void)C; /* unused */
+
BKE_report(op->reports, RPT_ERROR, "Python disabled in this build");
return OPERATOR_CANCELLED;
diff --git a/source/blender/editors/space_view3d/view3d_draw.c b/source/blender/editors/space_view3d/view3d_draw.c
index 7722ca5605b..30880db0c90 100644
--- a/source/blender/editors/space_view3d/view3d_draw.c
+++ b/source/blender/editors/space_view3d/view3d_draw.c
@@ -1459,7 +1459,7 @@ static void draw_dupli_objects_color(Scene *scene, ARegion *ar, View3D *v3d, Bas
{
RegionView3D *rv3d= ar->regiondata;
ListBase *lb;
- DupliObject *dob_prev= NULL, *dob, *dob_next;
+ DupliObject *dob_prev= NULL, *dob, *dob_next= NULL;
Base tbase;
BoundBox bb, *bb_tmp; /* use a copy because draw_object, calls clear_mesh_caches */
GLuint displist=0;
diff --git a/source/blender/modifiers/CMakeLists.txt b/source/blender/modifiers/CMakeLists.txt
index 40f0ad127cd..7524244c701 100644
--- a/source/blender/modifiers/CMakeLists.txt
+++ b/source/blender/modifiers/CMakeLists.txt
@@ -85,7 +85,7 @@ ENDIF(WITH_MOD_BOOLEAN)
IF(WITH_MOD_DECIMATE)
ADD_DEFINITIONS(-DWITH_MOD_DECIMATE)
LIST(APPEND INC ../../../intern/decimation/extern)
-ENDIF(WITH_MOD_BOOLEAN)
+ENDIF(WITH_MOD_DECIMATE)
IF(NOT WITH_MOD_FLUID)
ADD_DEFINITIONS(-DDISABLE_ELBEEM)
diff --git a/source/blender/render/intern/raytrace/rayobject.cpp b/source/blender/render/intern/raytrace/rayobject.cpp
index 84ec56e131a..119a62ad05a 100644
--- a/source/blender/render/intern/raytrace/rayobject.cpp
+++ b/source/blender/render/intern/raytrace/rayobject.cpp
@@ -533,7 +533,11 @@ float RE_rayobject_cost(RayObject *r)
r = RE_rayobject_align( r );
return r->api->cost( r );
}
- else assert(0);
+ else
+ {
+ assert(0);
+ return 1.0; /* XXX, better default value? */
+ }
}
void RE_rayobject_hint_bb(RayObject *r, RayHint *hint, float *min, float *max)
diff --git a/source/blender/windowmanager/intern/wm_init_exit.c b/source/blender/windowmanager/intern/wm_init_exit.c
index b319058ce5c..e373579577d 100644
--- a/source/blender/windowmanager/intern/wm_init_exit.c
+++ b/source/blender/windowmanager/intern/wm_init_exit.c
@@ -145,6 +145,9 @@ void WM_init(bContext *C, int argc, char **argv)
BPY_set_context(C); /* necessary evil */
BPY_start_python(argc, argv);
BPY_load_user_modules(C);
+#else
+ (void)argc; /* unused */
+ (void)argv; /* unused */
#endif
wm_init_reports(C); /* reports cant be initialized before the wm */
@@ -212,7 +215,7 @@ int WM_init_game(bContext *C)
wmWindow* win;
ScrArea *sa;
- ARegion *ar;
+ ARegion *ar= NULL;
Scene *scene= CTX_data_scene(C);