Click here to Skip to main content
16,005,281 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: fscanf access violation problem Pin
David Crow28-Jun-05 7:04
David Crow28-Jun-05 7:04 
GeneralRe: fscanf access violation problem Pin
simaneal28-Jun-05 9:12
simaneal28-Jun-05 9:12 
GeneralRe: fscanf access violation problem Pin
David Crow28-Jun-05 9:17
David Crow28-Jun-05 9:17 
GeneralRe: fscanf access violation problem Pin
simaneal30-Jun-05 3:15
simaneal30-Jun-05 3:15 
GeneralRe: fscanf access violation problem Pin
David Crow30-Jun-05 3:56
David Crow30-Jun-05 3:56 
GeneralRe: fscanf access violation problem Pin
simaneal30-Jun-05 7:21
simaneal30-Jun-05 7:21 
GeneralRe: fscanf access violation problem Pin
David Crow30-Jun-05 7:53
David Crow30-Jun-05 7:53 
GeneralRe: fscanf access violation problem Pin
simaneal30-Jun-05 10:28
simaneal30-Jun-05 10:28 
Here is the code for allocating memory usinf malloc and for intializing the arrays The problems arrizes when I try initializing the last 2 arrays allocated.



//allocation of dynamic memory forfirst of 20 sets (60 arrays total)

int *pix1;

if ((pix1 = (int*)malloc(array_size * sizeof(pix1)))== NULL) {
(void)printf("ERROR: Malloc failed");
(void)exit(EXIT_FAILURE); /* or return EXIT_FAILURE; */
}

int *pixm1;

if ((pixm1 = (int*)malloc(array_size * sizeof(pixm1))) == NULL) {
(void)fprintf(stderr, "ERROR: Malloc failed");
(void)exit(EXIT_FAILURE); /* or return EXIT_FAILURE; */
}

int *pixhigh1;

if ((pixhigh1 = (int*)malloc(array_size * sizeof(pixhigh1))) == NULL) {
(void)fprintf(stderr, "ERROR: Malloc failed");
(void)exit(EXIT_FAILURE); /* or return EXIT_FAILURE; */
}


//initialization of 1 of 20 sets
for(y=0; y
GeneralRe: fscanf access violation problem Pin
David Crow30-Jun-05 10:35
David Crow30-Jun-05 10:35 
GeneralRe: fscanf access violation problem Pin
simaneal30-Jun-05 10:58
simaneal30-Jun-05 10:58 
GeneralRe: fscanf access violation problem Pin
David Crow30-Jun-05 16:47
David Crow30-Jun-05 16:47 
GeneralRe: fscanf access violation problem Pin
simaneal5-Jul-05 3:13
simaneal5-Jul-05 3:13 
GeneralRe: fscanf access violation problem Pin
David Crow5-Jul-05 3:29
David Crow5-Jul-05 3:29 
GeneralRe: fscanf access violation problem Pin
simaneal5-Jul-05 7:50
simaneal5-Jul-05 7:50 
GeneralRe: fscanf access violation problem Pin
simaneal5-Jul-05 7:45
simaneal5-Jul-05 7:45 
GeneralRe: fscanf access violation problem Pin
David Crow5-Jul-05 8:26
David Crow5-Jul-05 8:26 
GeneralFillBuffer Pin
Andrew Admire23-Jun-05 8:16
Andrew Admire23-Jun-05 8:16 
GeneralRe: FillBuffer Pin
David Crow23-Jun-05 8:18
David Crow23-Jun-05 8:18 
GeneralRe: FillBuffer Pin
Andrew Admire23-Jun-05 8:22
Andrew Admire23-Jun-05 8:22 
GeneralRe: FillBuffer Pin
David Crow23-Jun-05 9:22
David Crow23-Jun-05 9:22 
GeneralRe: FillBuffer Pin
Andrew Admire23-Jun-05 9:30
Andrew Admire23-Jun-05 9:30 
GeneralRe: FillBuffer Pin
David Crow23-Jun-05 9:33
David Crow23-Jun-05 9:33 
GeneralRe: FillBuffer Pin
Andrew Admire23-Jun-05 9:38
Andrew Admire23-Jun-05 9:38 
GeneralRe: FillBuffer Pin
David Crow23-Jun-05 9:43
David Crow23-Jun-05 9:43 
GeneralRe: FillBuffer Pin
Andrew Admire23-Jun-05 9:45
Andrew Admire23-Jun-05 9:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.