load: Change buffer_pos to be a size_t
authorJanne Kulmala <janne.t.kulmala@tut.fi>
Tue, 17 Apr 2012 08:05:12 +0000 (11:05 +0300)
committerPetri Lehtinen <petri@digip.org>
Wed, 18 Apr 2012 18:21:17 +0000 (21:21 +0300)
buffer_pos should be type size_t, because it's used to store the
current position in the read buffer. Also, it never can be negative.

src/load.c

index a904599..9ad4752 100644 (file)
@@ -48,7 +48,7 @@ typedef struct {
     get_func get;
     void *data;
     char buffer[5];
-    int buffer_pos;
+    size_t buffer_pos;
     int state;
     int line;
     int column, last_column;