ecore_evas_extn: do not double close fd in case of memory starvation.

In case eina_stringshare_add was failing it could lead to a double close
on lockfd. This was reported by coverity: CID1039885

@fix
This commit is contained in:
Cedric BAIL 2014-07-30 03:47:31 +02:00
parent 048d52f086
commit ca2e2af522
1 changed files with 1 additions and 0 deletions

View File

@ -158,6 +158,7 @@ _extnbuf_lock_file_set(Extnbuf *b, const char *file)
if (b->am_owner) return EINA_FALSE;
if (b->lock) eina_stringshare_del(b->lock);
if (b->lockfd >= 0) close(b->lockfd);
b->lockfd = -1;
if (!file)
{
b->lock = NULL;