Commit graph

11407 commits

Author SHA1 Message Date
Dan Williams
ad7ea00c81 core: quit if manager startup completed before starting the mainloop
(cherry picked from commit a5891299b9)
2015-03-11 09:29:32 -05:00
Dan Williams
9eba2b0e7d man: note that dhcp=internal is required for configure-and-quit=true
(cherry picked from commit cb17be1e12)
2015-03-10 15:30:33 -05:00
Lubomir Rintel
fe9dada57a route-manager: refactor: a readability improvement
(cherry picked from commit 6c5d93b847)

Conflicts:
	src/nm-route-manager.c
2015-03-09 14:27:44 +01:00
Lubomir Rintel
435632a757 platform: fix route addition ordering
(cherry picked from commit 47167cab4f)
2015-03-09 14:26:13 +01:00
Dan Williams
0bb7623580 release: belatedly bump version to 1.0.1 (development) 2015-03-05 11:12:19 -06:00
Jiří Klimeš
2a72527c44 tui: fix a crash when connection list for activation is empty (rh #1119663)
When there are no connections for a device, do not add the header.

https://bugzilla.redhat.com/show_bug.cgi?id=1119663
(cherry picked from commit 5aa204edec)
2015-03-05 07:44:08 -06:00
Stas Solovey
785dd7c21a po: updated Russian (ru) translation (bgo #745262)
https://bugzilla.gnome.org/show_bug.cgi?id=745262
(cherry picked from commit f610ae7265)
2015-03-05 07:43:56 -06:00
Thomas Haller
ae500e4ee0 wwan: refactor nm_modem_ip_type_to_string() and fix return type
The statement
    g_return_val_if_reached (NM_MODEM_IP_TYPE_UNKNOWN);
was wrong, because the return type is 'const char *'.

But just refactor nm_modem_ip_type_to_string() to get rid of
the static table and make it a switch statement.

Fixes: 02beeeeb12

(cherry picked from commit 5599a82d0d)
2015-03-05 12:55:04 +01:00
Dan Williams
a7323ab2cc dhclient: use fqdn.fqdn for server DDNS updates
dhclient only supports fqdn.fqdn for server DDNS updates with
DHCPv6.  And even though the underlying DHCP options that fqdn.fqdn
controls allow non-qualified hostnames on the wire, dhclient does
not.  So we must require a fully-qualified name for DHCPv6.

Second, while no-client-updates seems like it should be "off", doing
that apparently makes dhclient set the "O" flag to 1 which appears to
be a bug, and results in the server not doing the DDNS update.  So
we must stop setting that option too.

Found by: Alexander Groß

(cherry picked from commit 677cee0f23)
2015-02-27 10:06:25 -06:00
Aleksander Morgado
2a4b785925 wwan: indentation & alignment fixes 2015-02-24 16:15:27 -06:00
Aleksander Morgado
02beeeeb12 wwan: new retry logic when ipv4=auto and ipv6=auto
When ipv4=auto and ipv6=auto, we'll first try with the IPv4v6 PDP type, and if
that fails (e.g. if either the modem or the operator doesn't support it), we'll
fallback to trying with IPv4 or IPv6 PDP types (only if may-fail configuration
allows it).

Patch based on a previous implementation by Dan Williams <dcbw@redhat.com>

https://bugzilla.gnome.org/show_bug.cgi?id=733696
2015-02-24 16:15:27 -06:00
Lubomir Rintel
762f55ce93 wwan: fix wrong assert in deactivate_cleanup()
When the modem device is abruptly disconnected,
nm_modem_device_state_changed() calls deactivate_cleanup() with a NULL
device argument and that's perfectly fine.

We should only check the instance type if we know the device is non-NULL.

(NetworkManager:9166): NetworkManager-wwan-CRITICAL **: deactivate_cleanup: assertion 'NM_IS_DEVICE ( failed

(cherry picked from commit 41c87eb363)
2015-02-24 16:15:27 -06:00
Aleksander Morgado
6f2e6071bc wwan: consolidate format of log messages
(cherry picked from commit a6fedb1a26)
2015-02-24 16:15:27 -06:00
Aleksander Morgado
0cd5589add wwan: wait for pppd to exit before relaying the port to ModemManager
ModemManager needs to have CLOCAL set in the TTY termios configuration, in order
to notify the kernel that modem control lines are not in effect (e.g. so that a
transition to LOW in the DCD input control line doesn't trigger a hangup in the
TTY).

pppd in the other hand, needs CLOCAL unset in order to have proper modem control
lines in effect during the PPP session. So, when pppd starts it will store the
original termios settings, and before exiting it will restore the original
settings in the TTY. In other words, if CLOCAL was set before launching pppd,
CLOCAL will be also set after pppd exits.

Now, in order for this sequence to work correctly, NetworkManager also needs to
make sure that ModemManager is notified about the disconnection only after pppd
has really finished re-configuring the TTY.

https://bugzilla.gnome.org/show_bug.cgi?id=734347

----------------------

Once the patch is applied, we will be making sure that ModemManager is only
notified about the disconnection AFTER pppd has fully exited:
    NetworkManager[27589]: <info>  (ttyUSB2): device state change: activated -> deactivating (reason 'user-requested') [100 110 39]
    Terminating on signal 15
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_phasechange): status 10 / phase 'terminate'
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_phasechange): status 8 / phase 'network'
    Connect time 0.3 minutes.
    Sent 56 bytes, received 0 bytes.
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_phasechange): status 5 / phase 'establish'
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_phasechange): status 11 / phase 'disconnect'
    Connection terminated.
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_phasechange): status 1 / phase 'dead'
    nm-pppd-plugin-Message: nm-ppp-plugin: (nm_exit_notify): cleaning up
    NetworkManager[27589]: <warn>  pppd pid 27617 exited with error: pppd received a signal
    NetworkManager[27589]: <info>  (ttyUSB2): modem state changed, 'connected' --> 'disconnecting' (reason: user-requested)
    NetworkManager[27589]: <info>  (ttyUSB2): modem state changed, 'disconnecting' --> 'registered' (reason: user-requested)
    NetworkManager[27589]: <info>  (ttyUSB2) modem deactivation finished
    NetworkManager[27589]: <info>  (ttyUSB2): device state change: deactivating -> disconnected (reason 'user-requested') [110 30 39]
    NetworkManager[27589]: <info>  (ttyUSB2): deactivating device (reason 'user-requested') [39]

