]> git.parisson.com Git - pdf.js.git/commitdiff
remove putBack and make skip go via skipChar
authorAndreas Gal <andreas.gal@gmail.com>
Tue, 10 May 2011 06:10:40 +0000 (23:10 -0700)
committerAndreas Gal <andreas.gal@gmail.com>
Tue, 10 May 2011 06:10:40 +0000 (23:10 -0700)
pdf.js

diff --git a/pdf.js b/pdf.js
index 8092e79742f82ee452d0c485f883ea09475e7eda..1c03d2648cdd21ef1b8fee96141f2798920e7424 100644 (file)
--- a/pdf.js
+++ b/pdf.js
@@ -39,14 +39,12 @@ var Stream = (function() {
             this.pos++;
             return ch;
         },
-        putBack: function() {
-            this.pos--;
-        },
         skipChar: function() {
             this.pos++;
         },
         skip: function(n) {
-            this.pos += n;
+            while (n-- > 0)
+                this.skipChar();
         },
         moveStart: function() {
             this.start = this.pos;