I am trying to get access the buffer called buf from function readfile. When I print sizeof(buf) I see that buf has 4 bytes (pointer). On the other hand, if I paste the printf command on the readFiles, I can see that the size is 2916. Actually, I don't understand why it is not 729, but it is obvious I cannot access the buf inside the readfile which I need. So the question is; where is the problem and how to correct it?
void readfiles(FILES * files){
unsigned char * buf [1*729];
int skip_lines = 14;
int shift = 0;
char * filename = "file.txt";
// printf("buf size %d", sizeof(buf));
readfile(filename, skip_lines, buf, shift);
}
int readfile(char * name, int skip, unsigned char * buf, int shift ){
// buf is (unsigned char *) on address 0x22dd18 ""
printf("buf size %d", sizeof(buf));
}