Commit Graph

171 Commits

Author SHA1 Message Date
Mike Blumenkrantz 4edbb6487c and actually return a value
SVN revision: 68612
2012-03-02 03:01:10 +00:00
Mike Blumenkrantz b21d766d41 prevent stringshare leak
SVN revision: 68611
2012-03-02 03:00:59 +00:00
Cedric BAIL b9fbbaa656 eio: forgotten lstat.
SVN revision: 68499
2012-02-28 09:20:43 +00:00
Cedric BAIL 60132f0727 eio: finish eio fallback monitor.
NOTE: this make Eio now officially in Alpha stage.
API and ABI should remain stable until the coming release.
Only bug fixes and highly needed api change will make in.


SVN revision: 68479
2012-02-27 20:58:26 +00:00
Cedric BAIL 1a82751cf1 eio: start implement fallback monitor.
SVN revision: 68473
2012-02-27 13:20:05 +00:00
Cedric BAIL 4a65416c6a eio: use the newly introduced Eina_Stat.
SVN revision: 68316
2012-02-23 11:46:51 +00:00
Cedric BAIL 0b07301937 eio: improving doc for Eio release.
SVN revision: 68280
2012-02-22 16:30:43 +00:00
Cedric BAIL 76b3828b8f eio: take into account filter for subdirectory to.
SVN revision: 68269
2012-02-22 12:46:51 +00:00
Cedric BAIL 422de4f2e5 eio: change callback prototype.
SVN revision: 68265
2012-02-22 11:51:45 +00:00
Cedric BAIL 59647d1be0 eio: make eio_dir_direct_ls a public API.
SVN revision: 68260
2012-02-22 10:26:39 +00:00
Cedric BAIL 6db00c119d eio: add eio_dir_direct_ls.
SVN revision: 68254
2012-02-22 09:30:43 +00:00
Cedric BAIL 37804c589f eio: forever forgetting to use svn add... sorry.
SVN revision: 68247
2012-02-22 08:34:37 +00:00
Cedric BAIL 11f245ab0b eio: add Eet asynchronous helper.
NOTE: this also make Eet an hard dependency for Eio. I do
think that every one will be using Eet anyway, so I didn't
bother making it optional, but if someone complain to me
with enough cookie, I could change my mind.


SVN revision: 68231
2012-02-21 21:01:22 +00:00
Cedric BAIL ac0c389ff9 eio: fix memory leak in eio_dir_stat_ls.
SVN revision: 68163
2012-02-20 14:06:04 +00:00
Cedric BAIL 1a29f7f309 eio: fix a doc typo.
SVN revision: 67877
2012-02-13 09:06:28 +00:00
Cedric BAIL 7e8b2681c9 eio: fix eio monitor by Guillaume Friloux.
SVN revision: 67501
2012-01-24 16:00:57 +00:00
Cedric BAIL cbd7088c63 eio: fix open use with O_CREATE.
SVN revision: 67394
2012-01-20 16:08:10 +00:00
Cedric BAIL 408b4b5a39 eio: fix build on old debian system.
Patch by Guillaume Friloux <guillaume.friloux@asp64.com>


SVN revision: 67330
2012-01-19 10:26:41 +00:00
Cedric BAIL a49186092e eio: temporary fix when splice is not available.
SVN revision: 67294
2012-01-18 15:45:01 +00:00
Cedric BAIL f185e2d950 eio: use new Eina_File infra to detect IO error during mmap copy.
SVN revision: 66800
2012-01-03 15:00:30 +00:00
Cedric BAIL 76295f136e eio: fix starting of documentation block.
SVN revision: 66701
2011-12-30 15:31:16 +00:00
Cedric BAIL 173ec48730 eio: add some documentation.
SVN revision: 66700
2011-12-30 15:22:42 +00:00
Cedric BAIL ef067cebd6 eio: call eina_file_* on Eina_File pointer.
SVN revision: 66622
2011-12-29 10:46:56 +00:00
Cedric BAIL 70b7b55c42 eio: make eio_file_map_* api more usefull.
SVN revision: 66573
2011-12-27 16:45:07 +00:00
Cedric BAIL 87b31027e0 eio: forgotten svn add.
SVN revision: 66419
2011-12-21 08:34:23 +00:00
Daniel Juyung Seo 9b99fb534c eio: Removed eio_map.c from build temporarily. SPANK CEDRIC!
SVN revision: 66405
2011-12-21 02:38:54 +00:00
Cedric BAIL dbccbce821 eio: add API for eina_file_open and like.
tweet: now Eio can help you load your file assynchronously !


