[Pidgin] #4735: For msimprpl msim_input_cb, look into using PurpleCircBuffer

Pidgin trac at pidgin.im
Sun Jan 27 16:34:44 EST 2008


#4735: For msimprpl msim_input_cb, look into using PurpleCircBuffer
----------------------+-----------------------------------------------------
 Reporter:  jeff      |       Owner:  jeff 
     Type:  defect    |      Status:  new  
 Priority:  minor     |   Milestone:       
Component:  MySpace   |     Version:  2.3.1
 Keywords:  msimprpl  |     Pending:  0    
----------------------+-----------------------------------------------------
 Look into using PurpleCircBuffer for the receive buffer, instead of rxbuf,
 rxoff, and rxsize in an MsimSession.

 From Mark Doliner on devel:

 >Anyway, the real reason for this email is to let you know about
 >PurpleCircBuffer.  It's a circular buffer for binary data that expands as
 >needed.  I didn't look at your buffer implementation in detail, but it
 seems
 >like PurpleCircBuffer might be useful to you.  Possibly more efficient,
 since
 >it doesn't need to move data back to the beginning of the buffer after a
 >partial read from it.  But because of this you would need to be careful
 in the
 >event that you need to do multiple reads from the buffer (if you read to
 the
 >end of the buffer and then need to wrap around to the beginning to
 continue
 >reading data).
 >
 >You can see the header and implementation at libpurple/circbuffer.h and
 >libpurple/circbuffer.c

-- 
Ticket URL: <http://developer.pidgin.im/ticket/4735>
Pidgin <http://pidgin.im>
Pidgin


More information about the Tracker mailing list