From: Sebastian D. <seb...@ta...> - 2008-08-18 17:21:02
|
Dmitriy Mazovka wrote: > Hello! > > Seems there is a problem in > > ef_icon_theme.c:590 > > if (!strcmp(p, ".png") || !strcmp(p, ".xpm")) > { > *p = '\0'; > > p = strrchr(file, '/'); > if (p) p++; > if (p) ecore_hash_set(icons, strdup(p), strdup(p)); > } > > I suppose there is a bug here, and the code should be like follows: > > if (!strcmp(p, ".png") || !strcmp(p, ".xpm")) > { > *p = '\0'; > > p = strrchr(file, '/'); > if (p) p++; > else p = file; > if (p) ecore_hash_set(icons, strdup(p), strdup(p)); > } > > It is a small notice however and we (me and Vincent Torri) cannot decide whether this is a feature or bug. So just a warning for you:). Tests pass good and without it actually, but "icons" list stays empty while it should be definitely filled. Shouldn't it be just to add the file? ecore_file_ls will only give file names without path, and such never contain '/'. Sebastian |