Version 1.8.0.0
[socat.git] / filan.h
blobb86539ba429f5ece0ddcc5dfa7c60a579f4c3dec
1 /* source: filan.h */
2 /* Copyright Gerhard Rieger and contributors (see file CHANGES) */
4 /* Published under the GNU General Public License V.2, see file COPYING */
6 #ifndef __filan_h_included
7 #define __filan_h_included 1
9 struct sockaddr; /* prevent gcc from spitting silly warning */
10 struct sockaddr_un; /* prevent gcc from spitting silly warning */
11 struct sockaddr_in; /* prevent gcc from spitting silly warning */
12 struct sockaddr_in6; /* prevent gcc from spitting silly warning */
14 extern bool filan_followsymlinks;
15 extern bool filan_rawoutput;
17 extern int filan_file(const char *filename, FILE *outfile);
18 extern int filan_fd(int fd, FILE *outfile);
19 extern int filan_stat(
20 #if HAVE_STAT64
21 struct stat64 *buf
22 #else
23 struct stat *buf
24 #endif /* !HAVE_STAT64 */
25 , int statfd, int dynfd, FILE *outfile,
26 const char *filename);
28 extern int cdevan(int fd, FILE *outfile);
30 #if _WITH_SOCKET
31 extern int isasocket(int fd);
32 extern int sockettype(int socktype, char *typename, size_t typenamemax);
33 extern int sockan(int fd, FILE *outfile);
34 extern int ipan(int fd, FILE *outfile);
35 extern int ip6an(int fd, FILE *outfile);
36 #endif /* _WITH_SOCKET */
38 extern
39 int fdname(const char *file, int fd, FILE *outfile, const char *numform,
40 char style);
42 #endif /* !defined(__filan_h_included) */