Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!europa.asd.contel.com!gatech!udel!haven.umd.edu!umbc3.umbc.edu!gmuvax2!gmuvax.gmu.edu!5645an From: 5645an@gmuvax.gmu.edu Newsgroups: comp.sys.next Subject: VM_ALLOCATE PROBLEMS ... HELP! Message-ID: <1991Jun9.105525.51402@gmuvax.gmu.edu> Date: 9 Jun 91 15:55:25 GMT Organization: George Mason University, Fairfax, VA. Lines: 20 I am having a problem with virtual memory allocation in a program. It seems to occur at memory intensive points during execution. The following line of code mallocs some memory (numPts = 3708, so 14,832 bytes): line = (int*)malloc((numPts)*sizeof(int)); I get an error message from malloc - failed on vm_allocate but it still returns a value for the pointer (not NULL) (gdb) p line $4 = (port_name_array_t) 0x294c000 Then later, I try to access this memory space, and of course, I get a segmentation fault. Program received signal 11, Segmentation fault I have used the vm_statistics() function to print out available memory, and it appears I still have some. Anyone have any suggestions ?