Index: fusl/src/stdio/rename.c |
diff --git a/fusl/src/stdio/rename.c b/fusl/src/stdio/rename.c |
new file mode 100644 |
index 0000000000000000000000000000000000000000..04c90c01343a4b84beb5cf56b348e5d5041905ed |
--- /dev/null |
+++ b/fusl/src/stdio/rename.c |
@@ -0,0 +1,12 @@ |
+#include <stdio.h> |
+#include <fcntl.h> |
+#include "syscall.h" |
+ |
+int rename(const char *old, const char *new) |
+{ |
+#ifdef SYS_rename |
+ return syscall(SYS_rename, old, new); |
+#else |
+ return syscall(SYS_renameat, AT_FDCWD, old, AT_FDCWD, new); |
+#endif |
+} |