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:
-rw-r--r--intern/opensubdiv/internal/evaluator/gl_compute_evaluator.cc4
-rw-r--r--source/blender/blenloader/intern/blend_validate.c15
-rw-r--r--source/blender/draw/intern/draw_cache_impl_subdivision.cc4
3 files changed, 19 insertions, 4 deletions
diff --git a/intern/opensubdiv/internal/evaluator/gl_compute_evaluator.cc b/intern/opensubdiv/internal/evaluator/gl_compute_evaluator.cc
index ee4eaeaec5d..acf628c7035 100644
--- a/intern/opensubdiv/internal/evaluator/gl_compute_evaluator.cc
+++ b/intern/opensubdiv/internal/evaluator/gl_compute_evaluator.cc
@@ -140,8 +140,8 @@ GLStencilTableSSBO::~GLStencilTableSSBO()
GLComputeEvaluator::GLComputeEvaluator() : _workGroupSize(64), _patchArraysSSBO(0)
{
- memset(&_stencilKernel, 0, sizeof(_stencilKernel));
- memset(&_patchKernel, 0, sizeof(_patchKernel));
+ memset((void *)&_stencilKernel, 0, sizeof(_stencilKernel));
+ memset((void *)&_patchKernel, 0, sizeof(_patchKernel));
}
GLComputeEvaluator::~GLComputeEvaluator()
diff --git a/source/blender/blenloader/intern/blend_validate.c b/source/blender/blenloader/intern/blend_validate.c
index 10150f56098..e1527201e22 100644
--- a/source/blender/blenloader/intern/blend_validate.c
+++ b/source/blender/blenloader/intern/blend_validate.c
@@ -181,5 +181,20 @@ bool BLO_main_validate_shapekeys(Main *bmain, ReportList *reports)
BKE_main_unlock(bmain);
+ /* NOTE: #BKE_id_delete also locks `bmain`, so we need to do this loop outside of the lock here.
+ */
+ LISTBASE_FOREACH_MUTABLE (Key *, shapekey, &bmain->shapekeys) {
+ if (shapekey->from != NULL) {
+ continue;
+ }
+
+ BKE_reportf(reports,
+ RPT_ERROR,
+ "Shapekey %s has an invalid 'from' pointer (%p), it will be deleted",
+ shapekey->id.name,
+ shapekey->from);
+ BKE_id_delete(bmain, shapekey);
+ }
+
return is_valid;
}
diff --git a/source/blender/draw/intern/draw_cache_impl_subdivision.cc b/source/blender/draw/intern/draw_cache_impl_subdivision.cc
index f24500419fd..831b0327d6f 100644
--- a/source/blender/draw/intern/draw_cache_impl_subdivision.cc
+++ b/source/blender/draw/intern/draw_cache_impl_subdivision.cc
@@ -1803,9 +1803,9 @@ static bool draw_subdiv_create_requested_buffers(const Scene *scene,
const float obmat[4][4],
const bool do_final,
const bool do_uvedit,
- const bool UNUSED(use_subsurf_fdots),
+ const bool /*use_subsurf_fdots*/,
const ToolSettings *ts,
- const bool UNUSED(use_hide),
+ const bool /*use_hide*/,
OpenSubdiv_EvaluatorCache *evaluator_cache)
{
SubsurfModifierData *smd = BKE_object_get_last_subsurf_modifier(ob);