Krolyxon
Commit 30e2356

Branches

Refs →

nsxiv30e2356

Remove obsolete files[].base

Author
Bert Münnich
Date
2017-12-07 14:16 +0100
Parent
004fcd5
Commit
30e235662251d24e855ef12eaf9a5a338fbe5d65

+0 −6

2 files changed

  1. M main.c +0 −5
  2. M sxiv.h +0 −1
M main.c View
@@ -103,7 +103,6 @@ void cleanup(void)
103103 void check_add_file(char *filename, bool given)
104104 {
105105 char *path;
106− const char *bn;
107106
108107 if (*filename == '\0')
109108 return;
@@ -124,10 +123,6 @@ void check_add_file(char *filename, bool given)
124123
125124 files[fileidx].name = estrdup(filename);
126125 files[fileidx].path = path;
127− if ((bn = strrchr(files[fileidx].name , '/')) != NULL && bn[1] != '\0')
128− files[fileidx].base = ++bn;
129− else
130− files[fileidx].base = files[fileidx].name;
131126 if (given)
132127 files[fileidx].flags |= FF_WARN;
133128 fileidx++;
M sxiv.h View
@@ -113,7 +113,6 @@ typedef enum {
113113 typedef struct {
114114 const char *name; /* as given by user */
115115 const char *path; /* always absolute */
116− const char *base;
117116 fileflags_t flags;
118117 } fileinfo_t;
119118