(cherry picked from commit fe090c34b7)
2015-02-24 16:15:26 -06:00
Aleksander Morgado
a274b66d37 wwan,modem: let disconnect() be an async operation
(cherry picked from commit ec61601a22)
2015-02-24 16:15:26 -06:00
Aleksander Morgado
aea6183041 ppp-manager: new async stop() method to request stop and wait for it to complete
This method doesn't prevent the original logic in which the child process was
stopped when the last reference of the PPP manager was unref-ed.

(cherry picked from commit 14f732e8df)
2015-02-24 16:15:26 -06:00
Aleksander Morgado
0eb7652139 device: new deactivate_async() method to be run during DEACTIVATING phase
This method isn't run if NM is quitting; so the deactivate() method still needs
to be implemented to handle sync disconnection requests.

(cherry picked from commit f3efdbcdf2)
2015-02-24 16:15:26 -06:00
Lubomir Rintel
567e86c9f8 device: set the reason for when deactivating for another activation
It's always user requested -- auto activation never happens on already active
devices. nm_device_release_one_slave() rightly asserts teardown with
(un)configuration does not happen for no reason at all.

https://bugzilla.gnome.org/show_bug.cgi?id=744812
(cherry picked from commit 600489003f)
2015-02-24 18:55:03 +01:00
Lubomir Rintel
df7f57c516 manager: don't re-assume generated connections
They're being torn down as their device is being deactivated.

