1
1

2000-08-21 Jonathan Blandford <jrb@redhat.com>

* gmount.c (create_device_link): Fix memory leak.  Also, make sure
	the icon is dead before making the link.  This is necessary in
	case your metadata database gets fubarred.
Этот коммит содержится в:
Jonathan Blandford 2000-08-21 20:16:25 +00:00
родитель da03b26ab1
Коммит a7e8f34f9e
2 изменённых файлов: 11 добавлений и 0 удалений

Просмотреть файл

@ -1,3 +1,9 @@
2000-08-21 Jonathan Blandford <jrb@redhat.com>
* gmount.c (create_device_link): Fix memory leak. Also, make sure
the icon is dead before making the link. This is necessary in
case your metadata database gets fubarred.
2000-08-08 Miguel de Icaza <miguel@gnu.org>
* gdesktop.c (new_terminal): Add patch from Duncan Mak to use the

Просмотреть файл

@ -374,15 +374,20 @@ create_device_link (char *dev_name, char *short_dev_name, char *caption, char *i
char *icon_full;
char type = 'D';
char ejectable_c = ejectable;
struct stat st;
icon_full = g_concat_dir_and_file (ICONDIR, icon);
full_name = g_concat_dir_and_file (desktop_directory, short_dev_name);
if (!mc_lstat (full_name, &st))
mc_unlink (full_name);
if (mc_symlink (dev_name, full_name) != 0) {
message (FALSE,
_("Warning"),
_("Could not symlink %s to %s; "
"will not have such a desktop device icon."),
dev_name, full_name);
g_free (icon_full);
g_free (full_name);
return;
}