SVN revision: 66397
2011-12-20 17:35:41 +00:00
Cedric BAIL 2e21c6899f eio: move documentation into header like other EFL library.
NOTE: need some help to finish splitting this API in a more meaningfull sense.

TODO: Fix a few FIXME and update monitoring backend to work on most system.


SVN revision: 65840
2011-12-03 13:21:07 +00:00
Cedric BAIL 1a016f1915 eio: don't free internal data.
SVN revision: 63479
2011-09-19 12:47:02 +00:00
Cedric BAIL b2dc1ce8ab eio: use eina xattr helper and add more eio xattr function.
SVN revision: 63441
2011-09-16 14:18:08 +00:00
Cedric BAIL b17b7abfe0 eio: use eina_xattr.
SVN revision: 63438
2011-09-16 11:14:57 +00:00
Cedric BAIL 883cea4caa eio: pack data for a few ms.
SVN revision: 63215
2011-09-05 20:29:01 +00:00
Cedric BAIL 54fcc628bd eio: fix eio_monitor.
Patch by Michael Sans.


SVN revision: 63052
2011-09-01 10:22:00 +00:00
Cedric BAIL d6eea5fcc8 eio: improve eio_dir_stat_ls to work with Eio_Associate and make it faster.
SVN revision: 62939
2011-08-29 11:20:27 +00:00
Cedric BAIL 628e5d7d98 eio: obvious typo !
SVN revision: 62516
2011-08-16 21:13:20 +00:00
Christopher Michael abe52914db EIO: Add UNUSED where missing.
SVN revision: 61623
2011-07-23 23:15:54 +00:00
Mike Blumenkrantz fc64fb5a71 <arrowdodger> Patch to unbreak eio build on systems without xattr: http://intara.org.ru/eio.diff
SVN revision: 60955
2011-07-03 17:58:57 +00:00
Cedric BAIL ceecea1f3e eio: morning speedup, pack feedback together to reduce context switch.
SVN revision: 60935
2011-07-02 11:06:52 +00:00
Cedric BAIL 73edb0433f eio: more xattr support.
SVN revision: 60824
2011-06-29 17:28:55 +00:00
Cedric BAIL 20069184a5 eio: forgotten Eio.h decl.
SVN revision: 60820
2011-06-29 14:16:41 +00:00
Cedric BAIL f3e66ee718 eio: forgot the header.
SVN revision: 60690
2011-06-25 22:52:01 +00:00
Cedric BAIL 2217f284f7 eio: make it possible to know if an Eio_File was cancelled.
SVN revision: 60689
2011-06-25 22:49:01 +00:00
Cedric BAIL 28c4f6f8f5 eio: eio doesn't modify data at all, so make it const.
SVN revision: 60635
2011-06-23 13:29:45 +00:00
Cedric BAIL def2382a91 eio: oops forgot to export that function.
SVN revision: 60601
2011-06-22 17:45:22 +00:00
Cedric BAIL 9035d1f8c0 eio: fix api change.
SVN revision: 60600
2011-06-22 16:09:14 +00:00
Cedric BAIL 19d5fb205a eio: associate data to a file behing listed assynchronously.
SVN revision: 60043
2011-06-07 16:30:10 +00:00
Cedric BAIL d41e80a29c eio: add eio_file_container_get.
SVN revision: 59646
2011-05-24 10:41:37 +00:00
Cedric BAIL fdb32980b5 eio: add forgotten file.
SVN revision: 59149
2011-05-03 13:07:26 +00:00
Cedric BAIL fb2310d5a4 eio: add beginning of xattr support.
SVN revision: 59146
2011-05-03 10:36:51 +00:00
Cedric BAIL 74fb408eb1 eio: use eina refcount.
SVN revision: 59040
2011-04-29 16:24:14 +00:00
Cedric BAIL fc27a465a3 eio: also copy xattr when available.
SVN revision: 59015
2011-04-28 16:45:45 +00:00
Cedric BAIL 1a699607f6 eio: add inotify backend and fix api.
Note: API/ABI of Eio_Monitor could be considered usable and need feedback.
Still lacking of proper fallback and windows port.


SVN revision: 58953
2011-04-27 10:27:07 +00:00
Cedric BAIL b558cbc07e eio: add Eio_Monitor API.
Not yet working. Need to handle message, add fallback and windows support.


