eina: fix a possible race condition during eina_file_close.
authorCedric Bail <cedric.bail@samsung.com>
Wed, 20 Nov 2013 04:02:37 +0000 (13:02 +0900)
committerCedric Bail <cedric.bail@samsung.com>
Wed, 20 Nov 2013 04:02:37 +0000 (13:02 +0900)
commit7e8fb93206ee95945bb757267832537c13ab4287
tree8ff6ef8d854f28ac0dbcb1ebc86d7df076c03ccf
parent0146e3dacc87189eba100bf5489498290ec9f86b
eina: fix a possible race condition during eina_file_close.

The lock on the main hash was taken to late (after we took the decision
to remove the targeted Eina_File from the cache), this means it was possible
to get an Eina_File from the cache that was going to be removed. This patch
attempt to fix that potential race condition.

Hopefully should fix T461.
ChangeLog
NEWS
src/lib/eina/eina_file.c
src/lib/eina/eina_file_common.c
src/lib/eina/eina_file_common.h
src/lib/eina/eina_file_win32.c
src/tests/eina/eina_test_file.c