Page MenuHomePhabricator

efl_ui_exact_model: fix always true condition

Authored by stefan_schmidt on Sep 20 2019, 6:06 AM.



The tbuf binbuffer has already been freed the line above, which means
this condition would always be true as !tbuf would always result in true.
As a result the rest of the function has never been executed.

Depends on D10045

Diff Detail

rEFL core/efl
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.
stefan_schmidt created this revision.Sep 20 2019, 6:06 AM

It seems that this patch has no reviewers specified. If you are unsure who can review your patch, please check this wiki page and see if anyone can be added:

zmike requested changes to this revision.Sep 20 2019, 6:12 AM
zmike added a subscriber: zmike.

This is not quite correct: if tbuf is NULL on L84-85, this is still a valid case.

A better change would be to evaluate !tbuf separately before L84.

This revision now requires changes to proceed.Sep 20 2019, 6:12 AM
stefan_schmidt edited the summary of this revision. (Show Details)
zmike accepted this revision.Sep 20 2019, 7:11 AM
This revision is now accepted and ready to land.Sep 20 2019, 7:11 AM
This revision was automatically updated to reflect the committed changes.