Harmonize uses of fgets()