summaryrefslogtreecommitdiffstats
path: root/cpukit/libfs (follow)
Commit message (Collapse)AuthorAgeFilesLines
* imfs: Fix index underrun when extending empty file4.11Christian Mauderer2022-04-071-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently the following sequence causes a endless loop when extending an IMFS file: - Create a file with zero length and close it. - Make sure nearly no allocatable memory is left. - Open the file and write enough data into it that more than the remaining memory will be used. In that case when extending the IMFS file, the file currently need zero blocks. If allocating enough new blocks fails, the already allocated new blocks will be freed again. The comparison of block>=old_blocks that has been used prior to this patch compared two unsigned numbers. If old_blocks was zero, the comparison of these two numbers always evaluated to true. This patch frees the last block in a separate step to avoid this problem. Note: This patch is a backport of 43119193ef0f3fef6bc01a391ccda8a97cfc149c from RTEMS master. It only contains the bugfix. Adding a test case has been skipped because that part of the patch didn't apply without problems and is not really relevant for fixing the bug. Fixes #2353
* rfs: Remove erroneous call of rtems_disk_release()Sebastian Huber2018-08-101-1/+0
| | | | | | | The function rtems_rfs_buffer_sync() erroneously calls rtems_disk_release(). This screws up the reference counting of the disk. Close #3494.
* dosfs: Allow creating a file with similar name.Christian Mauderer2017-12-071-3/+7
| | | | | | | | If there is already a file with a long file name it isn't possible to create a second file which has a name that ends on the first files name (for example ets.beam and sets.beam). This patch fixes that. Close #3258.
* dosfs: Fix files with same name as volume name.Christian Mauderer2017-12-051-1/+2
| | | | | | | Take care that a file in the root directory with the same name as the volume name can be found. Close #3257.
* dosfs: Fix fat_file_update()Sebastian Huber2017-09-061-5/+3
| | | | | | Do not update the non-existant meta-data of the root directory. Close #2944.
* dosfs: Fix find name next entry preparationSebastian Huber2017-09-061-25/+50
| | | | Close #2964.
* dosfs: Fix msdos_dir_read()Sebastian Huber2017-09-061-27/+28
| | | | | | Set a proper name buffer length for each converter invocation. Close #2987.
* dosfs: Fix file name searchSebastian Huber2017-03-211-17/+7
| | | | | | | Do not use our long file name entry count to optimize the file name search. The Unicode comparison must be taken into account. Close #2939.
* dosfs: Fix race condition msdos_dir_read()Sebastian Huber2017-03-211-5/+5
| | | | | | Obtain file system instance lock before member access. Close #2937.
* dosfs: Rename fat_entries to lfn_entriesSebastian Huber2017-03-211-20/+20
| | | | | The name "fat_entries" for long file name directory entries is quite misleading.
* dosfs: Fix long file name paddingSebastian Huber2017-03-211-3/+3
| | | | Close #2934.
* dosfs: msdos_filename_utf8_to_short_name_for_saveSebastian Huber2017-03-211-15/+10
| | | | Simplify.
* dosfs: Fix msdos_add_file()Sebastian Huber2017-03-211-245/+155
| | | | | | Make sure that long file names work accross cluster boundaries. Close #2929.
* dosfs: Simplify msdos_add_file()Sebastian Huber2017-03-211-4/+2
| | | | Update #2929.
* dosfs: Add and use msdos_lfn_checksum()Sebastian Huber2017-03-213-22/+25
| | | | Update #2929.
* dosfs: Simplify fat_file_open()Sebastian Huber2017-03-211-3/+1
| | | | Update #2929.
* dosfs: Simplify msdos_creat_node()Sebastian Huber2017-03-211-21/+14
| | | | Update #2929.
* dosfs: Fix fat_file_write()Sebastian Huber2017-03-213-30/+11
| | | | | | | | Remove forced overwrite which leads to file data corruption. The logic to determine a forced overwrite was fundamentally broken. For simplity, disable this feature. Close #2622.
* dosfs: Fix msdos_utf8_normalize_and_fold()Sebastian Huber2017-03-211-2/+2
| | | | | | | | It is all right in case the result uses the full destination buffer. Without this fix the handling of a maximum 8.3 short file name is broken. Close #2928.
* dosfs: Fix FAT32 formatterSebastian Huber2017-02-281-2/+2
| | | | | | | | | The second FAT entry contains a bit to indicate if the FAT32 filesystem is not dirty and a bit to indicate if there was no IO error. Set both bits for a fresh filesystem. This prevents a warning if mounted on Windows. Update #2913.
* dosfs: Directories should have a file size of 0Sebastian Huber2017-02-281-1/+6
| | | | Update #2755.
* Remove old CVS keywordsNick Withers2017-02-152-2/+2
| | | | Close #2388.
* dosfs: Fix msdos_find_file_in_directory()Sebastian Huber2017-02-141-1/+1
| | | | | | For a filename match the entry must match without anything remaining. Update #2908.
* fat: Fix for invalid cluster sizesSebastian Huber2016-05-201-1/+3
| | | | | | | A cluster size > 32KiB resulted in an infinite loop in fat_init_volume_info() due to an integer overflow. Update #2717.
* untar: do not exit with error when created directory already exists.Pavel Pisa2015-11-231-1/+17
| | | | | | | | | | | | | | The problem exists for both RTEMS untar implementations and their variants: Untar_FromMemory(), Untar_FromFile() and rtems_tarfs_load(). If filesystem object already exists at extracted directory path then if it is directory, creation is ignored. Attempt to delete/unlink object and make directory is tried for other cases. This simple approach problem reported in ticket fixes #2413. Behavior follows GNU tar and BSD tar practice for directories but much more work is required to achieve full semantics of the full featured tar implementation still.
* RFS: Fix resource leakSebastian Huber2015-10-261-0/+2
| | | | Update #2433.
* Respect 2^32 - 1 B NFSv2 maximum file sizeNick Withers2015-08-061-3/+45
| | | | closes #2384
* nfsclient: Use an interrupt lockSebastian Huber2015-06-191-21/+29
|
* dosfs: avoid buffer-overread. closes #2292.Gedare Bloom2015-05-271-2/+2
|
* jffs2: Move into separate librarySebastian Huber2015-05-272-1/+18
| | | | | | | In case the zlib compression was used, then the librtemscpu.a depended on libz.a. To avoid a GCC patch or complicated link flags move the JFFS2 support into a separate library to use a simple "-ljffs2 -lz" to link the executable.
* dosfs: Fix warning fixSebastian Huber2015-04-271-1/+1
|
* score: Delete Thread_queue_Control::stateSebastian Huber2015-04-231-25/+0
| | | | | Use a parameter for _Thread_queue_Enqueue() instead to reduce memory usage.
* imfs.h: Add cast to remove warning for pointer/integer size mismatchJoel Sherrill2015-03-241-1/+1
|
* IMFS: NUL-terminate name returned by readdir()Sebastian Huber2015-03-171-2/+5
|
* cpukit/libdl/rtl-obj-comp.c: Use correct printf() specificationJoel Sherrill2015-03-171-2/+2
|
* IMFS: don't strlen() an unterminated string in IMFS_dir_read().Jamie Iles2015-03-161-1/+1
| | | | | | | | | a43a3466 (IMFS: Implement variable length node names) introduced a changed to IMFS_jnode_t from being a null terminated string to a separate unterminated string and length. IMFS_dir_read() was still performing a strlen() on this unterminated string though and when doing an 'ls' in the fileio example I saw that some filenames had garbage suffixes.
* rfs: cast minor to uintptr_t to truncate explicitlyGedare Bloom2015-03-161-2/+2
|
* Fix more Doxygen typosJoel Sherrill2015-03-061-3/+2
|
* Fix a number of minor Doxygen formatting issuesJoel Sherrill2015-03-061-5/+5
|
* dosfs: Fix warningsSebastian Huber2015-03-057-18/+12
|
* IMFS: Fix warningSebastian Huber2015-03-051-1/+1
|
* IMFS: Include missing header fileSebastian Huber2015-03-051-0/+1
|
* IMFS: Fix warningSebastian Huber2015-03-051-1/+1
|
* IMFS: Fix copy on write for linfilesSebastian Huber2015-02-201-0/+3
|
* IMFS: Silence warningSebastian Huber2015-02-181-1/+1
|
* IMFS: Implement variable length node namesSebastian Huber2015-02-155-25/+46
| | | | This reduces the average node size and adds more flexibility.
* IMFS: Add CONFIGURE_IMFS_DISABLE_READDIRSebastian Huber2015-02-147-140/+172
|
* IMFS: Add fine grained configurationSebastian Huber2015-02-127-185/+9
| | | | | | | | | | | | | | | | | | Remove miniIMFS. Statically initialize the root IMFS. Add configuration options to disable individual features of the root IMFS, e.g. o CONFIGURE_IMFS_DISABLE_CHOWN, o CONFIGURE_IMFS_DISABLE_FCHMOD, o CONFIGURE_IMFS_DISABLE_LINK, o CONFIGURE_IMFS_DISABLE_MKNOD, o CONFIGURE_IMFS_DISABLE_MOUNT, o CONFIGURE_IMFS_DISABLE_READLINK, o CONFIGURE_IMFS_DISABLE_RENAME, o CONFIGURE_IMFS_DISABLE_RMNOD, o CONFIGURE_IMFS_DISABLE_SYMLINK, o CONFIGURE_IMFS_DISABLE_UNMOUNT, and o CONFIGURE_IMFS_DISABLE_UTIME.
* IMFS: Allow static initialization of FS infoSebastian Huber2015-02-126-100/+118
|
* IMFS: Fix resource leakSebastian Huber2015-02-121-1/+9
|