diff --git a/configuration.h b/configuration.h index 5e05787409..a0f64b2805 100644 --- a/configuration.h +++ b/configuration.h @@ -210,7 +210,7 @@ typedef struct settings struct { char driver[32]; - char device[PATH_MAX_LENGTH]; + char device[255]; bool allow; unsigned width; unsigned height; @@ -234,7 +234,7 @@ typedef struct settings { char driver[32]; char resampler[32]; - char device[PATH_MAX_LENGTH]; + char device[255]; bool enable; bool mute_enable; unsigned out_rate; @@ -400,7 +400,7 @@ typedef struct settings #ifdef HAVE_NETWORKING struct { - char server[PATH_MAX_LENGTH]; + char server[255]; unsigned port; unsigned sync_frames; unsigned check_frames; diff --git a/database_info.h b/database_info.h index 7a5262c699..f6c63fe79f 100644 --- a/database_info.h +++ b/database_info.h @@ -22,7 +22,6 @@ #include #include -#include #include RETRO_BEGIN_DECLS @@ -107,7 +106,7 @@ typedef struct database_state_handle uint32_t crc; uint32_t archive_crc; uint8_t *buf; - char archive_name[PATH_MAX_LENGTH]; + char archive_name[255]; char serial[4096]; } database_state_handle_t; diff --git a/input/input_autodetect.c b/input/input_autodetect.c index 81dc090426..85a3bfa6b1 100644 --- a/input/input_autodetect.c +++ b/input/input_autodetect.c @@ -296,7 +296,7 @@ static bool input_config_autoconfigure_joypad_init(autoconfig_params_t *params) bool input_config_autoconfigure_joypad(autoconfig_params_t *params) { - char msg[PATH_MAX_LENGTH]; + char msg[255]; msg[0] = '\0'; @@ -337,7 +337,7 @@ const struct retro_keybind *input_get_auto_bind(unsigned port, unsigned id) void input_config_autoconfigure_disconnect(unsigned i, const char *ident) { - char msg[PATH_MAX_LENGTH]; + char msg[255]; msg[0] = '\0'; diff --git a/libretro-common/lists/string_list.c b/libretro-common/lists/string_list.c index 9eedc7ad37..93368c4201 100644 --- a/libretro-common/lists/string_list.c +++ b/libretro-common/lists/string_list.c @@ -26,7 +26,6 @@ #include #include -#include #include #include @@ -290,7 +289,7 @@ bool string_list_find_elem_prefix(const struct string_list *list, const char *prefix, const char *elem) { size_t i; - char prefixed[PATH_MAX_LENGTH]; + char prefixed[255]; if (!list) return false; diff --git a/menu/cbs/menu_cbs_get_value.c b/menu/cbs/menu_cbs_get_value.c index b6c79ee92a..9daf1d1cac 100644 --- a/menu/cbs/menu_cbs_get_value.c +++ b/menu/cbs/menu_cbs_get_value.c @@ -447,7 +447,7 @@ static void menu_action_setting_disp_set_label_input_desc( const char *path, char *s2, size_t len2) { - char descriptor[PATH_MAX_LENGTH]; + char descriptor[255]; const struct retro_keybind *auto_bind = NULL; const struct retro_keybind *keybind = NULL; settings_t *settings = config_get_ptr(); @@ -461,6 +461,8 @@ static void menu_action_setting_disp_set_label_input_desc( if (!settings) return; + + descriptor[0] = '\0'; remap_id = settings->input.remap_ids [inp_desc_user][inp_desc_button_index_offset]; @@ -1405,7 +1407,7 @@ static void menu_action_setting_disp_set_label_playlist_associations(file_list_t const char *path, char *s2, size_t len2) { - char playlist_name_with_ext[PATH_MAX_LENGTH]; + char playlist_name_with_ext[255]; bool found_matching_core_association = false; settings_t *settings = config_get_ptr(); struct string_list *str_list = string_split(settings->playlist_names, ";"); diff --git a/menu/cbs/menu_cbs_title.c b/menu/cbs/menu_cbs_title.c index 6cd8dd1d13..d16882e691 100644 --- a/menu/cbs/menu_cbs_title.c +++ b/menu/cbs/menu_cbs_title.c @@ -37,7 +37,7 @@ static void replace_chars(char *str, char c1, char c2) static void sanitize_to_string(char *s, const char *label, size_t len) { - char new_label[PATH_MAX_LENGTH]; + char new_label[255]; new_label[0] = '\0'; @@ -690,7 +690,7 @@ static int action_get_title_generic(char *s, size_t len, const char *path, if (list_path) { - char elem0_path[PATH_MAX_LENGTH]; + char elem0_path[255]; elem0_path[0] = '\0'; @@ -839,8 +839,8 @@ static int action_get_title_group_settings(const char *path, const char *label, strlcpy(s, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_HORIZONTAL_MENU), len); else { - char elem0[PATH_MAX_LENGTH]; - char elem1[PATH_MAX_LENGTH]; + char elem0[255]; + char elem1[255]; struct string_list *list_label = string_split(label, "|"); elem0[0] = elem1[0] = '\0'; diff --git a/menu/widgets/menu_entry.h b/menu/widgets/menu_entry.h index e2af13e9ac..d37fa7e457 100644 --- a/menu/widgets/menu_entry.h +++ b/menu/widgets/menu_entry.h @@ -45,11 +45,11 @@ enum menu_entry_type typedef struct menu_entry { - char path[PATH_MAX_LENGTH]; - char label[PATH_MAX_LENGTH]; - char sublabel[PATH_MAX_LENGTH]; - char rich_label[PATH_MAX_LENGTH]; - char value[PATH_MAX_LENGTH]; + char path[255]; + char label[255]; + char sublabel[255]; + char rich_label[255]; + char value[255]; size_t entry_idx; enum msg_hash_enums enum_idx; unsigned idx;