When enabling encryption for a file while compacting it, if the data or index file had the ctNOENCRYP extended file mode bit set, encryption was not enabled for the file. The file compact now turns off the no-encrypt option when the caller requests that the file is to be encrypted.