string GetNextLine (StreamReader reader, List<string> list) { if (reader.Peek () < 0) return null; string ret = reader.ReadLine (); list.Add (ret); return ret; }