mirror of https://github.com/MidnightCommander/mc
Removed some unused vars and functions
This commit is contained in:
parent
025ab0baee
commit
aed7edf0f6
|
@ -142,8 +142,7 @@ lock_get_info (const char *lockfname)
|
|||
int cnt;
|
||||
static char buf[BUF_SIZE];
|
||||
|
||||
if ((cnt = readlink (lockfname, buf, BUF_SIZE - 1)) == -1 || !buf
|
||||
|| !*buf)
|
||||
if ((cnt = readlink (lockfname, buf, BUF_SIZE - 1)) == -1 || !*buf)
|
||||
return NULL;
|
||||
buf[cnt] = '\0';
|
||||
return buf;
|
||||
|
|
|
@ -1223,8 +1223,6 @@ dirsizes_cmd (void)
|
|||
void
|
||||
save_setup_cmd (void)
|
||||
{
|
||||
char *str;
|
||||
|
||||
save_setup ();
|
||||
sync_profiles ();
|
||||
|
||||
|
|
|
@ -1491,36 +1491,6 @@ load_hotlist (void)
|
|||
current_group = hotlist;
|
||||
}
|
||||
|
||||
static void
|
||||
save_group (struct hotlist *grp)
|
||||
{
|
||||
struct hotlist *current = grp->head;
|
||||
char *group_section;
|
||||
|
||||
group_section = find_group_section (grp);
|
||||
|
||||
profile_clean_section (group_section, profile_name);
|
||||
for (;current && current->type == HL_TYPE_GROUP; current = current->next){
|
||||
WritePrivateProfileString (group_section,
|
||||
current->directory,
|
||||
current->label,
|
||||
profile_name);
|
||||
}
|
||||
g_free (group_section);
|
||||
|
||||
for (current = grp->head;
|
||||
current && current->type == HL_TYPE_GROUP;
|
||||
current = current->next)
|
||||
save_group (current);
|
||||
|
||||
profile_clean_section (grp->directory, profile_name);
|
||||
for (;current; current = current->next){
|
||||
WritePrivateProfileString (grp->directory,
|
||||
current->directory,
|
||||
current->label,
|
||||
profile_name);
|
||||
}
|
||||
}
|
||||
|
||||
static int list_level = 0;
|
||||
|
||||
|
|
13
src/main.c
13
src/main.c
|
@ -2114,19 +2114,6 @@ handle_args (int argc, char *argv[])
|
|||
poptFreeContext (ctx);
|
||||
}
|
||||
|
||||
static int
|
||||
do_mc_filename_rename (const char *o_name, const char *n_name)
|
||||
{
|
||||
char *full_o_name = concat_dir_and_file (home_dir, o_name);
|
||||
char *full_n_name = g_strconcat (home_dir, MC_BASE, n_name, (char *) NULL);
|
||||
int move;
|
||||
|
||||
move = 0 == rename (full_o_name, full_n_name);
|
||||
g_free (full_o_name);
|
||||
g_free (full_n_name);
|
||||
return move;
|
||||
}
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
|
|
|
@ -755,7 +755,6 @@ file_date (time_t when)
|
|||
static size_t i18n_timelength = 0;
|
||||
static const char *fmtyear, *fmttime;
|
||||
const char *fmt;
|
||||
struct tm *whentm;
|
||||
|
||||
if (i18n_timelength == 0){
|
||||
i18n_timelength = i18n_checktimelength() + 1;
|
||||
|
|
Loading…
Reference in New Issue