Reaching EOF with fgets
I’m writing a function that perform some authentications actions. I have a file with all the user_id:password:flag couples structured like this: Users.txt user_123:a1b2:0 user_124:a2b1:1 user_125:a2b2:2 This is the code: How can I manage the EOF reaching? I saw that when EOF is reached fgets doesn’t edits anymore the usr_psw_line but neither returns a NULL pointer. … Read more