wIconStore(): do not save the icon if it exists

The function wIconStore() doesn't write a new file overwriting the
previous icon if the icon file exists.
This commit is contained in:
Rodolfo García Peñas (kix) authored and Carlos R. Mafra committed 2012-04-16 09:32:24 -03:00
1 parent 21fb6db616
commit 0db76b822d
1 file changed
+4
+4
View File
@@ -473,6 +473,10 @@ char *wIconStore(WIcon * icon)
if (!path)
return NULL;
/* If icon exists, exit */
if (access(path, F_OK) == 0)
return path;
if (wwin->net_icon_image) {
image = RRetainImage(wwin->net_icon_image);
} else if (wwin->wm_hints && (wwin->wm_hints->flags & IconPixmapHint)