Commit Graph

42 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
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
Sebastian Dransfeld 7bf67b046b key and value aren't const
SVN revision: 50809
2010-08-04 12:33:58 +00:00
Sebastian Dransfeld 0a3f53c3b1 Check for null return
SVN revision: 50808
2010-08-04 12:33:48 +00:00
Sebastian Dransfeld 1576311af3 alloc the right amount of mem
sizeof(char) is 1, and sizeof(char *) is wrong for strings

SVN revision: 50782
2010-08-03 19:31:24 +00:00
Sebastian Dransfeld 69d0626265 use alloca for in function mem
SVN revision: 50781
2010-08-03 19:31:14 +00:00
Sebastian Dransfeld 31c6799a7e goto not needed anymore with alloca
SVN revision: 50496
2010-07-25 20:38:28 +00:00
Sebastian Dransfeld b76d9490dc Fix errors reported by clang
SVN revision: 50492
2010-07-25 20:25:40 +00:00
Sebastian Dransfeld 31f73712f3 efreet: stringshare
SVN revision: 47668
2010-04-01 19:41:03 +00:00
Sebastian Dransfeld 3b546516c3 efreet: fancy alloca include in common header
SVN revision: 47664
2010-04-01 19:32:41 +00:00
Sebastian Dransfeld f72d4f9342 Eet cache for efreet desktop
SVN revision: 46726
2010-03-01 18:16:32 +00:00
Sebastian Dransfeld 6f2038b6e7 Create path to file if not exists
Fixes bug #513

SVN revision: 45990
2010-02-08 19:27:58 +00:00
Sebastian Dransfeld 0423e1ea99 Formatting
SVN revision: 45865
2010-02-04 09:12:35 +00:00
Sebastian Dransfeld af22e351b2 Fix compiler warnings
SVN revision: 45199
2010-01-15 20:51:23 +00:00
Davide Andreoli a59b9655b2 *Efreet_Ini: Add a new API call:
EAPI void efreet_ini_key_unset(Efreet_Ini *ini, const char *key);

With this you can remove keys from ini files



SVN revision: 43245
2009-10-24 09:23:51 +00:00
Davide Andreoli c9533023ad Efreet_ini: remove ending withespaces
SVN revision: 43244
2009-10-24 09:02:56 +00:00
Vincent Torri 285297dcdd * API break: _shutdown() functions return an int, now
* simplify a bit and fix init/shutdown functions



SVN revision: 42996
2009-10-10 06:19:13 +00:00
Cedric BAIL 05126826a3 * efreet: Use eina_log.
Patch from Matthieu.


SVN revision: 42599
2009-09-21 16:36:29 +00:00
Gustavo Sverzut Barbieri 992936af22 Update to match new EINA init/shutdown.
SVN revision: 42301
2009-09-06 22:23:04 +00:00
Gustavo Sverzut Barbieri 44d66495ca more valgrind fixes on efreet.
SVN revision: 41121
2009-06-20 06:50:01 +00:00
Vincent Torri 1bf086809e * move header files in efree_provate.h to the source files
* fix compilation on Windows XP (not sure that Windows CE port is needed...)

note that, as ecore_exe is not available on Windows, some code have
been disables for that platform in src/lib/efreet_desktop.c. Also, a new Evil
version should be used (not in svn yet)

The compilation on Windows is needed for Ewl (icon and mime)



SVN revision: 40257
2009-04-20 23:20:40 +00:00
Gustavo Sverzut Barbieri ab2e35127f Fix most compiler & clang warnings.
Left warnings regarding signed and unsigned comparison since
eina_list_count() returns unsigned, can use a cast in this return, but
not big deal for now.


By: Luis Felipe Strano Moraes & myself.



SVN revision: 39260
2009-02-26 22:35:38 +00:00
Cedric BAIL 6978e98dc6 * estickies,
* etk,
	* PROTO/exalt,
	* E-MODULES-EXTRA/diskio,
	* E-MODULES-EXTRA/drawer,
	* E-MODULES-EXTRA/penguins,
	* E-MODULES-EXTRA/slideshow,
	* E-MODULES-EXTRA/mail,
	* E-MODULES-EXTRA/forecasts,
	* E-MODULES-EXTRA/iiirk,
	* E-MODULES-EXTRA/places,
	* e,
	* ewl,
	* ecore,
	* elitaire,
	* entrance,
	* e_dbus,
	* efreet: Here we go, move from Ecore_List to Eina_List.

	NOTE: This patch is huge, I did test it a lot, and I hope nothing is
	broken. But if you think something change after this commit, please
	contact me ASAP.


