Commit Graph

36 Commits

Author SHA1 Message Date
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 d0f668a6ba * eet: fix bad allocation case triggered by edje new file format.
Bad news, I also discovered in the same time that we introduced an
	API/ABI breakage in 1.3.0. This patch does prevent it from coming
	again, sadly, it imply an ABI break that I didn't find a proper
	way to work around. So recompile eet and all the program that use
	it after that commit.


SVN revision: 51080
2010-08-13 15:21:52 +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
Carsten Haitzler f7019f134d formatting. <- uncrustify
SVN revision: 50698
2010-07-31 01:54:48 +00:00
Carsten Haitzler 926db95c54 testing uncrustify on eet. this shall be standard efl formatting from
now on. you may run indent on code and convert to your own formatting
if you want.. but all code MUST be "uncrustified" before being
cxommitted to svn or before generating patches. time to get the
formatting monster under control.



SVN revision: 50563
2010-07-28 01:45:57 +00:00
Boris Faure 2ac69e62f0 eet: typo. Patch by Vincent Torri
SVN revision: 50445
2010-07-23 07:32:34 +00:00
Vincent Torri 8351950dee Add native Windows thread support instead of using pthread
(less overhead). On other OS, pthread is still used by default.
Pass --enable-win32-threads to activate thread support on
Windows.


SVN revision: 50262
2010-07-15 06:34:32 +00:00
Cedric BAIL 6df28268ca * eet: add support for eet_alias.
SVN revision: 49939
2010-06-29 16:20:23 +00:00
Cedric BAIL a5aaf1723b * eet: Add EET_G_VARIANT and EET_G_UNION.
This are the basis for a new edje file format.
	Next to come EET_G_INHERIT.


SVN revision: 48201
2010-04-21 14:00:24 +00:00
Cedric BAIL d0ec0f0b96 * eet: improve tests suite coverage of signature print code.
SVN revision: 48056
2010-04-16 15:27:50 +00:00
Cedric BAIL 2cc28483e6 * eet: Improve coverage by tests suite and don't leak file in /tmp.
SVN revision: 48054
2010-04-16 14:43:07 +00:00
Cedric BAIL 4b55e9f4eb * eet: let eet create the temporary test file.
SVN revision: 47880
2010-04-09 17:22:45 +00:00
Cedric BAIL aa015979bb * eet: Add Eet_Connection.
This will help people that want to use Eet over any kind of link.


SVN revision: 47688
2010-04-02 13:51:00 +00:00
Cedric BAIL 57f1862163 * eet: reduce amount of stress test with many thread.
SVN revision: 47686
2010-04-02 13:48:07 +00:00
Cedric BAIL 649760234c * eet: Reintroduce eet cache lock fix.
This version also fix a bug when file wasn't an eet file.


SVN revision: 47237
2010-03-15 14:47:51 +00:00
Carsten Haitzler 73a9612f2c also revert - on3e of these 2 - or both, causes a deadlock in e. see my
previous commit log.



SVN revision: 46918
2010-03-07 03:01:55 +00:00
Cedric BAIL c285985eeb * eet: Fix clearcache race condition.
Patch by Adam Simpkins.


SVN revision: 46891
2010-03-05 17:19:03 +00:00
Cedric BAIL 8aadedaaec * eet: Better tests suites.
SVN revision: 45443
2010-01-22 18:01:54 +00:00
Cedric BAIL f0fd392e9f * eet: MASSIV REWRITE OF EET_DATA !
Eet_Data now use more common code when doing dump/decode. This
	provide new functionnality, you can now do a list/array/hash of string.
	make test/coverage are now passing without problem with 79% of the code
	covered (mainly need to update test suite for fixed point). This rewrite
	is also a first for script langage to directly manipulate Eet_Data (more
	patch comming). It's also a cleanup of the Eet_Node API that could now
	be used just fine.

	Note: Previous dump will not be compatible with this update, but
	Eet_Data will.

	PS: I did some extensive test here with enlightenment, elementary_test,
	editje, elixir and eyelight. If you experience any weird behaviour that
	could be linked with eet_data (well almost anything that use the EFL),
	please report to me as soon as possible.


