summaryrefslogtreecommitdiff
path: root/apps/filetypes.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/filetypes.c')
-rw-r--r--apps/filetypes.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/apps/filetypes.c b/apps/filetypes.c
index 24dc0f2e4d..74607eac1c 100644
--- a/apps/filetypes.c
+++ b/apps/filetypes.c
@@ -262,9 +262,9 @@ void read_color_theme_file(void) {
262 unknown_file.color = -1; 262 unknown_file.color = -1;
263 if (!global_settings.colors_file[0] || global_settings.colors_file[0] == '-') 263 if (!global_settings.colors_file[0] || global_settings.colors_file[0] == '-')
264 return; 264 return;
265 snprintf(buffer, MAX_PATH, THEME_DIR "/%s.colours", 265
266 global_settings.colors_file); 266 fd = open_pathfmt(O_RDONLY, THEME_DIR "/%s.colours",
267 fd = open(buffer, O_RDONLY); 267 global_settings.colors_file);
268 if (fd < 0) 268 if (fd < 0)
269 return; 269 return;
270 while (read_line(fd, buffer, MAX_PATH) > 0) 270 while (read_line(fd, buffer, MAX_PATH) > 0)
@@ -303,9 +303,8 @@ void read_viewer_theme_file(void)
303 custom_filetype_icons[i] = filetypes[i].icon; 303 custom_filetype_icons[i] = filetypes[i].icon;
304 } 304 }
305 305
306 snprintf(buffer, MAX_PATH, "%s/%s.icons", ICON_DIR, 306 fd = open_pathfmt(O_RDONLY, "%s/%s.icons", ICON_DIR,
307 global_settings.viewers_icon_file); 307 global_settings.viewers_icon_file);
308 fd = open(buffer, O_RDONLY);
309 if (fd < 0) 308 if (fd < 0)
310 return; 309 return;
311 while (read_line(fd, buffer, MAX_PATH) > 0) 310 while (read_line(fd, buffer, MAX_PATH) > 0)