mirror of
https://github.com/MidnightCommander/mc
synced 2025-02-19 08:44:11 +03:00
* vfs.c (mc_chdir): Fixed memory leak.
This commit is contained in:
parent
6f68fa3082
commit
c64cec997a
@ -1,3 +1,7 @@
|
|||||||
|
2004-08-26 Roland Illig <roland.illig@gmx.de>
|
||||||
|
|
||||||
|
* vfs.c (mc_chdir): Fixed memory leak.
|
||||||
|
|
||||||
2004-08-22 Leonard den Ottolander <leonard * den ottolander nl>
|
2004-08-22 Leonard den Ottolander <leonard * den ottolander nl>
|
||||||
|
|
||||||
* vfs/extfs/a.in: Quote parameters to calls to system/open that spawn
|
* vfs/extfs/a.in: Quote parameters to calls to system/open that spawn
|
||||||
|
@ -678,8 +678,10 @@ mc_chdir (const char *path)
|
|||||||
|
|
||||||
new_dir = vfs_canon (path);
|
new_dir = vfs_canon (path);
|
||||||
new_vfs = vfs_get_class (new_dir);
|
new_vfs = vfs_get_class (new_dir);
|
||||||
if (!new_vfs->chdir)
|
if (!new_vfs->chdir) {
|
||||||
|
g_free (new_dir);
|
||||||
return -1;
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
result = (*new_vfs->chdir) (new_vfs, new_dir);
|
result = (*new_vfs->chdir) (new_vfs, new_dir);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user