I have a pgm calling a function in a module.
The program is to pass a file name to the module function - and then the module function will collect the stat information and return the stat info to the calling program.
I have written the following in my calling pgm:
and then in my module function:Code:struct stat file_info; &file_info = statfile(filename);
I am getting a compile error saying:Code:file_info statfile(name_type filename) { stat(filename, &file_info); return(file_info); }
incompatible types in return
Can anyone suggest a solution?
Sue