port-probe: rename _get_port() to _peek_port() as there is no ownership transfer

This commit is contained in:
Aleksander Morgado
2012-07-10 11:48:02 +02:00
parent e5e46f489e
commit a9075b0c09
7 changed files with 7 additions and 7 deletions

View File

@@ -63,7 +63,7 @@ grab_port (MMPlugin *self,
return FALSE; return FALSE;
} }
port = mm_port_probe_get_port (probe); /* transfer none */ port = mm_port_probe_peek_port (probe);
/* TODO: Why do we check for device file? */ /* TODO: Why do we check for device file? */
devfile = g_udev_device_get_device_file (port); devfile = g_udev_device_get_device_file (port);

View File

@@ -75,7 +75,7 @@ grab_port (MMPlugin *self,
return FALSE; return FALSE;
} }
port = mm_port_probe_get_port (probe); /* transfer none */ port = mm_port_probe_peek_port (probe);
/* Look for port type hints */ /* Look for port type hints */
if (g_udev_device_get_property_as_boolean (port, "ID_MM_NOKIA_PORT_TYPE_MODEM")) if (g_udev_device_get_property_as_boolean (port, "ID_MM_NOKIA_PORT_TYPE_MODEM"))

View File

@@ -60,7 +60,7 @@ grab_port (MMPlugin *self,
gchar *devfile; gchar *devfile;
MMPortType port_type; MMPortType port_type;
port = mm_port_probe_get_port (probe); /* transfer none */ port = mm_port_probe_peek_port (probe);
subsys = mm_port_probe_get_port_subsys (probe); subsys = mm_port_probe_get_port_subsys (probe);
name = mm_port_probe_get_port_name (probe); name = mm_port_probe_get_port_name (probe);

View File

@@ -66,7 +66,7 @@ grab_port (MMPlugin *self,
return FALSE; return FALSE;
} }
port = mm_port_probe_get_port (probe); /* transfer none */ port = mm_port_probe_peek_port (probe);
/* Genuine Option NV devices are always supposed to use USB interface 0 as /* Genuine Option NV devices are always supposed to use USB interface 0 as
* the modem/data port, per mail with Option engineers. Only this port * the modem/data port, per mail with Option engineers. Only this port

View File

@@ -65,7 +65,7 @@ grab_port (MMPlugin *self,
return FALSE; return FALSE;
} }
port = mm_port_probe_get_port (probe); /* transfer none */ port = mm_port_probe_peek_port (probe);
/* Look for port type hints; just probing can't distinguish which port should /* Look for port type hints; just probing can't distinguish which port should
* be the data/primary port on these devices. We have to tag them based on * be the data/primary port on these devices. We have to tag them based on

View File

@@ -933,7 +933,7 @@ mm_port_probe_get_port_type (MMPortProbe *self)
} }
GUdevDevice * GUdevDevice *
mm_port_probe_get_port (MMPortProbe *self) mm_port_probe_peek_port (MMPortProbe *self)
{ {
g_return_val_if_fail (MM_IS_PORT_PROBE (self), NULL); g_return_val_if_fail (MM_IS_PORT_PROBE (self), NULL);

View File

@@ -59,7 +59,7 @@ MMPortProbe *mm_port_probe_new (GUdevDevice *port,
const gchar *physdev_path, const gchar *physdev_path,
const gchar *driver); const gchar *driver);
GUdevDevice *mm_port_probe_get_port (MMPortProbe *self); GUdevDevice *mm_port_probe_peek_port (MMPortProbe *self);
const gchar *mm_port_probe_get_port_name (MMPortProbe *self); const gchar *mm_port_probe_get_port_name (MMPortProbe *self);
const gchar *mm_port_probe_get_port_subsys (MMPortProbe *self); const gchar *mm_port_probe_get_port_subsys (MMPortProbe *self);
const gchar *mm_port_probe_get_port_physdev (MMPortProbe *self); const gchar *mm_port_probe_get_port_physdev (MMPortProbe *self);