Fix segfault if gadget has no zone.

SVN revision: 49163
This commit is contained in:
Christopher Michael 2010-05-23 20:39:51 +00:00
parent aaffc9210f
commit d1e46e3888
1 changed files with 6 additions and 3 deletions

View File

@ -781,7 +781,10 @@ e_gadcon_client_config_new(E_Gadcon *gc, const char *name)
if (!cf_gcc) return NULL;
cf_gcc->name = eina_stringshare_add(name);
cf_gcc->id = eina_stringshare_add(cc->func.id_new(cc));
if (gc->zone)
cf_gcc->geom.res = gc->zone->w;
else
cf_gcc->geom.res = 800;
cf_gcc->geom.size = 80;
cf_gcc->geom.pos = cf_gcc->geom.res - cf_gcc->geom.size;
cf_gcc->style = NULL;