struct buff_struct {
int flags; /* flags */
unsigned char *inptr; /* pointer to next location to read */
int incnt; /* number of bytes left to read from input buffer;
* always 0 if had a read error */
int outchunk; /* location of chunk header when chunking */
int outcnt; /* number of byte put in output buffer */
unsigned char *inbase; ///???
unsigned char *outbase;
int bufsiz;
void (*error) (BUFF *fb, int op, void *data);
void *error_data;
long int bytes_sent; /* number of bytes actually written */
ap_pool *pool;
/* could also put pointers to the basic I/O routines here */
int fd; /* the file descriptor */
int fd_in; /* input file descriptor, if different */
#ifdef WIN32
HANDLE hFH; /* Windows filehandle */
#endif
/* transport handle, for RPC binding handle or some such */
void *t_handle;
#ifdef B_SFIO
Sfio_t *sf_in;
Sfio_t *sf_out;
#endif
void *callback_data;
void (*filter_callback)(BUFF *, const void *, int );
};
#ifdef B_SFIO
typedef struct {
Sfdisc_t disc;
BUFF *buff;
} apache_sfio;
这个结构蛮复杂的,涉及文件读写,Socket读写,apache 里的chunk具体含义还不是很明白,还有ebcdic编码等内容,不过windows和linux都不会用到这种编码了,呵呵,写这些东西主要是让自己能够继续分析下去,现在多少就有点想
退缩了,毕竟是第一次分析开源的代码,业余时间也不够,看代码很辛苦的,希望有此爱好的朋友能够大家多交流