1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-18 11:35:06 +00:00

Implement utime() along with a naive /bin/touch.

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.
This commit is contained in:
Andreas Kling 2018-12-19 21:14:55 +01:00
parent e03d341615
commit 038d8641f9
22 changed files with 122 additions and 22 deletions

View file

@ -72,7 +72,7 @@ private:
virtual InodeIdentifier root_inode() const override;
virtual bool write_inode(InodeIdentifier, const ByteBuffer&) override;
virtual InodeMetadata inode_metadata(InodeIdentifier) const override;
virtual bool set_mtime(InodeIdentifier, dword timestamp) override;
virtual int set_atime_and_mtime(InodeIdentifier, dword atime, dword mtime) override;
virtual InodeIdentifier create_inode(InodeIdentifier parentInode, const String& name, Unix::mode_t, unsigned size, int& error) override;
virtual ssize_t read_inode_bytes(InodeIdentifier, Unix::off_t offset, size_t count, byte* buffer, FileDescriptor*) const override;
virtual InodeIdentifier create_directory(InodeIdentifier parentInode, const String& name, Unix::mode_t, int& error) override;