Add symlink function (not yet implemented in ext2)
This commit is contained in:
@@ -54,6 +54,12 @@ off_t lseek(int fd, off_t offset, int whence);
|
||||
/// @return
|
||||
int unlink(const char *path);
|
||||
|
||||
/// @brief Creates a symbolic link.
|
||||
/// @param linkname the name of the link.
|
||||
/// @param path the entity it is linking to.
|
||||
/// @return 0 on success, a negative number if fails and errno is set.
|
||||
int symlink(const char *linkname, const char *path);
|
||||
|
||||
/// @brief Wrapper for exit system call.
|
||||
/// @param status The exit status.
|
||||
extern void exit(int status);
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
/// @file unlink.c
|
||||
/// @brief
|
||||
/// @copyright (c) 2014-2023 This file is distributed under the MIT License.
|
||||
/// See LICENSE.md for details.
|
||||
|
||||
#include "sys/unistd.h"
|
||||
#include "sys/errno.h"
|
||||
#include "system/syscall_types.h"
|
||||
|
||||
_syscall2(int, symlink, const char *, linkname, const char *, path)
|
||||
Reference in New Issue
Block a user