summaryrefslogtreecommitdiff
path: root/inotail.h
blob: b47e6a49a26c216b6aa48d423a1189590040cac3 (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
#ifndef _INOTAIL_H
#define _INOTAIL_H

/* Number of items to tail. */
#define DEFAULT_N_LINES 10

/* tail modes */
enum { M_LINES, M_BYTES };

/* Every tailed file is represented as a file_struct */
struct file_struct {
	char *name;		/* Name of file (or '-' for stdin) */
	int fd;			/* File descriptor (or -1 if file is not open */
	off_t st_size;		/* File size */

	unsigned ignore;	/* Wheter to ignore the file in further processing */

	int i_watch;		/* Inotify watch associated with file_struct */
};

#ifdef DEBUG
# define dprintf(fmt, args...) fprintf(stderr, fmt, ##args)
#else
# define dprintf(fmt, args...)
#endif /* DEBUG */

#ifdef __GNUC__
# define unlikely(x) __builtin_expect(!!(x), 0)	/* Taken from linux kernel source */
#else
# define unlikely(x) (x)
#endif

#endif /* _INOTAIL_H */
t.cgi/linux/net-next.git/commit/Documentation/SubmittingPatches?id=9b2c76777accbd7b70d73ca540d1e318e4f2c206'>Documentation/SubmittingPatches: enrich the Sphinx outputMauro Carvalho Chehab1-45/+55 2016-09-20Documentation/SubmittingPatches: convert it to ReST markupMauro Carvalho Chehab1-102/+105 2016-01-25SubmittingPatches: fix spelling of "git send-email"Jakub Wilk1-1/+1 2015-11-13Merge tag '4.4-additional' of git://git.lwn.net/linuxLinus Torvalds1-1/+14 2015-11-11Documentation/SubmittingPatches: discuss In-Reply-ToChris Metcalf1-1/+14 2015-09-24SubmittingPatches: make Subject examples match the de facto standardAlex Henrie1-4/+4 2015-09-01Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jiko...Linus Torvalds1-1/+1 2015-08-07Doc: fix trivial typo in SubmittingPatchesBenjamin Herr1-1/+1 2015-08-07fix typo in Documentation/SubmittingPatchesNik Nyby1-1/+1 2015-08-06SubmittingPatches: remove stray quote characterJakub Wilk1-1/+1 2015-07-24Doc: fix trivial typo in SubmittingPatchesBenjamin Herr1-1/+1 2015-07-14SubmittingPatches: fix wrong wordingSébastien Hinderer1-1/+1 2015-07-14SubmittingPatches: fix wrong wordingSébastien Hinderer1-1/+1 2015-07-10SubmittingPatches: update CodingStyle referenceLuis de Bethencourt1-1/+1 2015-07-09SubmittingPatches: fix typoSébastien Hinderer1-1/+1 2015-05-14SubmittingPatches: Clarify requirements for patches directed toward stableLuke Dashjr1-1/+3 2015-04-17checkpatch, SubmittingPatches: suggest line wrapping commit messages at 75 co...Joe Perches1-2/+2 2015-01-29Merge branch 'doc/sp-update' into docs-nextJonathan Corbet1-220/+216 2014-12-29Documentation/SubmittingPatches: unify whitespace/tabs for the DCOStefan Beller1-8/+8 2014-12-23Docs: SubmittingPatches: mention using pull requests as a cover letterJonathan Corbet1-1/+3 2014-12-23Docs: Mention device tree binding infoJonathan Corbet1-1/+2 2014-12-23Docs: SubmittingPatches: miscellaneous cleanupsJonathan Corbet1-23/+38 2014-12-23Docs: SubmittingPatches: update follow-through instructionsJonathan Corbet1-28/+22 2014-12-23Docs: Update recipient information in SubmittingPatchesJonathan Corbet1-53/+54 2014-12-23Docs: Bring SubmittingPatches more into the git eraJonathan Corbet1-29/+87 2014-12-23Docs: Remove "tips and tricks" from SubmittingPatchesJonathan Corbet1-96/+21 2014-10-29Documentation/SubmittingPatches: Reported-by tags and permissionDan Carpenter1-6/+4 2014-09-07Documentation: new page link in SubmittingPatchesSudip Mukherjee1-0/+1 2014-08-09Documentation: SubmittingPatches: overhaul changelog descriptionJohannes Weiner1-7/+31 2014-08-06Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jik...Linus Torvalds1-2/+2 2014-06-19doc: replace "practise" with "practice" in DocumentationJeremiah Mahler1-2/+2 2014-06-06Documentation/SubmittingPatches: describe the Fixes: tagJacob Keller1-1/+21 2014-04-03Documentation/SubmittingPatches: update some dead URLsMitchel Humpherys1-2/+2 2014-04-03SubmittingPatches: document the use of gitJosh Triplett1-15/+16 2014-04-03SubmittingPatches: add recommendation for mailing list referencesJosh Triplett1-1/+9 2014-04-03SubmittingPatches: add style recommendation to use imperative descriptionsJosh Triplett1-0/+5 2013-08-20Documentation/SubmittingPatches: Request summaries for commit referencesGeert Uytterhoeven1-0/+10 2013-04-29checkpatch: add Suggested-by as a standard signatureMugunthan V N1-1/+8 2013-03-08Randy has movedRandy Dunlap1-2/+1 2012-05-25Documentation/SubmittingPatches: suggested the use of scripts/get_maintainer.plMichel Machado1-1/+2 2011-08-13Documentation: fix spelling error in SubmittingPatchesZac Storer1-1/+1 2011-05-23Documentation: update GregKH linksVikram Narayanan1-4/+5 2011-03-31Fix common misspellingsLucas De Marchi1-1/+1 2010-08-09SubmittingPatches: add more about patch descriptionsRandy Dunlap1-0/+11