Fix #8205 : Deprecate file mode update when calling dumpFile