Commit Graph

198 Commits

Author SHA1 Message Date
Cedric BAIL 57997619c9 * eina: fix eina_tiler_iterator_new API to be consistent with the
rest of the iterator API and usage.

	WARNING !!! THIS IS REALLY BAD BUT FOR CONSISTENCY, I THINK THAT THIS
	API BREAK WAS NEEDED. IN FACT IT'S MORE AN ABI BREAK AS IT WILL NOT
	TRIGGER WARNING OR ERROR IN CURRENT PROGRAM USING
	eina_tiler_iterator_new SO YOU ARE WARNED !

	Reported by playya <frederik.sdun@googlemail.com>.


SVN revision: 54153
2010-11-04 14:53:00 +00:00
Cedric BAIL 0e7accd2ba * eina: don't bench ecore anymore as it's to slow.
SVN revision: 53346
2010-10-13 09:34:40 +00:00
Lucas De Marchi a95105a888 Implement function to drop priority of current thread
This function is useful for libraries like ecore and evas that have to
set some worker threads. The first thing these threads should do is to
call this function, so the main thread might continue running without
the worker threads interrupting it too much.



SVN revision: 52651
2010-09-23 20:38:48 +00:00
Lucas De Marchi 33dcb37afe Fix common misspellings
The following misspellings were fixed:

asociated->associated
convertion->conversion
exemple->example
existant->existent
immediatly->immediately
isnt->isn't
loosing->losing
memeber->member
occured->occurred
occurence->occurrence
occurences->occurrences
ocurred->occurred
recomended->recommended
sucess->success
teh->the
tiem->time
usefull->useful




SVN revision: 51962
2010-09-08 03:21:16 +00:00
Mike Blumenkrantz e892d9a2bf cleanups for eina_module_list_get type change
vtorri SPANK SPANK SPANK!!!


SVN revision: 51828
2010-09-02 03:28:04 +00:00
Mike Blumenkrantz 7a5677ad43 finish removing threadsafe stuff
SVN revision: 51687
2010-08-27 21:41:03 +00:00
Lucas De Marchi d8002ff386 Revert and re-apply badnull patch
Revert previous patch generated by badnull.cocci script, and apply the new one.
The main difference is that assert and assert-like functions are not touched
anymore.




SVN revision: 51650
2010-08-26 01:34:13 +00:00
Vincent Torri 402c60b18b get the verbosity with the env variable CK_VERBOSITY. By default, nothing is changed.
SVN revision: 51535
2010-08-22 17:58:01 +00:00
Lucas De Marchi 5a8a8c9014 Convert (hopefully) all comparisons to NULL
Apply badzero.cocci, badnull.coci and badnull2.cocci

This should convert all cases where there's a comparison to NULL to simpler
forms. This patch applies the following transformations:

code before patch               ||code after patch
===============================================================

return a == NULL;                 return !a;

return a != NULL;                 return !!a;

func(a == NULL);                  func(!a);

func(a != NULL);                  func(!!a);

b = a == NULL;                    b = !a;

b = a != NULL;                    b = !!a;

b = a == NULL ? c : d;            b = !a ? c : d;

b = a != NULL ? c : d;            b = a ? c : d;


other cases:

a == NULL                         !a
a != NULL                         a




SVN revision: 51487
2010-08-21 13:52:25 +00:00
Cedric BAIL e6f9cee051 * eina: fix structure content to be more futur proof and reduce
risk of ABI breakage.


SVN revision: 51390
2010-08-19 12:02:28 +00:00
Cedric BAIL f75eab161d * eina: remove thread safe data type for now. They will be back !
SVN revision: 51179
2010-08-16 09:32:09 +00:00
Cedric BAIL aa3728b3f5 * eina: preparing clean removal of eina threadsafe data type.
SVN revision: 51173
2010-08-16 09:00:42 +00:00
Mike Blumenkrantz 689a24559c add threadsafety for hashes
SVN revision: 51106
2010-08-14 03:05:35 +00:00
Cedric BAIL a6645cb746 * eina: fix eina array threadsafe version.
Also add iterator and accessor ability to walk threadsafely.
	Rename EINA_EACH to EINA_EACH_CB to match other callback cast.


