]> thyrsus.com Git - rcs-fast-import.git/commitdiff
Translate a little more.
authorEric S. Raymond <esr@thyrsus.com>
Tue, 16 Nov 2010 01:30:02 +0000 (20:30 -0500)
committerEric S. Raymond <esr@thyrsus.com>
Tue, 16 Nov 2010 01:30:02 +0000 (20:30 -0500)
rcs-fast-export

index 33c6133456e198f8370d1ae59129f5ff6d1a6a30..3982f988a441949112508b627fa3c74a00e2adf7 100644 (file)
@@ -271,7 +271,7 @@ class RCS:
                     if m:
                         rev = command
                         if rcs.has_revision(rev):
-                            status.appand("revision_data")
+                            status.append("revision_data")
                         else:
                             status.append("new_revision")
                         continue
@@ -303,20 +303,17 @@ class RCS:
                                 rcs.revision[rev].symbols.append(sym)
                             else:
                                 status.pop()
-                when :desc
-                        rcs.desc.replace lines.dup
-                        status.pop
-                when :read_lines
-                        # we sanitize lines as we read them
-
-                        actual_line = line.dup
-
-                        # the first line must begin with a @, which we strip
-                        if lines.empty?
-                                ats = line.match(/^@+/)
-                                raise 'malformed line' unless ats
-                                actual_line.replace line.sub(/^@/,'')
-                        end
+                elif status[-1] == "desc":
+                    rcs.desc = []
+                    status.pop()
+                elif status[-1] == "read_lines":
+                    # we sanitize lines as we read them
+                    # the first line must begin with a @, which we strip
+                    if not rcs.desc:
+                        if not line.startswith("@"):
+                            raise FatalException('malformed line')
+                        else:
+                            line = line[1:]
 
                         # if the line ends with an ODD number of @, it's the
                         # last line -- we work on actual_line so that content