1) include config.h first

2) conditionaly include alloca.h
3) use ofF_t instead of loff_t as it appears to be more portable

CVS patchset: 1599
CVS date: 1997/05/06 23:54:28
This commit is contained in:
ewt 1997-05-06 23:54:28 +00:00
parent 2b8a1d28e5
commit 0637a12f1d
1 changed files with 8 additions and 4 deletions

View File

@ -1,4 +1,9 @@
#include <alloca.h>
#include "config.h"
#if HAVE_ALLOCA_H
# include <alloca.h>
#endif
#include <errno.h>
#include <fcntl.h>
#include <stdio.h>
@ -9,7 +14,6 @@
#include <unistd.h>
#include <utime.h>
#include "config.h"
#include "cpio.h"
#include "miscfn.h"
@ -71,8 +75,8 @@ struct cpioHeader {
char * path;
};
static inline loff_t ourread(struct ourfd * thefd, void * buf, size_t size) {
loff_t i;
static inline off_t ourread(struct ourfd * thefd, void * buf, size_t size) {
off_t i;
i = gzread(thefd->fd, buf, size);
thefd->pos += i;