bfsUnlink()
PROTOTYPE
#include <bfs.h>
int bfsUnlink(const char *name);
DESCRIPTION
bfsUnlink() deletes the closed file specified by name.
If successful, bfsUnlink() returns 0. Otherwise, it sets errno and returns -1.
ERROR CODES
| EBUSY | The file specified by name is currently open. |
| EFAULT | name equals NULL or the empty string. |
| ENOENT | The specified file does not exist. |
| other | An I/O error occurred while deleting the file. |
EXAMPLE
if ((cmd == '0') || (cmd == '5'))
{
puts("Erasing \"bfs/boot.bin\"");
if (bfsUnlink("boot.bin"))
perror("bfs/boot.bin");
}