0 x008539fc (located in Project2. Exe) caused by abnormal: 0 xc0000005: while reading position 0 xfdfdfe2b access conflict, don't know how to solve,
#include
#include
#include
//a maze size 960 * 960
//unit 20
//wall 1
//road 0
Void makemaze2 (int a, b int, BYTE * * Maze)
{
Int I=0, t=0, c, d, e, f;
//int a=rand () % of 44 + 3, b=rand () % of 44 + 3, c=rand () % 4.//c
Int F [4], [2]={0,1,1,0,0, 1, 1, 0};
//four directionsAs [a] [b]=0;
For (I=0; I & lt;=3; I++)
{
C=a + 2 * F [I] [0], d=a + 2 * F [I] [1], e=a + F [I] [0], F=a + F [I] [1];
If (Maze [c] [d]==1)//mistake here,
{
Maze [e] [f]=0;
Makemaze2 (c, d, Maze);
}
}
}
Void makemaze ()
{
Int z, q;//z, q
Int x=0, y=0;
Int a=rand () % of 44 + 3, b=rand () % of 44 + 3, c=rand () % 4.//c
//int Maze [48] [48].
BYTE * * Maze=new BYTE * [48].
For (x=0; X & lt;=47; X++)
Maze [x]=new BYTE [48].
//int F [4], [2]={0,1,1,0,0, 1, 1, 0};
//four directionsFor (x=0; X & lt;=47; X++)
{
For (y=0; Y & lt;=47; Y++)
{
Maze [x] [y]=1;
//printf (" % d ", as he [x] [y]);
}
//printf (" \ n ");
}
Makemaze2 (a& 0 xffe b& 0 xffe, Maze);
For (z=0; Z & lt;=47; Z++)
{
For (q=0; Q & lt;=47; Q++)
Printf (" % d ", as he [z] [q]);
printf("\n");
}
}
Void main (void)
{
Srand ((unsigned) time (NULL));
Makemaze ();
}