Print this page
3484 enhance and document tail follow support
Reviewed by: Joshua M. Clulow <jmc@joyent.com>
@@ -25,12 +25,23 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
*/
+/*
+ * Copyright (c) 2013, Joyent, Inc. All Rights Reserved.
+ */
+#ifndef EXTERN_H
+#define EXTERN_H
+
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <port.h>
+
+
#define WR(p, size) do { \
if (write(STDOUT_FILENO, p, size) != (ssize_t)size) \
oerr(); \
} while (0)
@@ -46,10 +57,11 @@
struct file_info {
FILE *fp;
char *file_name;
struct stat st;
+ file_obj_t fobj;
};
typedef struct file_info file_info_t;
enum STYLE { NOTSET = 0, FBYTES, FLINES, RBYTES, RLINES, REVERSE };
@@ -65,5 +77,7 @@
void oerr(void);
int mapprint(struct mapinfo *, off_t, off_t);
int maparound(struct mapinfo *, off_t);
extern int Fflag, fflag, qflag, rflag, rval, no_files;
+
+#endif /* EXTERN_H */