chiark / gitweb /
Do not add one to offset for delim if there wasn't a delim
authorIan Jackson <ian@liberator.relativity.greenend.org.uk>
Sat, 1 May 2010 13:21:49 +0000 (14:21 +0100)
committerIan Jackson <ian@liberator.relativity.greenend.org.uk>
Sat, 1 May 2010 13:21:49 +0000 (14:21 +0100)
backends/innduct.c

index f7ef3acddbd990896415674212923224a97358c5..a1c749196099fd480acaf76c822234139a72d4bd 100644 (file)
@@ -1,6 +1,5 @@
 /*
  * todo
 /*
  * todo
- *  - skipping_long offset calculation is wrong
  *  - reset signals TERM and INT (and HUP) in children
  *
  *  - manpage: document control master stuff
  *  - reset signals TERM and INT (and HUP) in children
  *
  *  - manpage: document control master stuff
@@ -1921,7 +1920,7 @@ static void *feedfile_got_article(oop_source *lp, oop_read *rd,
   if (!data) { feedfile_eof(ipf); return OOP_CONTINUE; }
 
   off_t old_offset= ipf->offset;
   if (!data) { feedfile_eof(ipf); return OOP_CONTINUE; }
 
   off_t old_offset= ipf->offset;
-  ipf->offset += recsz + 1;
+  ipf->offset += recsz + !!(ev == OOP_RD_OK);
 
 #define X_BAD_DATA(m) return feedfile_got_bad_data(ipf,old_offset,data,m);
 
 
 #define X_BAD_DATA(m) return feedfile_got_bad_data(ipf,old_offset,data,m);