f8f5968753
libc: Define EOVERFLOW and make every dummy errno value unique
2022-11-09 11:37:32 +01:00
1300b8f5ee
libc: Add stubs for signal() and raise()
2022-11-09 11:37:08 +01:00
bbc7a7338c
libc: Add fpclassify
2022-11-09 11:36:52 +01:00
59e03d0799
libc: Add DT_* macros to dirent.h
2022-11-09 11:36:41 +01:00
accf7ee417
libc: Add unimplemented st_nlink field
2022-11-09 11:36:21 +01:00
033c41cbd7
Kernel: Rework the uid/gid system to make it compliant
2022-11-09 09:54:07 +01:00
99429baed2
tools: make moon.sym readable only by root
...
We don't want everyone peeking at kernel symbols.
2022-11-09 09:11:00 +01:00
bb26996cb7
Add a script to check whether all project sources are properly formatted
2022-11-08 19:17:21 +01:00
98da473fdc
Run clang-format
2022-11-08 19:07:43 +01:00
0c1ffedd3f
Add a script to run clang-format on all source files
2022-11-08 19:07:16 +01:00
327b60566c
Use different color for luna builds than for port builds
2022-11-08 18:04:58 +01:00
054d5a8bb4
Build system: Prettify build
2022-11-08 18:03:43 +01:00
00f9981f51
Userspace: Enable dead code stripping
2022-11-08 17:39:34 +01:00
6f72f92493
Kernel: Start preparing for recursive paging
2022-11-08 17:12:59 +01:00
2230ebd969
Wrap math.h around builtins
2022-11-06 21:37:00 +01:00
472192bcf2
libc: Define LC_NUMERIC
2022-11-06 20:47:16 +01:00
78ee6ce34a
libc: Stub out scanf()
2022-11-06 20:47:07 +01:00
c9e20fd38e
Why are there so many errno values
2022-11-06 20:46:34 +01:00
2eeef9581f
libc: Add strxfrm()
2022-11-06 19:56:36 +01:00
2e9348181d
Tests: Add tests for strcmp() and strncmp()
2022-11-06 19:51:56 +01:00
5d94525c7a
Kernel: Figure out why a program is misbehaving
2022-11-06 18:12:25 +01:00
c6ce7a5358
libc: Add bsearch (with a test!!)
2022-11-06 17:34:35 +01:00
1025248cc7
libc: Add qsort (with a test!!)
2022-11-06 17:16:08 +01:00
44815b08c7
Kernel: Use copy_from_user() and copy_to_user() in read/write
...
This is huge. Finally, we can do proper reads/writes with invalid addresses, or big buffers.
2022-11-06 15:19:23 +01:00
04ae97a6ec
libc: Add difftime()
2022-11-06 15:09:38 +01:00
2980ee3973
libc: Make fread() and fwrite() less awkward
2022-11-06 14:53:05 +01:00
88011fc162
init: Use fread() properly
2022-11-06 14:52:50 +01:00
40b078e0a2
libc: Make fread/fwrite return the number of items read/written instead of the number of bytes
2022-11-06 14:46:22 +01:00
d7692a7f59
libc: Rename fold() to lowercase() in strcasecmp and strncasecmp
2022-11-06 14:45:58 +01:00
da182f1c2f
libc: Add mktemp() and mkdtemp(), along with a test for mktemp
2022-11-05 18:07:45 +01:00
b2fb740d99
Kernel: Refuse to mkdir any directory named . or ..
2022-11-05 12:09:01 +01:00
b78f6f269d
Kernel: Omit displaying KernelHeap's buffer location in the log
2022-11-05 11:59:00 +01:00
cedefaf93d
libc: Exit with -errno if we fail initialization
2022-11-05 11:56:31 +01:00
9ab3ab7c40
Kernel: Show init's exit status before restarting
2022-11-05 11:56:16 +01:00
b63a9f5ba9
Kernel: Improve strdup_from_user and add copy to and from user
...
Still a bit funky, that's why we're not using it in read() and write() yet.
2022-11-05 11:54:55 +01:00
67f536cf91
Kernel: Split number-parsing code into a separate file
2022-11-05 10:50:58 +01:00
d0efc106b0
Kernel: Add UBSAN (Undefined Behaviour Sanitizer)
2022-11-05 10:47:18 +01:00
ffcaac0ca3
Kernel: Add validate_user_write() and validate_user_read()
...
Not at copy_from_user and copy_to_user yet, but an improvement over blindly using physical memory.
2022-11-04 22:46:48 +01:00
cbc2e76082
Remove the .elf suffix from the kernel filename
2022-11-03 20:44:37 +01:00
e5b2641019
Kernel: Enforce W^X when loading executables
...
From now on, if an executable contains segments that
want to be loaded as both writable and executable,
we refuse and abort with ENOEXEC.
2022-11-03 20:28:54 +01:00
2c08de044f
Kernel, libc: Add support for querying the framebuffer's scanline via ioctl()
2022-11-03 20:20:22 +01:00
71633e264f
Kernel: Make the serial port writable for everyone :)
2022-11-03 17:13:32 +01:00
979569eb5a
Ports: Refactor the NASM port's package script a bit
2022-11-03 17:06:27 +01:00
3b86f87c76
libc: Support %i in printf()
...
Which is the same as %d.
2022-11-03 16:53:19 +01:00
2cfefc25cc
libc: Stub out rename()
2022-11-03 16:52:41 +01:00
0fd31698b2
Kernel: Accept not opened file descriptors in dup2()
...
This involves renaming the descriptor_from_fd function to the more appropriately named
open_descriptor_from_fd (since we check if the descriptor was opened and error out otherwise),
and creating a new function that does not verify that the file descriptor was opened.
2022-11-03 16:52:21 +01:00
7afbff08b6
apps: Add a little screen utility
...
It tells you the resolution of your screen :)
2022-11-02 21:00:23 +01:00
249c79f8a3
Kernel, libc: Add ioctl()
...
Right now, only the framebuffer supports this system call, to query its dimensions.
2022-11-02 20:59:42 +01:00
feab66c0d3
Kernel: Remove the paint() system call
...
That was a very old one from back in the old days. Now that the framebuffer is finally a device file,
and it can be memory-mapped by user programs for more performance,
this syscall is MORE than obsolete.
2022-11-02 20:35:06 +01:00
8f2308c80d
Kernel: Implement mmap-able device files (regular files are not mmap-able yet)
2022-11-02 20:24:07 +01:00