storage_file_open

Function storage_file_open 

Source
pub unsafe extern "C" fn storage_file_open(
    file: *mut File,
    path: *const c_char,
    access_mode: FS_AccessMode,
    open_mode: FS_OpenMode,
) -> bool
Expand description

Open an existing file or create a new one.

The calling code MUST call storage_file_close() even if the open operation had failed.

§Arguments

  • file - pointer to the file instance to be opened.
  • path - pointer to a zero-terminated string containing the path to the file to be opened.
  • access_mode - access mode from FS_AccessMode.
  • open_mode - open mode from FS_OpenMode

§Returns

true if the file was successfully opened, false otherwise.