Skip to content

Commit dd480aa

Browse files
committed
Silence some more code analysis warnings
1 parent 4c07e26 commit dd480aa

File tree

3 files changed

+11
-12
lines changed

3 files changed

+11
-12
lines changed

gfx/gfx_animation.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1655,7 +1655,7 @@ void gfx_animation_deinit(void)
16551655
void gfx_animation_timer_start(float *timer, gfx_timer_ctx_entry_t *timer_entry)
16561656
{
16571657
gfx_animation_ctx_entry_t entry;
1658-
uintptr_t tag = (uintptr_t) timer;
1658+
uintptr_t tag = (uintptr_t)timer;
16591659

16601660
gfx_animation_kill_by_tag(&tag);
16611661

libretro-common/formats/m3u/m3u_file.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -474,7 +474,6 @@ bool m3u_file_save(
474474
{
475475
size_t i;
476476
char base_dir[DIR_MAX_LENGTH];
477-
char *last_slash = NULL;
478477
RFILE *file = NULL;
479478

480479
if (!m3u_file || !m3u_file->entries)
@@ -485,7 +484,7 @@ bool m3u_file_save(
485484
return false;
486485

487486
/* Get M3U file base directory */
488-
if ((last_slash = find_last_slash(m3u_file->path)))
487+
if (find_last_slash(m3u_file->path))
489488
fill_pathname_basedir(base_dir, m3u_file->path, sizeof(base_dir));
490489
else
491490
base_dir[0] = '\0';

menu/drivers/materialui.c

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5100,10 +5100,6 @@ static void materialui_render_menu_entry_playlist_desktop(
51005100
int divider_y = entry_y + (int)node->entry_height;
51015101
int entry_margin = (int)mui->margin;
51025102
int usable_width = node->entry_width - (int)(mui->margin * 2);
5103-
/* Entry label is drawn at the vertical centre
5104-
* of the current node */
5105-
int label_y = entry_y + (node->entry_height / 2.0f) +
5106-
mui->font_data.list.line_centre_offset;
51075103
bool draw_text_outside = (x_offset != 0);
51085104
/* To prevent any ugly alignment issues, we
51095105
* only draw a divider if its bottom edge is
@@ -5123,12 +5119,16 @@ static void materialui_render_menu_entry_playlist_desktop(
51235119
/* Draw entry label */
51245120
if (!string_is_empty(entry_label))
51255121
{
5126-
char label_buf[NAME_MAX_LENGTH];
5127-
5128-
label_buf[0] = '\0';
5129-
51305122
if (usable_width > 0)
51315123
{
5124+
char label_buf[NAME_MAX_LENGTH];
5125+
label_buf[0] = '\0';
5126+
5127+
/* Entry label is drawn at the vertical centre
5128+
* of the current node */
5129+
int label_y = entry_y + (node->entry_height / 2.0f) +
5130+
mui->font_data.list.line_centre_offset;
5131+
51325132
/* Apply ticker */
51335133
if (mui->flags & MUI_FLAG_USE_SMOOTH_TICKER)
51345134
{
@@ -5157,7 +5157,7 @@ static void materialui_render_menu_entry_playlist_desktop(
51575157
label_y,
51585158
video_width, video_height,
51595159
(entry_selected || touch_feedback_active) ?
5160-
mui->colors.list_text_highlighted : mui->colors.list_text,
5160+
mui->colors.list_text_highlighted : mui->colors.list_text,
51615161
TEXT_ALIGN_LEFT, 1.0f, false, 0.0f,
51625162
draw_text_outside);
51635163
}

0 commit comments

Comments
 (0)