#include <stdio.h>#include <gpxe/uaccess.h>#include <gpxe/umalloc.h>#include <gpxe/memmap.h>Go to the source code of this file.
Functions | |
| void | umalloc_test (void) |
| void umalloc_test | ( | void | ) |
Definition at line 6 of file umalloc_test.c.
References get_memmap(), printf(), ufree(), umalloc(), and urealloc().
00006 { 00007 struct memory_map memmap; 00008 userptr_t bob; 00009 userptr_t fred; 00010 00011 printf ( "Before allocation:\n" ); 00012 get_memmap ( &memmap ); 00013 00014 bob = umalloc ( 1234 ); 00015 bob = urealloc ( bob, 12345 ); 00016 fred = umalloc ( 999 ); 00017 00018 printf ( "After allocation:\n" ); 00019 get_memmap ( &memmap ); 00020 00021 ufree ( bob ); 00022 ufree ( fred ); 00023 00024 printf ( "After freeing:\n" ); 00025 get_memmap ( &memmap ); 00026 }
1.5.7.1