SVN revision: 51000
2010-08-11 14:32:30 +00:00
Mike Blumenkrantz cbf7f7b58a array threadsafing wip, get rid of dumb undefineds from earlier
SVN revision: 50959
2010-08-10 11:57:20 +00:00
Mike Blumenkrantz 56a0bd9396 implement threadsafety for arrays, alter all eina internal array usage to (hopefully) be threadsafe
call eina_threads_init() to enable this if you have pthread rwlock support (posix 2001)
note some function prototypes have lost const on array params to allow locking
WARNING: you should NOT call eina_threads_shutdown unless you are positive that you will not use any arrays which were created while threadsafe mode were enabled, and vice versa.  Failing to adhere to this warning WILL result in either deadlocks or memory leaks.


SVN revision: 50951
2010-08-10 03:26:15 +00:00
Lucas De Marchi 0a4617ae38 FORMATTING
* Remove vim modelines:
 find . -name '*.[chx]' -exec sed -i '/\/\*$/ {N;N;/ \* vim:ts/d}' \{\} \;
 find . -name '*.[chx]' -exec sed -i '/\/[\*\/] *vim:/d' \{\} \;

* Remove leading blank lines:
 find . -name '*.[cxh]' -exec sed -i '/./,$!d'

If you use vim, use this in your .vimrc:
set ts=8 sw=3 sts=8 expandtab cino=>5n-3f0^-2{2(0W1st0



SVN revision: 50816
2010-08-04 16:57:32 +00:00
Brett Nash d3655ee501 Beef up the strncpy test
SVN revision: 50740
2010-08-02 09:44:06 +00:00
Brett Nash 4efb9d70af Add ustr tests.
SVN revision: 50737
2010-08-02 09:43:51 +00:00
Carsten Haitzler 15c71af0a5 fix formatting also
SVN revision: 50577
2010-07-28 03:03:25 +00:00
Carsten Haitzler bed21c315d errrr... hmmm why did this change?
SVN revision: 50574
2010-07-28 02:48:11 +00:00
Carsten Haitzler ddc6ba2c2a uncrustify eina.
SVN revision: 50573
2010-07-28 02:37:05 +00:00
Tom Hacohen 6b69189efd Eina: Added ustringshare and binshare tests.
Fixed a small bug in binshare (in the length function).
Moved some debug messages around.

SVN revision: 50541
2010-07-27 11:43:37 +00:00
Vincent Torri 9f425c5892 make it compile on Windows
SVN revision: 50219
2010-07-13 13:08:14 +00:00
Vincent Torri fd59d59930 newline --
SVN revision: 50218
2010-07-13 12:49:37 +00:00
Lucas De Marchi 62391791bf Move ifdefs
Much better and readable, with less code and the same result. Moreover this
makes some parsers not to kill themselves.



SVN revision: 50069
2010-07-06 17:20:30 +00:00
Vincent Torri b131dfc65c export symbols on Windows
SVN revision: 49915
2010-06-28 05:15:44 +00:00
Vincent Torri d2e2f572a1 export symbols on Windows
SVN revision: 49913
2010-06-28 05:11:28 +00:00
Vincent Torri ae6a698ea1 on Windows, path delemiter is backslash and not slash
SVN revision: 49912
2010-06-28 05:06:28 +00:00
Cedric BAIL cf128ea0e4 * eina: improve quadtree to support more stuff needed by evas.
SVN revision: 49784
2010-06-21 13:17:09 +00:00
Mike Blumenkrantz fa5fa3c7e7 comment out nonexistent functions
SVN revision: 48922
2010-05-16 20:17:07 +00:00
Cedric BAIL 6caac50006 * eina: improve QuadTree API.
SVN revision: 48482
2010-04-30 17:04:28 +00:00
Cedric BAIL d239b6c524 * eina: oops forgotten file.
SVN revision: 48425
2010-04-29 17:30:18 +00:00
Cedric BAIL 9367b5f7c7 * eina: Add first version of a Quad Tree data type.
NOTE: consider the API experimental and subject to change.


SVN revision: 48424
2010-04-29 17:21:14 +00:00
Cedric BAIL 49c0a1e6e2 * eina: add tests for eina fixed point sin/cos functions.
SVN revision: 48423
2010-04-29 17:08:24 +00:00
Gustavo Sverzut Barbieri 54b0b06c1e Better resize rotine, linear instead of double.
Increment in steps linearly instead of doubling them, otherwise it
will get to maximum limit of 4096 too soon.

Also replace the loop with simple math.



SVN revision: 46585
2010-02-27 16:41:24 +00:00
Gustavo Sverzut Barbieri 08127ecc3e eina_str speedups.
* eina_str_split() now does the minimum number of passes and
   allocations. The first pass figures out the string size (strlen())
   and number of delimiters, so we can allocate the exact number of
   elements in array. The second repeats the loop copying elements to
   string and also setting them to the result array.

 * eina_str_split_full() is a variation of eina_str_split() that
   returns also the number of elements in array, in the case you need
   to pre-allocate another array to copy.

 * eina_strlen_bounded() is introduced to limit strlen() results, this
   is used in has_prefix and has_suffix, but possibly other use cases
   where string must be of a maximum size as we don't do useless
   iterations;



SVN revision: 46547
2010-02-27 03:42:27 +00:00
Gustavo Sverzut Barbieri bba70aef2e eina_strbuf_insert variants and fix leak with eina_strbuf_append_escaped()
SVN revision: 46521
2010-02-26 21:33:17 +00:00
Gustavo Sverzut Barbieri f32672764d add eina_strbuf_append_length()
SVN revision: 46516
2010-02-26 20:09:36 +00:00
Gustavo Sverzut Barbieri 926789e247 fix warnings.
SVN revision: 46498
2010-02-26 00:38:35 +00:00
Vincent Torri b87e1d6fae * -fno-strict-aliasing is checked at linked time (to make sure
that it is disabled for suncc)
 * add old evas data types in tests. Tell me if you encounter problems
   with them


SVN revision: 46136
2010-02-13 12:32:22 +00:00
Sebastian Dransfeld 9df3524f3a Good coverage for strbuf
SVN revision: 46101
2010-02-11 21:53:00 +00:00
Sebastian Dransfeld 8f5d0ecfb4 Don't timeout
SVN revision: 46099
2010-02-11 21:30:57 +00:00
Sebastian Dransfeld e699b67248 Only test built mempools
SVN revision: 46096
2010-02-11 21:21:22 +00:00
Sebastian Dransfeld a28ba1876e More tests for strbuf
SVN revision: 46095
2010-02-11 21:21:12 +00:00
Sebastian Dransfeld 0ed3fb726b Tests for strbuf
SVN revision: 46089
2010-02-11 20:08:52 +00:00
Sebastian Dransfeld 3d6a752111 Add simple test for strbuf
Need more

SVN revision: 46024
2010-02-09 21:05:47 +00:00
Gustavo Sverzut Barbieri 191d87d78a eina log level utilities.
couple of functions that are useful outside and should be fast.



SVN revision: 45996
2010-02-09 01:43:58 +00:00
Gustavo Sverzut Barbieri f7cd9786f1 eina log parameters getters and setters.
allow external users to check or set flags that are initialized based
on environment variables such as EINA_LOG_COLOR_DISABLE.



SVN revision: 45995
2010-02-09 00:52:00 +00:00
Boris Faure c6f9892e63 Fix some more warnings caused by -Wshadow
SVN revision: 45522
2010-01-24 13:53:32 +00:00