netatalk 4.5.0
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
papd/file.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 1990,1991 Regents of The University of Michigan.
3 * All Rights Reserved. See COPYRIGHT.
4 */
5
6#ifndef PAPD_FILE_H
7#define PAPD_FILE_H 1
8
9#include <sys/types.h>
10
11 struct papfile {
12 int pf_state;
13 struct state *pf_xstate;
14 int pf_bufsize;
15 int pf_datalen;
16 char *pf_buf;
17 char *pf_data;
18 int origin;
19};
20
21#define PF_BOT (1<<0)
22#define PF_EOF (1<<1)
23#define PF_QUERY (1<<2)
24#define PF_STW (1<<3)
25#define PF_TRANSLATE (1<<4)
26#define PF_FONT_QUERY (1<<5)
27
28#define CONSUME( pf, len ) { (pf)->pf_data += (len); \
29 (pf)->pf_datalen -= (len); \
30 if ((pf)->pf_datalen <= 0) { \
31 (pf)->pf_data = (pf)->pf_buf; \
32 (pf)->pf_datalen = 0; \
33 } \
34 }
35
36#define PF_MORESPACE 1024
37
38 int markline(struct papfile *, char **, int *, int *);
39 void morespace(struct papfile *, const char *, int);
40 void append(struct papfile *, const char *, int);
41 void spoolerror(struct papfile *, char *);
42 void spoolreply(struct papfile *, char *);
43
44#endif /* PAPD_FILE_H */
state
static int state
Definition magics.c:23
markline
int markline(struct papfile *, char **, int *, int *)
Definition papd/file.c:18
spoolerror
void spoolerror(struct papfile *, char *)
Definition papd/file.c:126
append
void append(struct papfile *, const char *, int)
Definition afpd/uam.c:596
spoolreply
void spoolreply(struct papfile *, char *)
Definition papd/file.c:112
morespace
void morespace(struct papfile *, const char *, int)
Definition papd/file.c:66
papfile
Definition papd/file.h:11
papfile::pf_bufsize
int pf_bufsize
Definition papd/file.h:14
papfile::pf_state
int pf_state
Definition papd/file.h:12
papfile::pf_datalen
int pf_datalen
Definition papd/file.h:15
papfile::pf_xstate
struct state * pf_xstate
Definition papd/file.h:13
papfile::pf_data
char * pf_data
Definition papd/file.h:17
papfile::origin
int origin
Definition papd/file.h:18
papfile::pf_buf
char * pf_buf
Definition papd/file.h:16