jos/user/faultnostack.c

13 lines
229 B
C
Raw Normal View History

2018-10-06 06:52:47 -07:00
// test user fault handler being called with no exception stack mapped
#include <inc/lib.h>
void _pgfault_upcall();
void
umain(int argc, char **argv)
{
sys_env_set_pgfault_upcall(0, (void*) _pgfault_upcall);
*(int*)0 = 0;
}