https://bugzilla.gnome.org/show_bug.cgi?id=744812
(cherry picked from commit d37f2280b7)
2015-02-24 18:55:03 +01:00
Thomas Haller
b32b10ac4c build: fix detecting support for -Wno-* compiler flags
Since GCC 4.4, gcc does not warn about unknown -Wno-* flags. At
least, it does not warning unless another warning is raised as well
(https://gcc.gnu.org/wiki/FAQ#wnowarning).

We didn't notice up to now, because we only tested flags that GCC
actually supports.

Hack around this, by checking for the -W* counterpart instead.

(cherry picked from commit 0462104317)
2015-02-24 18:52:45 +01:00
Thomas Haller
dfebbdaef1 device: skip generating enums for internal flags with glib-mkenums
(cherry picked from commit 6cdcf36a3d)
2015-02-24 18:22:29 +01:00
Thomas Haller
2edd273096 core: merge branch 'th/queue_act_request_no_carrier_rh1079353'
https://bugzilla.redhat.com/show_bug.cgi?id=1079353

(cherry picked from commit 1f5b9ffc3d)
2015-02-24 17:49:44 +01:00
Thomas Haller
b8f40f969b device: accept user activation request while waiting for carrier
https://bugzilla.redhat.com/show_bug.cgi?id=1079353
(cherry picked from commit 0bfe635119)
2015-02-24 17:44:05 +01:00
Thomas Haller
b6495b5000 device: eliminate direct calls to check_connection_available() in favor of nm_device_check_connection_available()
It was confusing to understand the difference between calling nm_device_connection_is_available()
and check_connection_available(), they behaved similar, but not really
the same. Especially nm_device_connection_is_available() would look
first into @available_connetions, and might call check_connection_available()
itself. Whereas @available_connetions was also populated by testing
check_connection_available(). This interrelation makes it hard to
understand when nm_device_connection_is_available() returned true.

Rename nm_device_connection_is_available() to nm_device_check_connection_available()
and remove all direct calls of check_connection_available() in favor of
the wrapper nm_device_check_connection_available().

Now we only call nm_device_check_connection_available() with different
parameters (@flags and @specific_object). We also have the additional
guarantee that specifying more @flags will widen the result and making
a connection "more" available, while specifying a @specific_object will
restrict it.

This also changes behavior in several cases. For example before
nm_device_connection_is_available() for user-requests would always
declare matching connections available on Wi-Fi devices (only)
regardless of the device state. Now the device state gets consistently
considered.

For default-unmanaged devices it also changes behavior in complicated
ways, because before we would put connections into @available_connetions
for every device-state, but nm_device_connection_is_available() had a
special over-ride only for unmanaged-state.

This also fixes a bug, that user can activate an unavailable Wi-Fi
device:
  nmcli radio wifi off
  nmcli connection up wlan0

(cherry picked from commit d80f1bf4f0)
2015-02-24 17:44:05 +01:00
Thomas Haller
92f4258326 device: remove debug logging from is_available()
Having logging statements in a simple getter (or is_*()) means
you cannot call these functions without cluttering the log.

Another approach would be to add an @out_reason argument, and
callers who actually care log the reason. For now, just get rid
of the messages.

(cherry picked from commit e524be2c34)
2015-02-24 17:44:04 +01:00
Thomas Haller
60641b0fa7 device: implement flag NM_DEVICE_CHECK_DEV_AVAILABLE_IGNORE_CARRIER for is_available()
(cherry picked from commit 37ebeccaa7)
2015-02-24 17:44:04 +01:00
Thomas Haller
ba52457f4d device: add flags to nm_device_is_available()
(cherry picked from commit 52dbb2398a)
2015-02-24 17:44:04 +01:00
Thomas Haller
3a5cee2a99 device: add flags argument to check_connection_available()
(cherry picked from commit e96af59444)
2015-02-24 17:44:04 +01:00
Thomas Haller
2799d502a1 device: merge check_connection_available_wifi_hidden() into check_connection_available()
Only refactoring, no behavioral change.

(cherry picked from commit 5a04273715)
2015-02-24 17:44:04 +01:00
Thomas Haller
e7c8affef5 device: refactor nm_device_connection_is_available()
No functional change, but refactor the function to
return early.

(cherry picked from commit 364c4476e3)
2015-02-24 17:44:04 +01:00
Thomas Haller
a042cec8a9 device/trivial: rename argument in nm_device_connection_is_available()
The argument name should express what the caller wants
(he wants to know, whether the connection can be activated
for an internal or external activation request).

Whether that involves checking device-specific overrides, is
not the point -- nm_device_check_connection_compatible() is
also a virtual function with device-specific overrides.

(cherry picked from commit a7e0a038bf)
2015-02-24 17:44:04 +01:00
Thomas Haller
1158fd4f5b device: add special NM_UNMANAGED_ALL flag
(cherry picked from commit aefd269308)
2015-02-24 17:43:39 +01:00
Thomas Haller
b2d0bd8afe device: don't remove and re-add pending action in nm_device_bring_up()
(cherry picked from commit dba5e8e731)
2015-02-24 17:43:39 +01:00
Thomas Haller
b09b501766 device: don't add dummy value to @available_connections hash
GHashTable is optimized for usage of a set, where the key equals
the value. Don't add a dummy value.

(cherry picked from commit 3cb5d20c34)
2015-02-24 17:43:39 +01:00
Thomas Haller
1d1947b25e device: fix leaking queued NMActiveConnection
The queued activation request must transition state to
DEACTIVATED, otherwise it is not removed from the list
of active_connections in NMManager.

(cherry picked from commit b9da094da9)
2015-02-24 16:42:39 +01:00
Milo Casagrande
da32e0a841 po: updated Italian (it) translation (bgo #744998)
https://bugzilla.gnome.org/show_bug.cgi?id=744998
2015-02-24 14:36:52 +01:00
Thomas Haller
820607112a doc: clearify description of @options argument for DeviceWireless:RequestScan()
(cherry picked from commit 3f01e3d293)
2015-02-24 14:35:19 +01:00
Thomas Haller
a0619cc36e translations: avoid preprocessor strings inside translation macro
https://bugzilla.gnome.org/show_bug.cgi?id=740381
https://bugzilla.gnome.org/show_bug.cgi?id=744998

Backport commit 943db815ee from libnm-core
to libnm-util.

(cherry picked from commit 81e72d9483)
2015-02-24 14:32:49 +01:00
Bastien Nocera
5c722630a5 man: fix small typo in nmcli man page
https://bugzilla.gnome.org/show_bug.cgi?id=745007
(cherry picked from commit 06535fca29)
2015-02-23 14:22:10 +01:00
Thomas Haller
7f8e486723 keyfile/writer: fix password_raw_writer() to write NMSetting8021x:password-raw
After refactoring libnm-core to use GBytes instead of
GByteArray/DBUS_TYPE_G_UCHAR_ARRAY, it was forgotten to update
keyfile writer.

This causes keyfile writer to skip the NMSetting8021x:password-raw setting
and raise a g_critical() warning.

Fixes: c43f88907b
(cherry picked from commit c651b27793)
2015-02-19 13:13:07 +01:00
Lubomir Rintel
7496cad4aa build: don't run tests with valgrind by default
Only enable it when user requested it. The surpressions might not work for
everyone.

(cherry picked from commit be6ce67213)
2015-02-18 18:16:39 +01:00
Lubomir Rintel
e97a7613f9 manager: memleak: free the state file name on dispose
==12663== 45 bytes in 1 blocks are definitely lost in loss record 2,464 of 4,708
==12663==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==12663==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==12663==    by 0x7F6301E: g_strdup (gstrfuncs.c:356)
==12663==    by 0x4B8AE5: nm_manager_new (nm-manager.c:4793)
==12663==    by 0x432F3D: main (main.c:413)

(cherry picked from commit b1e6c9be91)
2015-02-18 18:16:31 +01:00
Lubomir Rintel
2a0fb46d68 agent-manager: memleak: unref the last agent for a request too
==29353== 620 (+620) (32 (+32) direct, 588 (+588) indirect) bytes in 1 (+1) blocks are definitely lost in loss record 6,905 of 7,076
==29353==    at 0x7CDBAC8: g_type_create_instance (gtype.c:1844)
==29353==    by 0x7CBF356: g_object_new_internal (gobject.c:1774)
==29353==    by 0x7CC0D4C: g_object_newv (gobject.c:1922)
==29353==    by 0x7CC14E3: g_object_new (gobject.c:1614)
==29353==    by 0x50B58A: nm_secret_agent_new (nm-secret-agent.c:489)
==29353==    by 0x50915F: impl_agent_manager_register_with_capabilities (nm-agent-manager.c:309)
==29353==    by 0x62649BE: invoke_object_method (dbus-gobject.c:1899)
==29353==    by 0x62649BE: object_registration_message (dbus-gobject.c:2161)
==29353==    by 0x649D5CE: _dbus_object_tree_dispatch_and_unlock (dbus-object-tree.c:1018)
==29353==    by 0x648F193: dbus_connection_dispatch (dbus-connection.c:4718)
==29353==    by 0x6261DB4: message_queue_dispatch (dbus-gmain.c:90)
==29353==    by 0x7F44AEA: g_main_dispatch (gmain.c:3111)
==29353==    by 0x7F44AEA: g_main_context_dispatch (gmain.c:3710)
==29353==    by 0x7F44E87: g_main_context_iterate.isra.29 (gmain.c:3781)

(cherry picked from commit 7d706daf3e)
2015-02-18 18:16:31 +01:00
Lubomir Rintel
be9293fe45 auth-utils: memleak: free the key when we steal data
==5177== 6 (+6) bytes in 1 (+1) blocks are definitely lost in loss record 118 of 6,581
==5177==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==5177==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==5177==    by 0x7F6301E: g_strdup (gstrfuncs.c:356)
==5177==    by 0x4AD902: nm_auth_chain_set_data (nm-auth-utils.c:194)
==5177==    by 0x50919E: impl_agent_manager_register_with_capabilities (nm-agent-manager.c:323)
==5177==    by 0x62649BE: invoke_object_method (dbus-gobject.c:1899)
==5177==    by 0x62649BE: object_registration_message (dbus-gobject.c:2161)
==5177==    by 0x649D5CE: _dbus_object_tree_dispatch_and_unlock (dbus-object-tree.c:1018)
==5177==    by 0x648F193: dbus_connection_dispatch (dbus-connection.c:4718)
==5177==    by 0x6261DB4: message_queue_dispatch (dbus-gmain.c:90)
==5177==    by 0x7F44AEA: g_main_dispatch (gmain.c:3111)
==5177==    by 0x7F44AEA: g_main_context_dispatch (gmain.c:3710)
==5177==    by 0x7F44E87: g_main_context_iterate.isra.29 (gmain.c:3781)
==5177==    by 0x7F451B1: g_main_loop_run (gmain.c:3975)

(cherry picked from commit da5c332151)
2015-02-18 18:16:31 +01:00
Lubomir Rintel
755c52758b connectivity: memleak: drop async result reference on complete
==5177== 104 (+104) bytes in 1 (+1) blocks are definitely lost in loss record 5,502 of 6,581
==5177==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==5177==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==5177==    by 0x7F6159F: g_slice_alloc (gslice.c:1007)
==5177==    by 0x7F61B6D: g_slice_alloc0 (gslice.c:1032)
==5177==    by 0x7CDB9A3: g_type_create_instance (gtype.c:1847)
==5177==    by 0x7CBF356: g_object_new_internal (gobject.c:1774)
==5177==    by 0x7CC0D4C: g_object_newv (gobject.c:1922)
==5177==    by 0x7CC14E3: g_object_new (gobject.c:1614)
==5177==    by 0x79A4C57: g_simple_async_result_new (gsimpleasyncresult.c:319)
==5177==    by 0x515B34: nm_connectivity_check_async (nm-connectivity.c:289)
==5177==    by 0x515D74: run_check (nm-connectivity.c:217)
==5177==    by 0x515DBF: idle_start_periodic_checks (nm-connectivity.c:229)

(cherry picked from commit e5499c558f)

Conflicts:
	src/nm-connectivity.c
2015-02-18 18:16:27 +01:00
Lubomir Rintel
e343507bd4 linux-platform: dont use-after-free the driver string
==1345== Invalid read of size 1
==1345==    at 0x827DC15: vfprintf (vfprintf.c:1642)
==1345==    by 0x8345D04: __vasprintf_chk (vasprintf_chk.c:66)
==1345==    by 0x7F882DB: vasprintf (stdio2.h:210)
==1345==    by 0x7F882DB: g_vasprintf (gprintf.c:316)
==1345==    by 0x7F6319C: g_strdup_vprintf (gstrfuncs.c:507)
==1345==    by 0x7F63258: g_strdup_printf (gstrfuncs.c:533)
==1345==    by 0x472833: nm_platform_link_to_string (nm-platform.c:2337)
==1345==    by 0x472A05: log_link (nm-platform.c:2754)
==1345==    by 0x9DC5D5F: ffi_call_unix64 (unix64.S:76)
==1345==    by 0x9DC57D0: ffi_call (ffi64.c:525)
==1345==    by 0x7CBA553: g_cclosure_marshal_generic (gclosure.c:1448)
==1345==    by 0x7CB9D34: g_closure_invoke (gclosure.c:768)
==1345==    by 0x7CCB34B: signal_emit_unlocked_R (gsignal.c:3483)
==1345==  Address 0xa91b5a0 is 0 bytes inside a block of size 5 free'd
==1345==    at 0x4C2ACE9: free (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==1345==    by 0x68E7D6D: link_free_data (link.c:223)
==1345==    by 0x6D47B1F: nl_object_free (object.c:186)
==1345==    by 0x46C31C: put_nl_object (nm-linux-platform.c:222)
==1345==    by 0x46C31C: link_change (nm-linux-platform.c:2354)
==1345==    by 0x46C87F: link_set_user_ipv6ll_enabled (nm-linux-platform.c:2583)
==1345==    by 0x4476C4: set_nm_ipv6ll (nm-device.c:4418)
==1345==    by 0x4476C4: ip6_managed_setup (nm-device.c:7515)
==1345==    by 0x453F12: _set_state_full (nm-device.c:7665)
==1345==    by 0x4B6609: add_device (nm-manager.c:1885)
==1345==    by 0x4B6880: system_create_virtual_device (nm-manager.c:1126)
==1345==    by 0x4B6B40: system_create_virtual_devices (nm-manager.c:1163)
==1345==    by 0x4B6E00: platform_link_added (nm-manager.c:2213)
==1345==    by 0x4B6E00: platform_link_cb (nm-manager.c:2228)
==1345==    by 0x9DC5D5F: ffi_call_unix64 (unix64.S:76)

(cherry picked from commit f93f0e0b15)
2015-02-18 18:15:35 +01:00
Lubomir Rintel
50348b708a ndp: memleak: unregister router advertisement handler on dispose
ndp_close() does not do that -- it only closes the socket. It's safe to call
even if we didn't start solicitation as it has a NULL-check.

==7745== 80 (+80) bytes in 2 (+2) blocks are definitely lost in loss record 3,983 of 5,735
==7745==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==7745==    by 0x6F57A2D: ndp_msgrcv_handler_register (libndp.c:1697)
==7745==    by 0x47572E: start (nm-lndp-rdisc.c:691)
==7745==    by 0x44A457: addrconf6_start_with_link_ready (nm-device.c:4280)
==7745==    by 0x44C1E7: linklocal6_complete (nm-device.c:3931)
==7745==    by 0x44C1E7: update_ip_config (nm-device.c:6667)
==7745==    by 0x44C2F8: queued_ip_config_change (nm-device.c:6688)
==7745==    by 0x7F44AEA: g_main_dispatch (gmain.c:3111)
==7745==    by 0x7F44AEA: g_main_context_dispatch (gmain.c:3710)
==7745==    by 0x7F44E87: g_main_context_iterate.isra.29 (gmain.c:3781)
==7745==    by 0x7F451B1: g_main_loop_run (gmain.c:3975)
==7745==    by 0x432F74: main (main.c:460)

(cherry picked from commit 5d9f9febfb)
2015-02-18 18:15:35 +01:00
Lubomir Rintel
098c2f2294 dhcp-client: memleak: free uuid on dispose
==7745== 37 (+37) bytes in 1 (+1) blocks are definitely lost in loss record 2,679 of 5,735
==7745==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==7745==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==7745==    by 0x7F6301E: g_strdup (gstrfuncs.c:356)
==7745==    by 0x45B097: set_property (nm-dhcp-client.c:851)
==7745==    by 0x7CBF688: object_set_property (gobject.c:1415)
==7745==    by 0x7CBF688: g_object_new_internal (gobject.c:1808)
==7745==    by 0x7CC1194: g_object_new_valist (gobject.c:2034)
==7745==    by 0x7CC14D0: g_object_new (gobject.c:1617)
==7745==    by 0x45FF9F: client_start (nm-dhcp-manager.c:253)
==7745==    by 0x460393: nm_dhcp_manager_start_ip4 (nm-dhcp-manager.c:308)
==7745==    by 0x44EB16: dhcp4_start (nm-device.c:3168)
==7745==    by 0x44EE15: act_stage3_ip4_config_start (nm-device.c:3440)
==7745==    by 0x455C9F: nm_device_activate_stage3_ip4_start (nm-device.c:4657)

(cherry picked from commit c26ef29a47)
2015-02-18 18:15:35 +01:00
Lubomir Rintel
8a9a999958 dhcp-client: memleak: free hostname on dispose
==7745== 11 (+11) bytes in 1 (+1) blocks are definitely lost in loss record 408 of 5,735
==7745==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==7745==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==7745==    by 0x7F6301E: g_strdup (gstrfuncs.c:356)
==7745==    by 0x45C188: nm_dhcp_client_start_ip4 (nm-dhcp-client.c:417)
==7745==    by 0x460147: client_start (nm-dhcp-manager.c:268)
==7745==    by 0x460393: nm_dhcp_manager_start_ip4 (nm-dhcp-manager.c:308)
==7745==    by 0x44EB16: dhcp4_start (nm-device.c:3168)
==7745==    by 0x44EE15: act_stage3_ip4_config_start (nm-device.c:3440)
==7745==    by 0x455C9F: nm_device_activate_stage3_ip4_start (nm-device.c:4657)
==7745==    by 0x456467: nm_device_activate_stage3_ip_config_start (nm-device.c:4801)
==7745==    by 0x7F44AEA: g_main_dispatch (gmain.c:3111)
==7745==    by 0x7F44AEA: g_main_context_dispatch (gmain.c:3710)
==7745==    by 0x7F44E87: g_main_context_iterate.isra.29 (gmain.c:3781)

(cherry picked from commit 76430f9cca)
2015-02-18 18:15:07 +01:00
Lubomir Rintel
3c640b1930 settings-connection: memleak: free filename on dispose
==4203== 97 (+97) bytes in 2 (+2) blocks are definitely lost in loss record 4,586 of 5,632
==4203==    at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==4203==    by 0x7F4A6F5: g_malloc (gmem.c:97)
==4203==    by 0x7F6301E: g_strdup (gstrfuncs.c:356)
==4203==    by 0x47E4C8: nm_settings_connection_set_filename (nm-settings-connection.c:2228)
==4203==    by 0x7CBF6EC: object_set_property (gobject.c:1415)
==4203==    by 0x7CBF6EC: g_object_new_internal (gobject.c:1828)
==4203==    by 0x7CC1194: g_object_new_valist (gobject.c:2034)
==4203==    by 0x7CC14D0: g_object_new (gobject.c:1617)
==4203==    by 0x12A08193: nm_ifcfg_connection_new (nm-ifcfg-connection.c:229)
==4203==    by 0x12A0542B: update_connection (plugin.c:225)
==4203==    by 0x12A0696A: add_connection (plugin.c:715)
==4203==    by 0x4814BB: nm_settings_add_connection (nm-settings.c:1030)
==4203==    by 0x4817DE: pk_add_cb (nm-settings.c:1136)

(cherry picked from commit 9b7c8db16a)
2015-02-18 18:15:07 +01:00