path: root/header_checks
diff options
authorCarsten Haitzler (Rasterman) <>2019-02-12 19:54:22 +0000
committerCarsten Haitzler (Rasterman) <>2019-02-12 19:54:35 +0000
commita57c7f751023fe1d1edeabbf8683574ac7497e5e (patch)
tree8803287a8502e666ee9f1762d850e9c9e978506c /header_checks
parente908142da6e27a8e38f29895770d5d40f8587498 (diff)
Revert command line array object because it's broken by design
Revert "ecore: get rid of commands in efl_task." This reverts commit 616381e9cfed41b83fef039b0e38c09b41fd3d7f. Revert "ecore: here comes a command line object" This reverts commit 48e5684b3c37b337edd7004e68fc0690b58a84e6. 1. this is broken: EOLIAN static const char* _efl_core_command_line_command_get(const Eo *obj EINA_UNUSED, Efl_Core_Command_Line_Data *pd) { return eina_strdup(pd->string_command); } it returns a const char * BUT it duplicates it on return. no. a big fat honking NO. return a char * or don't duplicate. pick. 2. _efl_core_command_line_command_array_set() is broken by design. it accepts an array of strings, but the strings are owned by the caller who creates the array (requiring they free them up themselves after this call) but the array becomes owned by the callee. the code here frees the incoming array but doesn't care about the string content of it. it's leak heaven waiting to happen (or bugs when someone wants to access the array they create to walk it to free the strings they put into it after it is set). i brought this up and it was dismissed. now exactly he issue i brought up is there with mixed ownership and the added complexity as well as transfer of some ownership but not others. go back and think about this so it isn't broken by design.
Diffstat (limited to 'header_checks')
0 files changed, 0 insertions, 0 deletions