2007-10-10 Dan Williams <dcbw@redhat.com>

* src/nm-manager.c
		- (wait_for_connection_expired): ensure info is valid
		- (connection_added_default_handler): Should only remove pending
			connection info when the manager has the connection that it's
			waiting for.  Fixes segfault in wait_for_connection_info().  



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2969 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
Dan Williams 2007-10-10 20:45:15 +00:00
parent 7ccae0048b
commit dc3d072b04
2 changed files with 15 additions and 5 deletions

View file

@ -1,3 +1,11 @@
2007-10-10 Dan Williams <dcbw@redhat.com>
* src/nm-manager.c
- (wait_for_connection_expired): ensure info is valid
- (connection_added_default_handler): Should only remove pending
connection info when the manager has the connection that it's
waiting for. Fixes segfault in wait_for_connection_info().
2007-10-10 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting.c

View file

@ -1105,6 +1105,8 @@ wait_for_connection_expired (gpointer data)
PendingConnectionInfo *info = priv->pending_connection_info;
GError *err;
g_return_val_if_fail (info != NULL, FALSE);
nm_info ("%s: didn't receive connection details soon enough for activation.",
nm_device_get_iface (info->device));
@ -1158,15 +1160,12 @@ connection_added_default_handler (NMManager *manager,
NMConnectionType connection_type)
{
NMManagerPrivate *priv = NM_MANAGER_GET_PRIVATE (manager);
PendingConnectionInfo *info;
PendingConnectionInfo *info = priv->pending_connection_info;
const char *path;
if (!nm_manager_activation_pending (manager))
if (!info)
return;
info = priv->pending_connection_info;
priv->pending_connection_info = NULL;
if (connection_type != info->connection_type)
return;
@ -1174,6 +1173,9 @@ connection_added_default_handler (NMManager *manager,
if (strcmp (info->connection_path, path))
return;
/* Will destroy below; can't be valid during the initial activation start */
priv->pending_connection_info = NULL;
// FIXME: remove old_dev deactivation when multiple device support lands
deactivate_old_device (manager);