mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-21 10:19:03 +03:00
038d8641f9
This synchronous approach to inodes is silly, obviously. I need to rework it so that the in-memory CoreInode object is the canonical inode, and then we just need a sync() that flushes pending changes to disk.
17 lines
287 B
C++
17 lines
287 B
C++
#include <stdio.h>
|
|
#include <utime.h>
|
|
#include <sys/types.h>
|
|
|
|
int main(int argc, char** argv)
|
|
{
|
|
if (argc != 2) {
|
|
fprintf(stderr, "usage: touch <path>\n");
|
|
return 1;
|
|
}
|
|
int rc = utime(argv[1], nullptr);
|
|
if (rc < 0)
|
|
perror("utime");
|
|
return 0;
|
|
}
|
|
|