Re: mmap segmentation fault

2012-04-12 Thread Jilles Tjoelker
On Fri, Apr 13, 2012 at 12:25:32AM +0530, Maninya M wrote: > I want to allocate memory at a specified address location 'a' of size 'b'. > I wrote code below to do it, but I'm getting a seg fault. How can I solve > this? > How can I get the allocated memory at the required address? > int main() > {

mmap segmentation fault

2012-04-12 Thread Maninya M
Hello, I want to allocate memory at a specified address location 'a' of size 'b'. I wrote code below to do it, but I'm getting a seg fault. How can I solve this? How can I get the allocated memory at the required address? int main() { unsigned int *addr,*newaddr; unsigned long a=134516736,a1; unsi