35 #define SPDYF_BUFFER_SIZE 8192
41 #define SPDYF_INITIAL_WINDOW_SIZE 65536
49 #define SPDYF_NUM_SENT_FRAMES_AT_ONCE 10
69 #define SPDYF_PANIC(msg) \
70 spdyf_panic (spdyf_panic_cls, __FILE__, __LINE__, msg)
79 #define SPDYF_ASSERT(expr, msg) \
95 #define HTON24(n) (((((uint32_t)(n) & 0xFF)) << 16)\
96 | (((uint32_t)(n) & 0xFF00))\
97 | ((((uint32_t)(n) & 0xFF0000)) >> 16))
110 #define NTOH24(n) (((((uint32_t)(n) & 0xFF)) << 16)\
111 | (((uint32_t)(n) & 0xFF00))\
112 | ((((uint32_t)(n) & 0xFF0000)) >> 16))
125 #define NTOH31(n) (((((uint32_t)(n) & 0x7F)) << 24) | \
126 ((((uint32_t)(n) & 0xFF00)) << 8) | \
127 ((((uint32_t)(n) & 0xFF0000)) >> 8) | \
128 ((((uint32_t)(n) & 0xFF000000)) >> 24))
141 #define HTON31(n) (((((uint32_t)(n) & 0xFF)) << 24) | \
142 ((((uint32_t)(n) & 0xFF00)) << 8) | \
143 ((((uint32_t)(n) & 0xFF0000)) >> 8) | \
144 ((((uint32_t)(n) & 0x7F000000)) >> 24))
154 #define SPDYF_DEBUG(fmt, ...) do { \
155 fprintf (stdout, "%s\n%u: ",__FILE__, __LINE__);\
156 fprintf(stdout,fmt,##__VA_ARGS__);\
157 fprintf(stdout,"\n");\
158 fflush(stdout); } while (0)
167 #define SPDYF_PRINT_STREAM(strm, size) do { \
169 for(___i=0;___i<size;___i++){\
170 fprintf(stdout,"%x ",*((uint8_t *) strm + ___i));\
173 fprintf(stdout,"\n");\
182 #define SPDYF_SIGINT(msg) do { \
183 fprintf(stdout,"%i : %s\n", __LINE__,__FILE__);\
184 fprintf(stdout,msg);\
185 fprintf(stdout,"\n");\
187 raise(SIGINT); } while (0)
SPDY_PanicCallback spdyf_panic
public interface to libmicrospdy
void(* SPDY_PanicCallback)(void *cls, const char *file, unsigned int line, const char *reason)
unsigned long long SPDYF_monotonic_time(void)