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--build_files/cmake/macros.cmake6
-rw-r--r--source/blender/blenlib/intern/path_util.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/build_files/cmake/macros.cmake b/build_files/cmake/macros.cmake
index ec55489e59e..2297cac8bb9 100644
--- a/build_files/cmake/macros.cmake
+++ b/build_files/cmake/macros.cmake
@@ -358,8 +358,8 @@ macro(get_blender_version)
message(FATAL_ERROR "Version parsing failed for BLENDER_VERSION_CYCLE")
endif()
- MATH(EXPR BLENDER_VERSION_MAJOR "${_out_version} / 100")
- MATH(EXPR BLENDER_VERSION_MINOR "${_out_version} % 100")
+ math(EXPR BLENDER_VERSION_MAJOR "${_out_version} / 100")
+ math(EXPR BLENDER_VERSION_MINOR "${_out_version} % 100")
set(BLENDER_VERSION "${BLENDER_VERSION_MAJOR}.${BLENDER_VERSION_MINOR}")
set(BLENDER_SUBVERSION ${_out_subversion})
@@ -372,7 +372,7 @@ macro(get_blender_version)
else()
set(_char_ls a b c d e f g h i j k l m n o p q r s t u v w q y z)
list(FIND _char_ls ${BLENDER_VERSION_CHAR} _out_version_char_index)
- MATH(EXPR BLENDER_VERSION_CHAR_INDEX "${_out_version_char_index} + 1")
+ math(EXPR BLENDER_VERSION_CHAR_INDEX "${_out_version_char_index} + 1")
unset(_char_ls)
unset(_out_version_char_index)
endif()
diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c
index 7b6afd6b884..c0c8fc4e24f 100644
--- a/source/blender/blenlib/intern/path_util.c
+++ b/source/blender/blenlib/intern/path_util.c
@@ -206,7 +206,7 @@ void BLI_newname(char *name, int add)
int BLI_uniquename_cb(int (*unique_check)(void *, const char *), void *arg, const char defname[], char delim, char *name, short name_len)
{
- if(name == '\0') {
+ if(name[0] == '\0') {
BLI_strncpy(name, defname, name_len);
}
@@ -1192,7 +1192,7 @@ void BLI_setenv_if_new(const char *env, const char* val)
void BLI_clean(char *path)
{
- if(path==0) return;
+ if(path==NULL) return;
#ifdef WIN32
if(path && BLI_strnlen(path, 3) > 2) {
@@ -1205,7 +1205,7 @@ void BLI_clean(char *path)
void BLI_char_switch(char *string, char from, char to)
{
- if(string==0) return;
+ if(string==NULL) return;
while (*string != 0) {
if (*string == from) *string = to;
string++;