After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 377262 - When renaming a VPN connection, the old name is not removed from the list
When renaming a VPN connection, the old name is not removed from the list
Status: RESOLVED FIXED
Product: NetworkManager
Classification: Platform
Component: nm-applet
0.6.6
Other All
: Normal normal
: ---
Assigned To: Dan Williams
Dan Williams
Depends on:
Blocks:
 
 
Reported: 2006-11-20 02:16 UTC by Daniel P. Berrange
Modified: 2006-11-20 04:07 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix renaming of VPN connections (1.73 KB, patch)
2006-11-20 02:19 UTC, Daniel P. Berrange
none Details | Review

Description Daniel P. Berrange 2006-11-20 02:16:19 UTC
Please describe the problem:
When renaming an existing VPN connection, the list of VPN connections ends up with a duplicated entry. Once this happens, it is impossible to edit the VPN connection in question again without restarting the app

Steps to reproduce:
1. Left click applet to display menu
2. Select VPN Connections -> Configure VPN...
3. Select a connection
4. Click 'edit'
5. In the property editor dialog change the name of the VPN connection
6. Click 'apply'


Actual results:
The list of VPN connections now contains a bogus entry - one with the old name, one with the new name.

Expected results:
The list of VPN connections should only contain an entry with the new name

Does this happen every time?
Yes

Other information:
Comment 1 Daniel P. Berrange 2006-11-20 02:19:02 UTC
Created attachment 76886 [details] [review]
Fix renaming of VPN connections

The attached patch ensures that the old VPN connection entry is removed from the ListStore model when a connection is renamed. The core of the problem was that the call:

			gtk_list_store_remove (vpn_conn_list, &iter);

Was failing, because 'iter' was not initialized to point at any row. The fix simply initializes the 'iter' object to point to the currently selected row.

In addition, the patch also ensures that after the old entry is removed, the newly named entry is made the active selection.
Comment 2 Dan Williams 2006-11-20 04:07:36 UTC
Committed to HEAD and stable, thanks!