file consistency using mmap
How can I achieve file consistency while using mmap? I have a block of code that needs synchronized access across processes (not threads). Using threads, one can regulate access to the mmaped portion of the file by locking it using a mutex. How can I achieve the same using different processes, some of which run in different programs?