1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 17:17:44 +00:00

Implement /proc/PID/vm.

Refactored SyntheticFileSystem to maintain an arbitrary directory structure.
ProcFileSystem creates a directory entry in /proc for each new process.
This commit is contained in:
Andreas Kling 2018-10-26 17:42:12 +02:00
parent 10347b9ae8
commit a32b3a3ddf
15 changed files with 217 additions and 39 deletions

View file

@ -16,6 +16,26 @@ static void testWeakPtr();
int main(int, char**)
{
StringImpl::initializeGlobals();
{
struct entry {
String s;
};
HashMap<unsigned, entry> tab;
tab.set(1, { "one" });
tab.set(2, { "two" });
tab.set(3, { "three" });
tab.set(4, { "four" });
tab.remove(1);
tab.remove(2);
tab.remove(3);
for (auto& it : tab) {
printf("%s\n", it.value.s.characters());
}
return 0;
}
{
CircularQueue<int, 4> queue;
queue.dump();