1 --- src/rcs_file.cc.orig 2011-03-26 02:41:01.000000000 -0400
2 +++ src/rcs_file.cc 2011-07-06 02:32:22.430729595 -0400
10 string const & filename;
13 - file_handle(string const & fn) :
14 + rcs_file_handle(string const & fn) :
20 throw oops("open of " + filename + " failed");
26 throw oops("close of " + filename + " failed");
30 +struct rcs_file_source
32 string const & filename;
38 - file_source(string const & fn,
39 + rcs_file_source(string const & fn,
44 if (mapping == MAP_FAILED)
45 throw oops("mmap of " + filename + " failed");
50 if (munmap(mapping, length) == -1)
51 throw oops("munmapping " + filename + " failed, after reading RCS file");
59 string const & filename;
62 - file_handle(string const & fn) :
63 + rcs_file_handle(string const & fn) :
69 throw oops("open of " + filename + " failed");
74 if (CloseHandle(fd)==0)
75 throw oops("close of " + filename + " failed");
83 string const & filename;
89 - file_source(string const & fn,
90 + rcs_file_source(string const & fn,
96 throw oops("MapViewOfFile of " + filename + " failed");
101 if (UnmapViewOfFile(mapping)==0)
102 throw oops("UnmapViewOfFile of " + filename + " failed");
107 -typedef istream file_source;
108 +typedef istream rcs_file_source;
116 -get_token(file_source & ist,
117 +get_token(rcs_file_source & ist,
121 @@ -303,14 +303,14 @@
126 + rcs_file_source & ist;
133 - parser(file_source & s,
134 + parser(rcs_file_source & s,
136 : ist(s), r(r), line(1), col(1)
139 parse_rcs_file(string const & filename, rcs_file & r)
141 #if defined(HAVE_MMAP) || defined(WIN32)
142 - file_handle handle(filename);
143 - file_source ifs(filename, handle.fd, handle.length);
144 + rcs_file_handle handle(filename);
145 + rcs_file_source ifs(filename, handle.fd, handle.length);
147 ifstream ifs(filename.c_str());
148 ifs.unsetf(ios_base::skipws);