summaryrefslogtreecommitdiff
path: root/news/nn/patches/patch-ah
blob: 77b987eb33fe000c1ff28ce14fed14d53598351d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
$NetBSD: patch-ah,v 1.2 1999/08/22 22:55:46 kim Exp $

--- collect.c.orig	Wed Aug 14 23:08:39 1996
+++ collect.c	Sun Aug 22 18:21:47 1999
@@ -45,7 +45,7 @@
     article_number last;
     register FILE *arc;
     register int c;
-    off_t start;
+    long start;
     static char *arc_header = "Archived-Last: ";
     /* Header format: Archived-Last: 88888888 group.name */
     /* Fixed constants length == 15 and offset == 24 are used below */
@@ -83,9 +83,9 @@
 
     fseek(arc, start, 0);
     fprintf(arc, "%s%8ld %s\n", arc_header, (long)num, gh->group_name);
-    fseek(arc, (off_t)0, 2);
+    fseek(arc, (long)0, 2);
 
-    fseek(f, (off_t)0, 0);
+    fseek(f, (long)0, 0);
     while ((c = getc(f)) != EOF) putc(c, arc);
     putc(NL, arc);
     fclose(arc);
@@ -177,8 +177,8 @@
     /* get article header */
 
     art_hdr.a_number = art_num;
-    art_hdr.hpos = (off_t)0;
-    art_hdr.lpos = (off_t)0;
+    art_hdr.hpos = (long)0;
+    art_hdr.lpos = (long)0;
     art_hdr.flag = 0;
 
     mode = FILL_NEWS_HEADER | FILL_OFFSETS | SKIP_HEADER;
@@ -391,7 +391,7 @@
 	}
 #endif
 #ifndef RENUMBER_DANGER
-	if (temp == 0 && gh->data_write_offset == (off_t)0) {
+	if (temp == 0 && gh->data_write_offset == (long)0) {
 	    gh->first_db_article = gh->last_db_article + 1;
 	    continue;
 	}