mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 20:36:50 +03:00
* xdirentry.h: Get rid of ifree(), it's equivalent to g_free().
* direntry.c: Likewise. * fish.c: Likewise. * ftpfs.c: Likewise.
This commit is contained in:
parent
87e4797648
commit
982a256ee0
@ -1,5 +1,10 @@
|
||||
2002-07-19 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* xdirentry.h: Get rid of ifree(), it's equivalent to g_free().
|
||||
* direntry.c: Likewise.
|
||||
* fish.c: Likewise.
|
||||
* ftpfs.c: Likewise.
|
||||
|
||||
* fish.c (fish_fill_names): New function, replacement for
|
||||
generic vfs_s_fill_names() which didn't work right with fish.
|
||||
|
||||
|
@ -91,7 +91,7 @@ vfs_s_free_inode (vfs *me, vfs_s_inode *ino)
|
||||
}
|
||||
|
||||
CALL (free_inode) (me, ino);
|
||||
ifree (ino->linkname);
|
||||
g_free (ino->linkname);
|
||||
if (ino->localname){
|
||||
unlink (ino->localname);
|
||||
g_free(ino->localname);
|
||||
@ -443,7 +443,7 @@ vfs_s_free_super (vfs *me, vfs_s_super *super)
|
||||
}
|
||||
|
||||
CALL (free_archive) (me, super);
|
||||
ifree (super->name);
|
||||
g_free (super->name);
|
||||
super->name = NULL;
|
||||
g_free(super);
|
||||
}
|
||||
|
10
vfs/fish.c
10
vfs/fish.c
@ -150,11 +150,11 @@ free_archive (vfs *me, vfs_s_super *super)
|
||||
close(SUP.sockr);
|
||||
SUP.sockw = SUP.sockr = -1;
|
||||
}
|
||||
ifree (SUP.host);
|
||||
ifree (SUP.home);
|
||||
ifree (SUP.user);
|
||||
ifree (SUP.cwdir);
|
||||
ifree (SUP.password);
|
||||
g_free (SUP.host);
|
||||
g_free (SUP.home);
|
||||
g_free (SUP.user);
|
||||
g_free (SUP.cwdir);
|
||||
g_free (SUP.password);
|
||||
}
|
||||
|
||||
static void
|
||||
|
10
vfs/ftpfs.c
10
vfs/ftpfs.c
@ -382,11 +382,11 @@ free_archive (vfs *me, vfs_s_super *super)
|
||||
command(me, super, NONE, "QUIT");
|
||||
close(SUP.sock);
|
||||
}
|
||||
ifree (SUP.host);
|
||||
ifree (SUP.home);
|
||||
ifree (SUP.user);
|
||||
ifree (SUP.cwdir);
|
||||
ifree (SUP.password);
|
||||
g_free (SUP.host);
|
||||
g_free (SUP.home);
|
||||
g_free (SUP.user);
|
||||
g_free (SUP.cwdir);
|
||||
g_free (SUP.password);
|
||||
}
|
||||
|
||||
/* some defines only used by changetype */
|
||||
|
@ -254,11 +254,8 @@ int vfs_s_get_line_interruptible (vfs *me, char *buffer, int size, int fd);
|
||||
int vfs_s_retrieve_file (vfs *me, struct vfs_s_inode *ino);
|
||||
|
||||
#if 0
|
||||
/* If non-null, FREE */
|
||||
#define ifree(ptr) do { if (ptr) g_free(ptr); } while (0)
|
||||
#define ERRNOR(a, b) do { me->verrno = a; return b; } while (0)
|
||||
#else
|
||||
#define ifree(ptr) { if (ptr) g_free(ptr); }
|
||||
#define ERRNOR(a, b) { me->verrno = a; return b; }
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user