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>2011-02-13 06:21:27 +0300
committerCampbell Barton <ideasman42@gmail.com>2011-02-13 06:21:27 +0300
commit867fc4b463ef39ea16103f18f332c3d259624d29 (patch)
tree7d20c416241afb7b878b767a9955e284d3cddbe2 /source/blender/modifiers/intern/MOD_shrinkwrap.c
parent9e03a0d4762b4734fe7ccb20e03b4a3c8f939620 (diff)
enforce string limits (reported by pedantic checking tools & some developers).
mostly replace strcpy with BLI_strncpy and multiple strcat's with a BLI_snprintf(). also fix possible crash if CWD isnt available.
Diffstat (limited to 'source/blender/modifiers/intern/MOD_shrinkwrap.c')
-rw-r--r--source/blender/modifiers/intern/MOD_shrinkwrap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_shrinkwrap.c b/source/blender/modifiers/intern/MOD_shrinkwrap.c
index 56a5b4b8577..c7f15a94bf2 100644
--- a/source/blender/modifiers/intern/MOD_shrinkwrap.c
+++ b/source/blender/modifiers/intern/MOD_shrinkwrap.c
@@ -32,9 +32,9 @@
#include <string.h>
+#include "BLI_string.h"
#include "BLI_utildefines.h"
-
#include "BKE_cdderivedmesh.h"
#include "BKE_modifier.h"
#include "BKE_shrinkwrap.h"
@@ -65,7 +65,7 @@ static void copyData(ModifierData *md, ModifierData *target)
tsmd->target = smd->target;
tsmd->auxTarget = smd->auxTarget;
- strcpy(tsmd->vgroup_name, smd->vgroup_name);
+ BLI_strncpy(tsmd->vgroup_name, smd->vgroup_name, sizeof(tsmd->vgroup_name));
tsmd->keepDist = smd->keepDist;
tsmd->shrinkType= smd->shrinkType;