SVN revision: 58907
2011-04-25 17:04:46 +00:00
Cedric BAIL 25959fb6ed eio: fix eio shadow warning.
SVN revision: 58906
2011-04-25 17:01:26 +00:00
Cedric BAIL 79dbc39b5c eio: destroy leaf before root.
SVN revision: 58732
2011-04-19 15:27:21 +00:00
Cedric BAIL 8fe5c5ce54 eio: make it easy to filter content during eio_dir_* operation.
SVN revision: 57631
2011-03-09 16:21:11 +00:00
Cedric BAIL fb188326a9 eio: correctly fix large file support.
SVN revision: 57629
2011-03-09 15:04:01 +00:00
Cedric BAIL fc2aaf9935 eio: fix issue on 32bits system.
SVN revision: 57626
2011-03-09 14:53:55 +00:00
Cedric BAIL c6cb315e35 eio: add eio_dir_stat_ls.
SVN revision: 57129
2011-02-17 15:59:07 +00:00
Michael BOUCHAUD 29b6b151b1 eio: don't forget to init the list of links. Avoid segfault with eio_dir_copy and maybee(surely) others function
SVN revision: 55848
2011-01-04 16:58:58 +00:00
Michael BOUCHAUD 947b8db665 eio: move 'typedef enum' after 'enum' to compil with g++ (from Mikael Sans)
SVN revision: 55372
2010-12-08 14:35:37 +00:00
Cedric BAIL 581a3c66e2 * eio: fix API to match the rest of the EFL API.
SVN revision: 54504
2010-11-12 14:08:01 +00:00
Cedric BAIL e61f8560ea * ecore: break Ecore_Thread API once and for all to make it consistent.
SVN revision: 54502
2010-11-12 13:28:19 +00:00
Cedric BAIL 7e9c729ce2 * eio: fix recursion by detecting link and recreating them.
SVN revision: 54123
2010-11-03 12:35:21 +00:00
Cedric BAIL 058deb3c1f * eio: add eio_file_stat_ls.
SVN revision: 54106
2010-11-02 17:08:00 +00:00
Cedric BAIL eb4cd21f0c * eina: remove dirent so apps don't rely on non portable code.
SVN revision: 54103
2010-11-02 15:11:05 +00:00
Cedric BAIL 57aa3f4147 * eio: fix shadow symbol.
SVN revision: 54033
2010-10-30 12:06:21 +00:00
Carsten Haitzler 46abf6fc81 use new type member.
SVN revision: 54018
2010-10-30 05:59:39 +00:00
Cedric BAIL 61bb247e13 * eio: oops forgotten file.
SVN revision: 53990
2010-10-29 13:06:58 +00:00
Cedric BAIL 09d09fe0ce * eio: inline accessor.
SVN revision: 53988
2010-10-29 12:58:04 +00:00
Cedric BAIL 9b279fa367 * eio: break Eio error callback API to match the rest of the API.
SVN revision: 53986
2010-10-29 12:36:43 +00:00
Cedric BAIL b519dad7b4 * eio: fix doc.
SVN revision: 53964
2010-10-28 15:57:48 +00:00
Cedric BAIL c0cf78da54 * eio: add small helper.
SVN revision: 53962
2010-10-28 14:50:24 +00:00
Cedric BAIL a5abd3d320 * eio: add eio_file_ls() tutorial.
SVN revision: 53915
2010-10-27 12:30:12 +00:00
Vincent Torri 9c5ce8345e [eio] add check on some functions (will be used later) and
add native win32 mutex code.

Question: with pthread, if a mutex is initialized with
PTHREAD_MUTEX_INITIALIZER, should it be destroyed  with
pthread_mutex_destroy() ?

SVN revision: 53772
2010-10-22 16:44:30 +00:00
Vincent Torri c2d941930c [eio] check if threads, grp.h and fchmod() are available
SVN revision: 53723
2010-10-21 17:51:21 +00:00
Vincent Torri ab84f4da58 [eio] _GNU_SOURCE already defined in config.h
SVN revision: 53721
2010-10-21 17:18:35 +00:00
Vincent Torri 600053d7a9 [eio] improve documentation layout and add a tutorial for
eio_dir_copy()