SVN revision: 45059
2010-01-12 12:38:59 +00:00
Vincent Torri fe0f51ab21 set the size of the test images explicitely
SVN revision: 44536
2009-12-18 09:32:51 +00:00
Cedric BAIL f285d6ad16 * eet: Fix tests suite.
SVN revision: 40036
2009-04-14 09:26:15 +00:00
Cedric BAIL febbf0ab0f Make password callback work (PKCS8 support), fix minor bugs and add more tests.
SVN revision: 37625
2008-11-14 17:34:51 +00:00
Cedric BAIL 0f36b190f1 Add crypto support to eet.
GNUTLS support by Arnaud de Turckheim <quarium@gmail.com>.


SVN revision: 37603
2008-11-13 16:31:13 +00:00
Cedric BAIL d0fe4b4f3f * Bug fix :
- Array layout would be broken or worse not possible to reload at all if you put NULL pointer in it.
  - Array of string now work.
  - Fix a double free issue with array on double load.

* Add the test to detect this case.



SVN revision: 37051
2008-10-24 14:06:40 +00:00
Cedric BAIL 04edb0cbec * Fix Hash of String bug.
* Add a test case for it.



SVN revision: 37029
2008-10-23 14:41:04 +00:00
Cedric BAIL 5c096e9ddb * Fix bug with string included in a list found by Viktor Kojouharov.
* Add a test case for that one.

Problem was simple type inlining in complex structure (like list/hash/array) is
just a hack. We are creating a subtype with the data chunk. That work with INT
or SHORT for example, but not with STRING because it's a pointer to a STRING and
not directly the STRING. This result in a double pointer dereferencing where it
shouldn't. In fact STRING is not really like other simple data type. So we
should handle it differently.

Still need to fix Array and Hash.



SVN revision: 37024
2008-10-23 13:12:33 +00:00
Cedric BAIL 4391aa6f08 Remove eet data type from the test suite.
SVN revision: 36861
2008-10-20 15:10:46 +00:00
Cedric BAIL 2127e5c551 Remove more compiler warning.
SVN revision: 36614
2008-10-13 11:51:10 +00:00
Cedric BAIL 9515e85a80 Remove warning.
SVN revision: 36562
2008-10-10 09:28:07 +00:00
Cedric BAIL 46b7796946 Add signature support in eet.
You can use eet -s to sign a eet file and eet -c to check its signature. The
current code doesn't check any certificate trust path, only if the signature
match the certificate and that the certificate could be loaded. If that's not
the case, eet_open will fail. If the file is not signed, eet_open will just
continue to succeed.



SVN revision: 35882
2008-09-08 09:19:57 +00:00
Cedric BAIL d59f9b7d6c Fix a little bug in the test and do a real write test.
SVN revision: 35255
2008-07-30 14:10:36 +00:00
Cedric BAIL 9dddec7f09 Fix wrongly stored image when compressed size is bigger than uncompressed. Fix bug #523.
SVN revision: 35204
2008-07-24 13:25:18 +00:00
Cedric BAIL d16456e061 Fix the bug with EET_T_UNKNOW/EET_G_UNKNOWN that did break the CVS.
Add a test to detect this bug and caught another one, not yet solved
with dump/undump of EET_T_UNKNOW/EET_G_UNKNOWN.


SVN revision: 34925
2008-06-27 15:26:53 +00:00
Cedric BAIL 86e4286496 This patch is a starting point for cleaning up eet_data.c.
It also add EET_G_VAR_ARRAY and EET_G_ARRAY thanks to
turran's (jorgeluis.zapata@gmail.com) last year patch.
Of course we have test code for it and eet_data.c code
is covered around 90.1%. We need to test with garbage
data for increasing it more.

WARNING: API of eet_data_descriptor_element_add is not
clean and we will need to break it, if we want a clean
API. So this is the plan for version 2.0.0.


SVN revision: 34919
2008-06-26 15:47:25 +00:00
Cedric BAIL 2b37d10029 Add eet_data_image_read_to_surface and eet_data_image_decode_to_surface.
This functions provide a way to support tiles with eet. They also give the
possibility to directly decompress eet image inside an engine surface.


SVN revision: 34725
2008-06-02 16:01:18 +00:00
Cedric BAIL 0f5070cf40 Introducing unit test in EFL using cvs check library for the test
suite (http://check.sourceforge.net/) and lcov from cvs also for the
coverage accounting (http://ltp.sourceforge.net/coverage/lcov.php).
   This first set provide an overall coverage rate for src/lib 2111
of 2607 lines (81.0%) for eet. And it helped in finding and fixing
the bugs of the last three days.


SVN revision: 34591
2008-05-16 15:07:03 +00:00