I have a function in C which takes an array of structs as an argument:
int load_ini_parms(char * ini_file,
struct test_object s[],
int num,
struct lwm2m_object * l)
My question is, would it be better programming practice to pass a pointer to an array of structs? What would be the advantages or disadvantages?
struct test_object s[]as argument, the compiler actually sees it asstruct test_object *s. So you're already passing a pointer (to the first element).structpointer, which might be sometimes useful but unnecessary here