mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-03-03 17:30:37 +00:00
[core] scan-build: Value stored to 'len' is never read
This commit is contained in:
parent
dc2b43fb74
commit
a5ef549b81
@ -2134,7 +2134,6 @@ SWITCH_DECLARE(switch_image_t *) switch_img_write_text_img(int w, int h, switch_
|
|||||||
char *argv[6] = { 0 };
|
char *argv[6] = { 0 };
|
||||||
switch_rgb_color_t bgcolor = { 0 };
|
switch_rgb_color_t bgcolor = { 0 };
|
||||||
int pre_width = 0, width = 0, font_size = 0, height = 0;
|
int pre_width = 0, width = 0, font_size = 0, height = 0;
|
||||||
int len = 0;
|
|
||||||
char *duptxt = strdup(text);
|
char *duptxt = strdup(text);
|
||||||
switch_img_txt_handle_t *txthandle = NULL;
|
switch_img_txt_handle_t *txthandle = NULL;
|
||||||
switch_image_t *txtimg = NULL;
|
switch_image_t *txtimg = NULL;
|
||||||
@ -2178,11 +2177,6 @@ SWITCH_DECLARE(switch_image_t *) switch_img_write_text_img(int w, int h, switch_
|
|||||||
while (*txt == ' ') txt++;
|
while (*txt == ' ') txt++;
|
||||||
while (end_of(txt) == ' ') end_of(txt) = '\0';
|
while (end_of(txt) == ' ') end_of(txt) = '\0';
|
||||||
|
|
||||||
len = strlen(txt);
|
|
||||||
|
|
||||||
if (len < 5) len = 5;
|
|
||||||
|
|
||||||
|
|
||||||
switch_img_txt_handle_create(&txthandle, font_face, fg, bg, font_size, 0, NULL);
|
switch_img_txt_handle_create(&txthandle, font_face, fg, bg, font_size, 0, NULL);
|
||||||
|
|
||||||
pre_width = switch_img_txt_handle_render(txthandle,
|
pre_width = switch_img_txt_handle_render(txthandle,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user