does it return anything? is EOF nothing but -1 ? How does fgets detect an EOF ? Can somebody please elaborate also on the difference between gets and fgets()
It returns NULL on encountering EOF