SVN revision: 39200
2009-02-25 11:03:47 +00:00
Cedric BAIL 35540b3a3b This commit is huge. I did test it a lot on my computer, and it run fine here.
But is so big i fear i could have broken some piece of code. So report any wrong
behaviour to me (cedric on #edevelop).

So moving e17 and efreet to eina_hash. With a little efreet API break so they
must come together.


SVN revision: 38185
2008-12-17 15:33:43 +00:00
Cedric BAIL 01befd2b67 Switch ecore_strings to eina_stringshare.
SVN revision: 36676
2008-10-15 14:48:03 +00:00
Miculcy Brian cf33734edf enable failback when empty localisation string are found
SVN revision: 35184
2008-07-22 13:30:25 +00:00
Carsten Haitzler 43821d36e4 * add efreet garbage data check
* remove printfs that clutter output
* add efreet file type check - only parse regular files
* chekc mmap returns correctly for MAP_FAILED results
* edje has some stubs for adding script-only objecvts - but nothing useful
right now


SVN revision: 34689
2008-05-29 02:00:04 +00:00
Dan Sinclair cecac6f9d6 - add comments
- fix formatting


SVN revision: 34512
2008-05-08 14:22:21 +00:00
Carsten Haitzler 69a1a1a2e0 slackdood seems to report creating new apps is broken. this may be it.
SVN revision: 34508
2008-05-08 07:11:48 +00:00
Dan Sinclair 3322ce3b12 - deal with blank lines outside the invalid file checks
- this fixes the warning about a missing = sign
- you can have a blank value set on a key
  - this fixes the warnings about invalid key=value pairs
- formatting changes


SVN revision: 34496
2008-05-07 04:14:45 +00:00
Dan Sinclair 3624e4e923 - if we can't parse the INI file we can't set ini->data so return NULL
instead of an invalid ini file


SVN revision: 34493
2008-05-07 03:04:58 +00:00
Dan Sinclair 74b5878da7 - fix warnings
SVN revision: 34490
2008-05-07 02:16:50 +00:00
Cedric BAIL 14a01955ef Switch efreet_ini_parse to use mmap instead of fopen. Small speed improvements and little code cleanup.
FIXME: If people wonder we are loosing 50% of efreet time inside ecore_hash_* and ecore_string_*.


SVN revision: 34482
2008-05-06 15:56:40 +00:00
Carsten Haitzler 9e6e6a86e2 efreet segv maker removed. bad unescaping causing segvs! fixxored.
SVN revision: 34445
2008-05-03 09:25:43 +00:00
Sebastian Dransfeld d15dcd181c EAPI
SVN revision: 32339
2007-11-04 09:32:35 +00:00
Sebastian Dransfeld 9506bc06df Revert erronous changes.
SVN revision: 31716
2007-09-14 22:22:29 +00:00
doursse 6a7494bba7 remove trailing spaces
SVN revision: 31638
2007-09-06 16:15:10 +00:00
doursse 5209a42671 in efreet_ini_parse:
* move the opening of the file after the creation of the hash table and
  return it on failure
* return NULL when the hash table can not be created
* add the binary flag when opening a file for compatibility with Windows

in efreet_new, return NULL when efreet_ini_parse returns NULL (mem alloc
failure)


SVN revision: 31637
2007-09-06 16:05:35 +00:00
Peter Wehrfritz cd20fbc9d9 *API BREAK* see the discussion in the mailing list. misc and e_modules will follow
SVN revision: 30970
2007-07-25 17:01:04 +00:00
Sebastian Dransfeld 8691b711a3 formatting.
SVN revision: 29849
2007-05-04 17:45:26 +00:00
Sebastian Dransfeld d4b0093826 Efreet style.
SVN revision: 29348
2007-04-04 12:00:40 +00:00
ningerso 9e363d07e9 Initial import of efreet, an implementation of the freedesktop icon and menu
specs.


SVN revision: 28214
2007-02-03 13:05:30 +00:00