virtualpointer=(char*) VirtualAlloc (NULL, (unsigned __int64) (1<<31), MEM_RESERVE, PAGE_READWRITE);
mainhashbuf=progression=virtualpointer;
VirtualAlloc (progression, (unsigned __int64) (1<<15), MEM_COMMIT, PAGE_READWRITE);
progression=progression+capacity;
*(mainhashbuf+1000)='c';
mainhashbuf, progression and virtualpointer are pointers to char. I first reserve space, with virtual pointer pointing to that space. Then i set the other 2 pointers equal to virtual pointer. I then commit (1<<15) of that space using progression (which by now is also pointing to the reserve space), and then increment the progression pointer. Then I try to set a value in that now committed space which mainhashbuf SHOULD be pointing to, however i get a writing exception. Am I using virtualalloc wrong and/or have a wrong conception of how pointers actually work?