FF_Close()

From FullFAT
Jump to: navigation, search


Closes the FF_FILE object specified, and cleans up all resources used. Furthermore, FF_Close() guarantees that all data is saved to disk.

Contents

Prototype

FF_ERROR FF_Close(FF_FILE *pFile);

Back to API.

Parameters

pFile

FF_FILE object from the FF_Open() function.

Return Value

The function returns an error code, that can be passed to FF_GetErrMessage(). FF_ERR_NONE on success.

Example

#include "fullfat.h"
 
FF_ERROR Error;
 
Error = FF_Close(pFile);
 
if(Error) {
    printf("Error closing file: %s\n", FF_GetErrMessage(Error));
}

Back to API.

See Also

Personal tools