forked from enlightenment/efl
parent
e15ba8bba1
commit
d625e4d386
|
@ -313,7 +313,6 @@ _eio_dir_chmod(Ecore_Thread *thread, Eio_Dir_Copy *order,
|
|||
{
|
||||
/* destroy in reverse order so that we don't prevent change of lower dir */
|
||||
dir = eina_list_data_get(eina_list_last(order->dirs));
|
||||
if (!dir) continue;
|
||||
order->dirs = eina_list_remove_list(order->dirs, eina_list_last(order->dirs));
|
||||
|
||||
/* build target dir path */
|
||||
|
|
|
@ -414,18 +414,16 @@ eio_file_direct_stat(const char *path,
|
|||
s->path = eina_stringshare_add(path);
|
||||
s->done_cb = done_cb;
|
||||
|
||||
if (eio_file_set(&s->common,
|
||||
if (!eio_file_set(&s->common,
|
||||
NULL,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_stat,
|
||||
_eio_file_stat_done,
|
||||
_eio_file_stat_error))
|
||||
return &s->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
free(s);
|
||||
return NULL;
|
||||
return &s->common;
|
||||
}
|
||||
|
||||
EAPI Eio_File *
|
||||
|
@ -446,18 +444,16 @@ eio_file_direct_lstat(const char *path,
|
|||
s->path = eina_stringshare_add(path);
|
||||
s->done_cb = done_cb;
|
||||
|
||||
if (eio_file_set(&s->common,
|
||||
if (!eio_file_set(&s->common,
|
||||
NULL,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_lstat,
|
||||
_eio_file_stat_done,
|
||||
_eio_file_stat_error))
|
||||
return &s->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
free(s);
|
||||
return NULL;
|
||||
return &s->common;
|
||||
#else
|
||||
return eio_file_direct_stat(path, done_cb, error_cb, data);
|
||||
#endif
|
||||
|
@ -479,18 +475,16 @@ eio_file_unlink(const char *path,
|
|||
|
||||
l->path = eina_stringshare_add(path);
|
||||
|
||||
if (eio_file_set(&l->common,
|
||||
if (!eio_file_set(&l->common,
|
||||
done_cb,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_unlink,
|
||||
_eio_file_unlink_done,
|
||||
_eio_file_unlink_error))
|
||||
return &l->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
free(l);
|
||||
return NULL;
|
||||
return &l->common;
|
||||
}
|
||||
|
||||
EAPI Eio_File *
|
||||
|
@ -511,18 +505,16 @@ eio_file_mkdir(const char *path,
|
|||
r->path = eina_stringshare_add(path);
|
||||
r->mode = mode;
|
||||
|
||||
if (eio_file_set(&r->common,
|
||||
if (!eio_file_set(&r->common,
|
||||
done_cb,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_mkdir,
|
||||
_eio_file_mkdir_done,
|
||||
_eio_file_mkdir_error))
|
||||
return &r->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
free(r);
|
||||
return NULL;
|
||||
return &r->common;
|
||||
}
|
||||
|
||||
EAPI Eio_File *
|
||||
|
@ -543,18 +535,16 @@ eio_file_chmod(const char *path,
|
|||
r->path = eina_stringshare_add(path);
|
||||
r->mode = mode;
|
||||
|
||||
if (eio_file_set(&r->common,
|
||||
if (!eio_file_set(&r->common,
|
||||
done_cb,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_chmod,
|
||||
_eio_file_mkdir_done,
|
||||
_eio_file_mkdir_error))
|
||||
return &r->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
free(r);
|
||||
return NULL;
|
||||
return &r->common;
|
||||
}
|
||||
|
||||
EAPI Eio_File *
|
||||
|
@ -577,19 +567,14 @@ eio_file_chown(const char *path,
|
|||
c->user = eina_stringshare_add(user);
|
||||
c->group = eina_stringshare_add(group);
|
||||
|
||||
if (eio_file_set(&c->common,
|
||||
if (!eio_file_set(&c->common,
|
||||
done_cb,
|
||||
error_cb,
|
||||
data,
|
||||
_eio_file_chown,
|
||||
_eio_file_chown_done,
|
||||
_eio_file_chown_error))
|
||||
return &c->common;
|
||||
return NULL;
|
||||
|
||||
eina_stringshare_del(path);
|
||||
eina_stringshare_del(user);
|
||||
eina_stringshare_del(group);
|
||||
free(c);
|
||||
|
||||
return NULL;
|
||||
return &c->common;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue