diff options
| author | manuel <manuel@mausz.at> | 2012-03-26 12:54:45 +0200 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2012-03-26 12:54:45 +0200 |
| commit | b5f0874cd96ee2a62aabc645b9626c2749cb6a01 (patch) | |
| tree | 1262e4bbe0634de6650be130c36e0538240f4cbf /pintos-progos/tests/userprog/create-bad-ptr.c | |
| download | progos-b5f0874cd96ee2a62aabc645b9626c2749cb6a01.tar.gz progos-b5f0874cd96ee2a62aabc645b9626c2749cb6a01.tar.bz2 progos-b5f0874cd96ee2a62aabc645b9626c2749cb6a01.zip | |
initial pintos checkin
Diffstat (limited to 'pintos-progos/tests/userprog/create-bad-ptr.c')
| -rw-r--r-- | pintos-progos/tests/userprog/create-bad-ptr.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/pintos-progos/tests/userprog/create-bad-ptr.c b/pintos-progos/tests/userprog/create-bad-ptr.c new file mode 100644 index 0000000..4a07bb3 --- /dev/null +++ b/pintos-progos/tests/userprog/create-bad-ptr.c | |||
| @@ -0,0 +1,12 @@ | |||
| 1 | /* Passes a bad pointer to the create system call, | ||
| 2 | which must cause the process to be terminated with exit code | ||
| 3 | -1. */ | ||
| 4 | |||
| 5 | #include "tests/lib.h" | ||
| 6 | #include "tests/main.h" | ||
| 7 | |||
| 8 | void | ||
| 9 | test_main (void) | ||
| 10 | { | ||
| 11 | msg ("create(0x20101234): %d", create ((char *) 0x20101234, 0)); | ||
| 12 | } | ||
