[Pidgin] #14309: Pidgin doesnt remember me in created group after program restart

Pidgin trac at pidgin.im
Wed Sep 21 15:17:35 EDT 2011


#14309: Pidgin doesnt remember me in created group after program restart
--------------------+-------------------------------------------------------
 Reporter:  LukynZ  |        Owner:  deryni
     Type:  defect  |       Status:  new   
Milestone:          |    Component:  XMPP  
  Version:  2.8.0   |   Resolution:        
 Keywords:          |  
--------------------+-------------------------------------------------------

Comment(by dustin):

 (IMHO, this is a minor bug that can easily be worked around, so it may be
 better to consider the patch after Pidgin 3.0 is out.

 There's another patch in #14610 which seems to cure a more serious problem
 with contacts disappearing altogether, that could be used in the meantime.
 (The two patches are incompatible, though.)


 Hi,

 in `[blist.c] purple_blist_add_contact()`, moving a buddy to another group
 currently takes place in this order:

  - contact is unlinked from `purplebuddylist`
  - for each buddy:
   - buddy is removed from old and added to new group in hash_tables
   - `jabber_roster_group_change()` is called via `serv_move_buddy()`
  - after that contact is relinked to `purplebuddylist` in new group +
 ui_ops

 At the point where `serv_move_buddy()` is called, the buddy's cnode is no
 longer registered in any group.
 In case the new group was empty, `purple_find_buddies()` will not find any
 cnode in the new group, so there's no lookup for the moved buddy.


 The patch changes the order to:

  - for each buddy:
   - `jabber_roster_group_change()` is called via `serv_move_buddy()`
   - buddy is removed from old and added to new group in hash_tables
  - contact is unlinked from `purplebuddylist`
  - after that contact is relinked to `purplebuddylist` in new group +
 ui_ops

 ... so when `purple_find_buddies()` is called, the moved buddy will be
 found in the old group.

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


More information about the Tracker mailing list