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>2015-10-17 08:06:45 +0300
committerCampbell Barton <ideasman42@gmail.com>2015-10-17 08:06:45 +0300
commiteb49a76dcaa18ef6bf2667b3671913ca9ccf31e7 (patch)
tree1f8c0a98d887707d679d07049b90545cece49ff2 /source/blender/blenfont
parent3d69ef240e29194cb1be9d48591e5b411152632b (diff)
Cleanup: warnings
- remove NULL checks for args already set as ATTR_NONNULL. - double promotion.
Diffstat (limited to 'source/blender/blenfont')
-rw-r--r--source/blender/blenfont/intern/blf.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/source/blender/blenfont/intern/blf.c b/source/blender/blenfont/intern/blf.c
index 61b847fd3a3..b7d72bb28bb 100644
--- a/source/blender/blenfont/intern/blf.c
+++ b/source/blender/blenfont/intern/blf.c
@@ -176,9 +176,6 @@ int BLF_load(const char *name)
char *filename;
int i;
- if (!name)
- return -1;
-
/* check if we already load this font. */
i = blf_search(name);
if (i >= 0) {
@@ -216,9 +213,6 @@ int BLF_load_unique(const char *name)
char *filename;
int i;
- if (!name)
- return -1;
-
/* Don't search in the cache!! make a new
* object font, this is for keep fonts threads safe.
*/
@@ -260,9 +254,6 @@ int BLF_load_mem(const char *name, const unsigned char *mem, int mem_size)
FontBLF *font;
int i;
- if (!name)
- return -1;
-
i = blf_search(name);
if (i >= 0) {
/*font = global_font[i];*/ /*UNUSED*/
@@ -275,7 +266,7 @@ int BLF_load_mem(const char *name, const unsigned char *mem, int mem_size)
return -1;
}
- if (!mem || !mem_size) {
+ if (!mem_size) {
printf("Can't load font: %s from memory!!\n", name);
return -1;
}
@@ -295,9 +286,6 @@ int BLF_load_mem_unique(const char *name, const unsigned char *mem, int mem_size
FontBLF *font;
int i;
- if (!name)
- return -1;
-
/*
* Don't search in the cache, make a new object font!
* this is to keep the font thread safe.
@@ -308,7 +296,7 @@ int BLF_load_mem_unique(const char *name, const unsigned char *mem, int mem_size
return -1;
}
- if (!mem || !mem_size) {
+ if (!mem_size) {
printf("Can't load font: %s from memory!!\n", name);
return -1;
}