eina: fix CID 1106340: Logically dead code (DEADCODE) reported by coverity.

This commit is contained in:
Cedric BAIL 2013-10-14 13:22:45 +02:00
parent c7c08b0e3e
commit 1c1b48ca64
1 changed files with 2 additions and 1 deletions

View File

@ -608,10 +608,11 @@ eina_spinlock_take(Eina_Spinlock *spinlock)
{
if (errno == EBUSY) sched_yield();
else if (errno == EDEADLK) return EINA_LOCK_DEADLOCK;
else return EINA_LOCK_FAIL;
}
} while (t != 0);
return t ? EINA_LOCK_FAIL : EINA_LOCK_SUCCEED;
return EINA_LOCK_SUCCEED;
#else
return eina_lock_take(spinlock);
#endif