diff options
author | Campbell Barton <ideasman42@gmail.com> | 2015-01-10 04:40:09 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2015-01-10 04:40:09 +0300 |
commit | 9590e77a5993ac43cf5933628f9d42933a45b296 (patch) | |
tree | 40d3832e33597f8e67fdb6edcc8fa23b1ae1cdc3 /source | |
parent | dec523da877facb0573dccce6d95e5b0d2734707 (diff) |
cleanup: style & warnings
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/customdata.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/string.c | 4 | ||||
-rw-r--r-- | source/blender/editors/animation/keyframes_general.c | 5 | ||||
-rw-r--r-- | source/blender/editors/object/object_data_transfer.c | 3 |
4 files changed, 8 insertions, 6 deletions
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c index 856f893e876..89ebed258a3 100644 --- a/source/blender/blenkernel/intern/customdata.c +++ b/source/blender/blenkernel/intern/customdata.c @@ -3590,7 +3590,7 @@ static void customdata_data_transfer_interp_generic( const float mix_factor) { /* Fake interpolation, we actually copy highest weighted source to dest. - * Note we also handle bitflags here, in which case we rather choose to transfer value of elements totalizing + * Note we also handle bitflags here, in which case we rather choose to transfer value of elements totaling * more than 0.5 of weight. */ int best_src_idx = 0; diff --git a/source/blender/blenlib/intern/string.c b/source/blender/blenlib/intern/string.c index cc049fce7ab..f7ac8442b8b 100644 --- a/source/blender/blenlib/intern/string.c +++ b/source/blender/blenlib/intern/string.c @@ -773,7 +773,7 @@ int BLI_str_index_in_array(const char *__restrict str, const char **__restrict s return -1; } -bool BLI_strn_endswith(const char *__restrict str,const char *__restrict end, int slength) +bool BLI_strn_endswith(const char *__restrict str, const char *__restrict end, int slength) { int elength = strlen(end); @@ -796,7 +796,7 @@ bool BLI_strn_endswith(const char *__restrict str,const char *__restrict end, in * \param end The string we look for at the end. * \return If str ends with end. */ -bool BLI_str_endswith(const char *__restrict str,const char *end) +bool BLI_str_endswith(const char *__restrict str, const char *end) { int slength = strlen(str); return BLI_strn_endswith(str, end, slength); diff --git a/source/blender/editors/animation/keyframes_general.c b/source/blender/editors/animation/keyframes_general.c index 64332f61758..6d73cd0c04c 100644 --- a/source/blender/editors/animation/keyframes_general.c +++ b/source/blender/editors/animation/keyframes_general.c @@ -615,7 +615,8 @@ short copy_animedit_keys(bAnimContext *ac, ListBase *anim_data) return 0; } -static void flip_names(tAnimCopybufItem *aci, char **name) { +static void flip_names(tAnimCopybufItem *aci, char **name) +{ if (aci->is_bone) { char *str_start; if ((str_start = strstr(aci->rna_path, "pose.bones["))) { @@ -644,7 +645,7 @@ static void flip_names(tAnimCopybufItem *aci, char **name) { BLI_strncpy(str_iter, bname_new, length + 1); str_iter += length; BLI_strncpy(str_iter, str_end, postfix_l + 1); - str_iter[postfix_l] = 0; + str_iter[postfix_l] = '\0'; } } } diff --git a/source/blender/editors/object/object_data_transfer.c b/source/blender/editors/object/object_data_transfer.c index 8dfd31c92bb..86f2824deb4 100644 --- a/source/blender/editors/object/object_data_transfer.c +++ b/source/blender/editors/object/object_data_transfer.c @@ -25,7 +25,7 @@ * ***** END GPL LICENSE BLOCK ***** */ -/** \file blender/editors/object/object_transfer_data.c +/** \file blender/editors/object/object_data_transfer.c * \ingroup edobj */ @@ -378,6 +378,7 @@ static int data_transfer_exec(bContext *C, wmOperator *op) /* Note: issue with that is that if canceled, operator cannot be redone... Nasty in our case. */ return changed ? OPERATOR_FINISHED : OPERATOR_CANCELLED; #else + (void)changed; return OPERATOR_FINISHED; #endif } |