diff options
Diffstat (limited to 'source/blender/editors/object/object_bake_api.c')
-rw-r--r-- | source/blender/editors/object/object_bake_api.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/object/object_bake_api.c b/source/blender/editors/object/object_bake_api.c index 260d65fc5dc..e69ccf5a50d 100644 --- a/source/blender/editors/object/object_bake_api.c +++ b/source/blender/editors/object/object_bake_api.c @@ -467,8 +467,8 @@ static bool bake_object_check(const Scene *scene, } for (int i = 0; i < ob->totcol; i++) { - bNodeTree *ntree = NULL; - bNode *node = NULL; + const bNodeTree *ntree = NULL; + const bNode *node = NULL; const int mat_nr = i + 1; Image *image; ED_object_get_active_image(ob, mat_nr, &image, NULL, &node, &ntree); @@ -893,7 +893,7 @@ static bool bake_targets_output_external(const BakeAPIRender *bkr, else { /* if everything else fails, use the material index */ char tmp[5]; - sprintf(tmp, "%d", i % 1000); + BLI_snprintf(tmp, sizeof(tmp), "%d", i % 1000); BLI_path_suffix(name, FILE_MAX, tmp, "_"); } } |