summaryrefslogtreecommitdiff
path: root/src/dosbuf.c
diff options
context:
space:
mode:
authorAlain Magloire <alainm@rcsm.ee.mcgill.ca>1998-12-02 00:10:26 +0000
committerAlain Magloire <alainm@rcsm.ee.mcgill.ca>1998-12-02 00:10:26 +0000
commit1c29b0bffb85fea9fcd985240c857c3b791a9f70 (patch)
treeda223a865bc23674afc00f876429d299125cb229 /src/dosbuf.c
parentb07ca27e52335c8a22be8fbcd48c93a282092cd1 (diff)
downloadgrep-1c29b0bffb85fea9fcd985240c857c3b791a9f70.tar.gz
had tst for setmode and HAVE_SETMODE and HAVE_DOS_FILENAME
compatiblity patch from Paul. * src/grep.c : Typo s/infalid/invalid/ Also noted by Stanislav Brabec. * doc/grep.texi: I found and corrected several typos. I believe the GNU standards require the section that describes the options to the programs to be called ``Invoking'' or ``Invoking <program-name>''. This is so users and programs can easily find that node in any Info file. So I changed the name of the `Options' chapter to `Invoking', and corrected the cross-references accordingly. I added some markup to things like file names and options. I added some additional index entries where that seemed useful. I also corrected some index entries, such as "@cindex [:alnum:]", which used a colon in them (the colons confuse Info readers). * grep/doc/grep.texi : -h is not use for help. Nit spotted by Jim Meyering. * grep-2.2d release for beta.
Diffstat (limited to 'src/dosbuf.c')
-rw-r--r--src/dosbuf.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/dosbuf.c b/src/dosbuf.c
index d9af17d8..d3ba2f06 100644
--- a/src/dosbuf.c
+++ b/src/dosbuf.c
@@ -15,15 +15,15 @@ typedef enum {
} File_type;
struct dos_map {
- size_t pos; /* position in buffer passed to matcher */
- int add; /* how much to add when reporting char position */
+ off_t pos; /* position in buffer passed to matcher */
+ off_t add; /* how much to add when reporting char position */
};
static int dos_report_unix_offset = 0;
static File_type dos_file_type = UNKNOWN;
static File_type dos_use_file_type = UNKNOWN;
-static size_t dos_stripped_crs = 0;
+static off_t dos_stripped_crs = 0;
static struct dos_map *dos_pos_map;
static int dos_pos_map_size = 0;
static int dos_pos_map_used = 0;
@@ -121,7 +121,7 @@ undossify_input(register char *buf, size_t buflen)
}
/* Put the new entry. If the stripped CR characters
- preceed a Newline (the usual case), pretend that
+ precede a Newline (the usual case), pretend that
they were found *after* the Newline. This makes
displayed byte offsets more reasonable in some
cases, and fits better the intuitive notion that
@@ -145,11 +145,11 @@ undossify_input(register char *buf, size_t buflen)
}
/* Convert internal byte count into external. */
-static inline size_t
-dossified_pos(size_t byteno)
+static inline off_t
+dossified_pos (off_t byteno)
{
- size_t pos_lo;
- size_t pos_hi;
+ off_t pos_lo;
+ off_t pos_hi;
if (dos_file_type != DOS_TEXT || dos_report_unix_offset)
return byteno;