Bug 13547 - vfs_catia macros CATIA_FETCH_FSP_[PRE|POST]_NEXT race condition
Summary: vfs_catia macros CATIA_FETCH_FSP_[PRE|POST]_NEXT race condition
Status: ASSIGNED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: File services (show other bugs)
Version: unspecified
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Ralph Böhme
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-07-26 10:58 UTC by Ralph Böhme
Modified: 2018-09-14 21:10 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Böhme 2018-07-26 10:58:08 UTC
vfs_catia will show unexpected behaviour if two async function A and B complete in the same order:

CATIA_FETCH_FSP_PRE(A)
CATIA_FETCH_FSP_PRE(B)
CATIA_FETCH_FSP_POST(A)
CATIA_FETCH_FSP_POST(B)

The completion of A will restore the translated names on the fsp, so if B is still in flight and uses the names, it uses the wrong, untranslated ones.

It's unlikely with just two operations in flight, but with more in flight, there's a real risk that the first one completes before all subsequent ones completed their work.