SVN revision: 53704
2010-10-21 05:03:23 +00:00
Vincent Torri 3a5d43ea9c [eio] reorganize code like eina, clean up doc
SVN revision: 53688
2010-10-20 19:17:30 +00:00
Cedric BAIL 06ea9c415d * eio: add eio_file_chmod and eio_file_chown.
SVN revision: 53678
2010-10-20 16:42:45 +00:00
Cedric BAIL ff69a72f47 * eio: add eio_dir_unlink.
SVN revision: 53664
2010-10-20 13:48:13 +00:00
Cedric BAIL 80cbbc23a7 * eio: more doxy fix.
SVN revision: 53658
2010-10-20 12:20:06 +00:00
Cedric BAIL ab4a53f091 * eio: add eio_dir_move.
SVN revision: 53657
2010-10-20 12:09:58 +00:00
Cedric BAIL 10ff95e654 * eio: small doxy fix.
SVN revision: 53656
2010-10-20 12:08:56 +00:00
Cedric BAIL f3b720812e * e, eio: fix ecore_thread_run breakage.
SVN revision: 53371
2010-10-13 17:46:02 +00:00
Cedric BAIL 75577ee618 * eio: remove unecessary call.
SVN revision: 53365
2010-10-13 16:45:45 +00:00
Cedric BAIL a1c4588d64 * eio: fix use of ecore_thread_*run.
SVN revision: 53348
2010-10-13 10:59:33 +00:00
Gustavo Sverzut Barbieri c30d8f6af6 init threads as we use them!
SVN revision: 53342
2010-10-13 06:14:56 +00:00
Gustavo Sverzut Barbieri 83270f5f45 seems that the other way was not enough.
I was still reaching uninitialized usage and it does make sense, as
the parent thread could be postponed until the new is started, then
the scanner/worker thread hits an error (ie: directory permission
denied) and it is cancelled before the main thread had time to get the
thread attribution (common->thread).

I'd like someone to look at it. Probably this is NOT the right way to
fix. Likely what we should do is send a "ready! start working" command
from the main thread to the worker thread and avoid such thing.


==5848== Conditional jump or move depends on uninitialised value(s)
==5848==    at 0x42808CD: ecore_thread_cancel (ecore_thread.c:534)
==5848==    by 0x4238558: eio_file_thread_error (eio_single.c:35)
==5848==    by 0x42368FC: _eio_file_direct_heavy (eio_file.c:78)
==5848==    by 0x42800F3: _ecore_feedback_job (ecore_thread.c:247)
==5848==    by 0x4280398: _ecore_thread_worker (ecore_thread.c:317)
==5848==    by 0x41FE16AE: start_thread (in /lib/libpthread-2.11.2.so)
==5848==    by 0x41F3295D: clone (in /lib/libc-2.11.2.so)
==5848==  Uninitialised value was created by a heap allocation
==5848==    at 0x400793F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
==5848==    by 0x4237991: eio_file_direct_ls (eio_file.c:566)
==5848==    by 0x8051C81: ephoto_directory_thumb_add (ephoto_directory_thumb.c:131)
==5848==    by 0x804D4AB: _ephoto_thumb_dir_icon_get (ephoto_thumb_browser.c:75)
==5848==    by 0x405F4C8: _item_realize (elm_gengrid.c:807)
==5848==    by 0x405FE77: _item_place (elm_gengrid.c:980)
==5848==    by 0x40610F6: _pan_calculate (elm_gengrid.c:1199)
==5848==    by 0x418CA38: evas_call_smarts_calculate (evas_object_smart.c:843)
==5848==    by 0x41B23B2: evas_render_updates_internal (evas_render.c:971)
==5848==    by 0x41B3DA1: evas_render_updates (evas_render.c:1414)
==5848==    by 0x42E4550: _ecore_evas_x_render (ecore_evas_x.c:406)
==5848==    by 0x42DDD2C: _ecore_evas_idle_enter (ecore_evas.c:47)




