Vault 7: Projects
This publication series is about specific projects related to the Vault 7 main publication.
Preconditions
The drive containing the file must be mounted.
Parameters
Parameters Description
filePtr Pointer to the file object to initialize
pathName The path/name of the file to open.
mode The mode in which the file should be opened. Specified by
inclusive or'ing parameters from
FILEIO_OPEN_ACCESS_MODES.
Function
int FILEIO_Open ( FILEIO_OBJECT * filePtr, const uint16_t * pathName, uint16_t mode)
1.7.1.2.4 FILEIO_Remove Function
Deletes a file.
File
fileio_lfn.h
Syntax
int FILEIO_Remove(const uint16_t * pathName);
Module
Long File Name Library API
Returns
• If Success: FILEIO_RESULT_SUCCESS
• If Failure: FILEIO_RESULT_FAILURE
• Sets error code which can be retrieved with FILEIO_ErrorGet. Note that if the path cannot be resolved, the error will be
returned for the current working directory.
• FILEIO_ERROR_INVALID_ARGUMENT - The path could not be resolved.
• FILEIO_ERROR_WRITE_PROTECTED - The device is write-protected.
• FILEIO_ERROR_INVALID_FILENAME - The file name is invalid.
• FILEIO_ERROR_DELETE_DIR - The file being deleted is actually a directory (use FILEIO_DirectoryRemove)
• FILEIO_ERROR_ERASE_FAIL - The erase operation failed.
• FILEIO_ERROR_FILE_NOT_FOUND - The file entries for this file are invalid or have already been erased.
• FILEIO_ERROR_WRITE - The updated file data and entry could not be written to the device.
• FILEIO_ERROR_DONE - The directory entry could not be found.
• FILEIO_ERROR_BAD_SECTOR_READ - The directory entry could not be cached.
Description
Deletes the file specified by pathName.
Preconditions
The file's drive must be mounted and the file should exist.
1.7 Library Interface MLA - File I/O Library Help File I/O Layer
34
Protego_Release_01_05-Related-OEM-Documentation-MLA_v2013_12_20-help_mla_fileio.pdf