[Pidgin] #8198: Pidgin client blocked by AOL (ICQ)

Pidgin trac at pidgin.im
Fri Jan 23 05:03:10 EST 2009


#8198: Pidgin client blocked by AOL (ICQ)
--------------------+-------------------------------------------------------
 Reporter:  init    |        Owner:  MarkDoliner
     Type:  defect  |       Status:  new        
Milestone:          |    Component:  ICQ        
  Version:  2.5.4   |   Resolution:             
 Keywords:          |  
--------------------+-------------------------------------------------------

Comment(by NightFox):

 Updated solution:

 {{{
 guint16 generate_flap_sequence()
 {
 guint32 n = g_random_int (), s = 0, i;

 for (i = n; i >>= 3; s += i);

 return (((0 - s) ^ (guint)n) & 7 ^ n) + 3;
 }

 void
 flap_connection_send(FlapConnection *conn, FlapFrame *frame)
 {

         if (frame->channel == 0x01)
         {
         frame->seqnum = generate_flap_sequence();
         conn->seqnum_out = frame->seqnum;
         }
         else
         frame->seqnum = ++(conn->seqnum_out);

         purple_debug_info("oscar", "Sent FLAP seqid=%d\n",
                         frame->seqnum);

         sendframe_flap(conn, frame);
         flap_frame_destroy(frame);
 }


 }}}

-- 
Ticket URL: <http://developer.pidgin.im/ticket/8198#comment:97>
Pidgin <http://pidgin.im>
Pidgin


More information about the Tracker mailing list