Basic Solution File System - BSFS
Loading...
Searching...
No Matches
cp.c File Reference

Implements the cp command for the BSFS filesystem. More...

Functions

int cp (FILE *disk, superblock_t *sb, char **args)
 Copy a file.

Detailed Description

Implements the cp command for the BSFS filesystem.

Copies files within the filesystem.

Function Documentation

◆ cp()

int cp ( FILE * disk,
superblock_t * sb,
char ** args )

Copy a file.

Usage: cp <src> <dst>

Parameters
diskOpen filesystem image.
sbLoaded superblock.
argsSource path in args[1], destination path in args[2].
Returns
1 to continue the REPL.