I don\'t quite understand how things should be separated in C\'s source and header files. I often see many projects with two sets of files with the same name (sans the exten
There is little fundamental difference between .c and .h files (though some compilers may refuse to compile a raw .h file). The difference is more by convention.
Typically the .h file provides the API and the .c provides the implementation.
Therefore the .h file would contain only things needed by other source files to access the facilities provided by your .c file. So the .h files would provide the function prototypes of global functions, declarations of global variables (if you really must have them), and the structures and other types used by them. (Don't expose a structure if the only a pointer to the structure is required by the API.)
In-line functions are also often included in .h files but some coding guidelines prefer the use of a separate extension (e.g. .inl)
All other function implementations, the definition and initialisation of variables and declarations of local (static) variables and functions would be in the .c file.