SVN revision: 53340
2010-10-13 05:33:16 +00:00
Gustavo Sverzut Barbieri d037d75281 fix unitialized error.
==17972== Use of uninitialised value of size 4
==17972==    at 0x42918DB: ecore_thread_cancel (ecore_thread.c:536)
==17972==    by 0x4249558: eio_file_thread_error (eio_single.c:35)
==17972==    by 0x42478FC: _eio_file_direct_heavy (eio_file.c:78)
==17972==    by 0x42910F3: _ecore_feedback_job (ecore_thread.c:247)
==17972==    by 0x4291398: _ecore_thread_worker (ecore_thread.c:317)
==17972==    by 0x41FE16AE: start_thread (in /lib/libpthread-2.11.2.so)
==17972==    by 0x41F3295D: clone (in /lib/libc-2.11.2.so)
==17972==  Uninitialised value was created by a heap allocation
==17972==    at 0x400793F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
==17972==    by 0x4248991: eio_file_direct_ls (eio_file.c:566)
==17972==    by 0x8050B8E: ephoto_directory_thumb_add (ephoto_directory_thumb.c:127)
==17972==    by 0x4061570: _item_realize (elm_gengrid.c:807)
==17972==    by 0x4061E27: _item_place (elm_gengrid.c:980)
==17972==    by 0x4062875: _pan_calculate (elm_gengrid.c:1199)
==17972==    by 0x419DA38: evas_call_smarts_calculate (evas_object_smart.c:843)
==17972==    by 0x41C33B2: evas_render_updates_internal (evas_render.c:971)
==17972==    by 0x41C4DA1: evas_render_updates (evas_render.c:1414)
==17972==    by 0x42F5550: _ecore_evas_x_render (ecore_evas_x.c:406)
==17972==    by 0x42EED2C: _ecore_evas_idle_enter (ecore_evas.c:47)
==17972==    by 0x428C85F: _ecore_idle_enterer_call (ecore_idle_enterer.c:129)




SVN revision: 53336
2010-10-13 03:56:24 +00:00
Carsten Haitzler 8cde3d4ba6 ok... bad eio hackers. you know setting things like gnu_source and
file_offset_bits .. CHANGES the size of structs like dirent? so if u
do it differently in different c files... u end up with.. GASP
different structs with different sizes! dont do this. unify everything
into eio_private.h so its at least CONSISTENT for eio's internals.



SVN revision: 53322
2010-10-13 00:26:12 +00:00
Vincent Torri 0304666261 improve doc. Now, cedric, it's up to you :p
SVN revision: 53308
2010-10-12 14:59:30 +00:00
Cedric BAIL cb8d2cf2f9 * eio: improve allocation code for eio_file_direct_ls.
SVN revision: 53262
2010-10-11 12:40:20 +00:00
Gustavo Sverzut Barbieri 98e0d9f009 safer and louder about errors.
SVN revision: 53204
2010-10-08 20:14:21 +00:00
Eduardo de Barros Lima 9910581b1c Eio: No need to #define _GNU_SOURCE
SVN revision: 53165
2010-10-07 21:06:54 +00:00
Cedric BAIL 71ae9cd4e5 * eio: reduce code duplication.
SVN revision: 53094
2010-10-06 09:54:00 +00:00
Cedric BAIL 96172a4066 * eio: fix coding style, the other way.
SVN revision: 53071
2010-10-05 16:57:51 +00:00
Cedric BAIL b3d7e3423f * eio: add eio_dir_copy.
Little example on how to use it :
#include <Ecore.h>
#include <Eio.h>

static void
_test_notify_cb(void *data, const Eio_Progress *info)
{
   switch (info->op)
     {
      case EIO_FILE_COPY:
         printf("[%s] %f%%\n", info->dest, info->percent);
         break;
      case EIO_DIR_COPY:
         printf("global [%li/%li] %f%%\n", info->current, info->max, info->percent);
         break;
     }
}

static void
_test_done_cb(void *data)
{
   printf("copy done\n");
   ecore_main_loop_quit();
}

static void
_test_error_cb(int error, void *data)
{
   fprintf(stderr, "error: [%s]\n", strerror(error));
   ecore_main_loop_quit();
}

int
main(int argc, char **argv)
{
   Eio_File *cp;

   if (argc != 3)
     {
        fprintf(stderr, "eio_cp source_file destination_file\n");
        return -1;
     }

   ecore_init();
   eio_init();

   cp = eio_dir_copy(argv[1], argv[2],
                     _test_notify_cb,
                     _test_done_cb,
                     _test_error_cb,
                     NULL);

   ecore_main_loop_begin();

   eio_shutdown();
   ecore_shutdown();

   return 0;
}

	NOTE: be aware that it's your duty to provide the "right target".
	Meaning that copying to '.' will copy the content directly inside
	'.' and not in a subdirectory.


SVN revision: 53069
2010-10-05 16:46:41 +00:00
Cedric BAIL f352ce15bc * eio: follow efl coding style.
SVN revision: 53066
2010-10-05 15:58:19 +00:00
Cedric BAIL a1ea2ed6cd * eio: more code to share.
SVN revision: 53065
2010-10-05 15:32:24 +00:00