Hi, On Wed, 17 Jun 2015, fredvs wrote:
> But how to check if a file has executable permission (and if not, change it > with fpchmod(thefile S_IRWXU);) ? >From the top of my head: fpStat(), and in the returned stat structure, look for the mode field (or st_mode?). There are more useful bits in there. There is also fpFStat() and fpLStat() (for symlinks). There are also several S_* constants in BaseUnix unit for easier testing of various permission combinations. Charlie _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal