* compressing.
* 2)
*/
- len = connection_compress_from_buf(cell.payload,
+ len = connection_compress_from_buf(cell.payload+TOPIC_HEADER_SIZE,
CELL_PAYLOAD_SIZE - TOPIC_HEADER_SIZE,
conn, Z_SYNC_FLUSH);
if (len < 0)
cell.length = amount_to_process;
}
- if(connection_fetch_from_buf(cell.payload, cell.length, conn) < 0)
+ if(connection_fetch_from_buf(cell.payload+TOPIC_HEADER_SIZE,
+ cell.length, conn) < 0)
return -1;
#endif
}
#ifdef USE_ZLIB
- if(connection_decompress_to_buf(cell->payload,
+ if(connection_decompress_to_buf(cell->payload + TOPIC_HEADER_SIZE,
cell->length - TOPIC_HEADER_SIZE,
conn, Z_SYNC_FLUSH) < 0) {
log(LOG_INFO,"connection_edge_process_data_cell(): write to buf failed. Marking for close.");
return 0;
}
#else
- if(connection_write_to_buf(cell->payload,
+ if(connection_write_to_buf(cell->payload + TOPIC_HEADER_SIZE,
cell->length - TOPIC_HEADER_SIZE, conn) < 0) {
conn->marked_for_close = 1;
return 0;