mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-29 14:14:45 +03:00
Unbreak crashy user process test.
This commit is contained in:
parent
3253a23b91
commit
b40c851fce
Notes:
sideshowbarker
2024-07-19 18:39:46 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/b40c851fce8
@ -30,7 +30,7 @@
|
||||
#define TEST_VFS
|
||||
//#define STRESS_TEST_SPAWNING
|
||||
//#define TEST_ELF_LOADER
|
||||
//#define TEST_CRASHY_USER_PROCESSES
|
||||
#define TEST_CRASHY_USER_PROCESSES
|
||||
|
||||
system_t system;
|
||||
|
||||
@ -49,6 +49,22 @@ void banner()
|
||||
kprintf("\n");
|
||||
}
|
||||
|
||||
#ifdef TEST_CRASHY_USER_PROCESSES
|
||||
static void user_main() NORETURN;
|
||||
static void user_main()
|
||||
{
|
||||
DO_SYSCALL_A3(0x3000, 2, 3, 4);
|
||||
// Crash ourselves!
|
||||
char* x = reinterpret_cast<char*>(0xbeefbabe);
|
||||
*x = 1;
|
||||
HANG;
|
||||
for (;;) {
|
||||
// nothing?
|
||||
Userspace::sleep(1 * TICKS_PER_SECOND);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
static void undertaker_main() NORETURN;
|
||||
static void undertaker_main()
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user