On Mon, January 16, 2017 2:34 pm, I previously wrote: > The oldschool way of opening files using the system unit (no sysutils) > has the filemode variable.. > > system.FileMode := fmOpenRead; ... > Assign(... > Rewrite(... > > > > Can this be used with file locking/sharing OR-ed options like: > fmShareCompat fmShareDenyNone fmShareDenyRead fmShareDenyWrite > fmShareExclusive > > Or does file locking/sharing require using sysutils unit with fileopen: > http://www.freepascal.org/docs-html/rtl/sysutils/fileopen.html >
To answer my own question... Looking into the fpc rtl sources I found that DoFileLocking is inside sysutils, so likely system unit (old school handling of files) cannot be used with locking at this stage. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal