Commit Graph

13873 Commits

Author SHA1 Message Date
Lubomir Rintel
da5c332151 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
e5499c558f 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
f93f0e0b15 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
5d9f9febfb 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
c26ef29a47 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
76430f9cca 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)
2015-02-18 18:10:47 +01:00
Lubomir Rintel
9b7c8db16a 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)
2015-02-18 18:10:47 +01:00
Aleksander Morgado
5df024f57a wwan: don't assume DNS info is always available
Fixes segfault with e.g. Ericsson modems that reply just with IP+gateway,
without DNS info.

 [mm-port-serial-at.c:440] debug_log(): (ttyACM8): --> 'AT*E2IPCFG?<CR>'
 [mm-port-serial-at.c:440] debug_log(): (ttyACM8): <-- '<CR><LF>*E2IPCFG: (1,"10.191.64.12")(2,"10.191.64.10")<CR><LF>'
 [mm-port-serial-at.c:440] debug_log(): (ttyACM8): <-- '<CR><LF>OK<CR><LF>'
 [mm-port-serial.c:1296] mm_port_serial_close(): (ttyACM8) device open count is 1 (close)
 [mm-port.c:95] mm_port_set_connected(): (wwan0): port now connected
 [mm-base-bearer.c:488] connect_ready(): Connected bearer '/org/freedesktop/ModemManager1/Bearer/0'
 [mm-iface-modem.c:1392] __iface_modem_update_state_internal(): Modem /org/freedesktop/ModemManager1/Modem/0: state changed (connecting -> connected)

 <info> Activation (ttyACM8) Stage 3 of 5 (IP Configure Start) started...
 <info> (ttyACM8): device state change: config -> ip-config (reason 'none') [50 70 0]
 <info> Activation (ttyACM8) Stage 4 of 5 (IPv6 Configure Timeout) scheduled...
 <info> Activation (ttyACM8) Stage 3 of 5 (IP Configure Start) complete.
 <info> (ttyACM8): IPv4 static configuration:
 <info>   address 10.191.64.12/28
 <info>   gateway 10.191.64.10
Errore di segmentazione

http://lists.freedesktop.org/archives/modemmanager-devel/2015-February/001758.html
2015-02-17 12:06:09 -06:00
Pavel Šimerda
cd5d5655ba auth: don't enforce user session
Access to connection configuration should not be blocked by absence of a
user session tracked using logind or consolekit. Access control based on
UID is sufficient.

This patch ensures that the user can always access connections even if
he doesn't have a session tracked by logind or consolekit and even when
NetworkManager is not built with logind or consolekit support.

Please note that presence or absence of a session tracked by logind or
consolekit doesn't carry any security information.

Acked-By: Thomas Haller <thaller@redhat.com>
Acked-By: Dan Williams <dcbw@redhat.com>
2015-02-17 17:11:08 +01:00
Pavel Šimerda
75221bbc1b agent: don't enforce user session
Agent registration should not be blocked by absence of a user session
tracked using logind or consolekit. Access control based on UID is
sufficient.

This patch ensures that the user can always register a secret agent,
even if he doesn't have a session tracked by logind or consolekit and
even when NetworkManager is not built with logind or consolekit support.

Please note checking for presence or absence of a user session tracked
by logind has no value in this context.

Acked-By: Thomas Haller <thaller@redhat.com>
Acked-By: Dan Williams <dcbw@redhat.com>
2015-02-17 16:54:18 +01:00
Dan Williams
511a7395bf dhcp: gracefully recover from failed DHCP BOUND state transitions (bgo #743700)
First, configure.ac's grep was wrong and wasn't setting DHCPCD_SUPPORTS_IPV6,
which caused dhcpcd to acquire a DHCPv6 address when NM didn't think that
was going to happen, and thus DHCP options couldn't be parsed.

Second, even if that does happen, don't just assert and quit, but set the
DHCP state to failed.

https://bugzilla.gnome.org/show_bug.cgi?id=743700
2015-02-17 08:51:26 -06:00
Thomas Haller
7de9bc618a default-route-manager/trivial: add code comment 2015-02-17 12:28:55 +01:00
Thomas Haller
d4858013cf default-route-manager: own a reference to platform instance
Singletons subscribing (and more importantly unsubscribing)
from other singletons should own a reference to them to avoid
errors during destruction.
2015-02-17 11:39:39 +01:00
Thomas Haller
87517714f1 default-route-manager: avoid crash while disposing of NMDefaultRouteManager
During dipose(), NMDefaultRouteManager unrefed all the source pointers
in its list -- thereby having dangling pointers in the list of entries.

The unrefing can cause the final destruction of the device (during
shutdown), which would again call into NMDefaultRouteManager.

Fix this by ensuring that after disposing starts, all external calls
into NMDefaultRouteManager return early.

    #0  0x00007ffff4a2cc60 in g_logv (log_domain=0x535b51 "NetworkManager", log_level=G_LOG_LEVEL_CRITICAL, format=<optimized out>, args=args@entry=0x7fffffffd530) at gmessages.c:1046
    #1  0x00007ffff4a2ce9f in g_log (log_domain=log_domain@entry=0x535b51 "NetworkManager", log_level=log_level@entry=G_LOG_LEVEL_CRITICAL, format=format@entry=0x528f68 "file %s: line %d (%s): should not be reached") at gmessages.c:1079
    #2  0x000000000049b83b in _ipx_update_default_route (vtable=vtable@entry=0x7a49c0 <vtable_ip6>, self=0x7d1350 [NMDefaultRouteManager], source=source@entry=0x8b64e0) at nm-default-route-manager.c:659
    #3  0x000000000049c652 in nm_default_route_manager_ip6_update_default_route (self=<optimized out>, source=source@entry=0x8b64e0) at nm-default-route-manager.c:819
    #4  0x00000000004526a8 in _cleanup_generic_post (self=self@entry=0x8b64e0, deconfigure=deconfigure@entry=0) at devices/nm-device.c:7235
    #5  0x0000000000452bc0 in dispose (object=0x8b64e0) at devices/nm-device.c:8324
    #6  0x00007ffff4d29cbc in g_object_unref (_object=0x8b64e0) at gobject.c:3133
    #7  0x0000000000499091 in _entry_free (entry=0x8bf140) at nm-default-route-manager.c:187
    #8  0x00007ffff49fa82b in g_ptr_array_foreach (array=0x81d220, func=0x499080 <_entry_free>, user_data=0x0) at garray.c:1502
    #9  0x00007ffff49fa8c0 in ptr_array_free (array=0x81d220, flags=FREE_SEGMENT) at garray.c:1088
    #10 0x00007ffff49fa939 in g_ptr_array_free (array=<optimized out>, free_segment=free_segment@entry=1) at garray.c:1075
    #11 0x000000000049abcf in dispose (object=0x7d1350 [NMDefaultRouteManager]) at nm-default-route-manager.c:1357
    #12 0x00007ffff4d29cbc in g_object_unref (_object=0x7d1350) at gobject.c:3133
    #13 0x00007ffff7deb507 in _dl_fini () at dl-fini.c:252
    #14 0x00007ffff4658382 in __run_exit_handlers (status=status@entry=0, listp=0x7ffff49d66a0 <__exit_funcs>, run_list_atexit=run_list_atexit@entry=true) at exit.c:82
    #15 0x00007ffff46583d5 in __GI_exit (status=status@entry=0) at exit.c:104
    #16 0x0000000000432fd6 in main (argc=1, argv=0x7fffffffdeb8) at main.c:473
2015-02-17 11:38:56 +01:00
Thomas Haller
9d6b67012c trivial: fix spelling in comment 2015-02-17 07:10:01 +01:00
Lubomir Rintel
bf6073b647 config: add configure and quit command line option
Useful for using the feature without having to hardcode it in configuration
(container set up scripts, development).

https://bugzilla.gnome.org/show_bug.cgi?id=744241
2015-02-16 18:14:25 +01:00
Thomas Haller
5040a8a851 config/tests: inject NMDBusManager for tests in NMDevice stub
We don't need the bus for the tests and the manager may warn when it
is not available.

  $ (cd src/tests/config/; env -i DBUS_SYSTEM_BUS_ADDRESS=meow ./test-config)

  /config/parse-error: OK
  /config/no-auto-default: NetworkManager-Message: <info>  Could not connect to the system bus; only the private D-Bus socket will be available.
  /bin/sh: line 5: 29997 Trace/breakpoint trap   ${dir}$tst
  FAIL: test-config

This reverts commit 6994454461 for the
most part. It's not sufficient to disable logging warnings. Creating
a DBus Manager might affect the system in undesired ways.
2015-02-16 17:54:43 +01:00
Thomas Haller
9b16e85ece dbus-manager: add nm_dbus_manager_setup() function for testing 2015-02-16 17:42:01 +01:00
Thomas Haller
99465a34ca dbus-manager: refactor singleton getter dropping g_once_init_enter()
The class itself is not thread-safe, so no need for guarding
the creation with g_once_init_*().

Also, assert against multiple creation and log a line when
creating the singleton. The getter is now more similar to what
is created by NM_DEFINE_SINGLETON_GETTER().
2015-02-16 17:38:14 +01:00
Thomas Haller
5e74891b58 test: fix setup of logging for no-expect-message
Tests with assert-logging would never overwrite the logging level,
even if no-expect-message was set. Allow resetting the logging level
if no-expect-message is mixed with explicitly setting up logging.

    NMTST_DEBUG='log-level=DEBUG,log-domains=ALL,no-expect-message' make check -C src/tests/config/
2015-02-16 16:09:40 +01:00
Thomas Haller
96b8b99c7d core: fix memleak in NMDBusManager:private_server_new() 2015-02-16 10:02:34 +01:00
Jiří Klimeš
37becd2ee6 examples: add a Lua example setting user name for a VPN connection 2015-02-11 13:34:38 +01:00
Jiří Klimeš
0ff9b75387 nmcli: allow adding 'generic' connections via nmcli connection add
'nmcli connection edit' already allows adding and editing generic connections
(added by 2a2af5825a).
2015-02-11 10:51:49 +01:00
Lubomir Rintel
6994454461 tests: ignore warnings upon DBus manager initialization
We don't need the bus for the tests and the manager may warn it's not
available:

  /config/parse-error: OK
  /config/no-auto-default: NetworkManager-Message: <info>  Could not connect to the system bus; only the private D-Bus socket will be available.
  /bin/sh: line 5: 29997 Trace/breakpoint trap   ${dir}$tst
  FAIL: test-config

Fixes: e7356ef0a6
2015-02-10 18:01:39 +01:00
Dan Williams
ad90f2f0ea ifcfg-rh: fix memleak in test-ifcfg-rh.c 2015-02-10 14:38:19 +01:00
Dan Williams
51b3540ae4 tests: fix memleaks in test-wifi-ap-utils.c 2015-02-10 13:56:16 +01:00
Jiří Klimeš
21c9c7e21c examples: add a Lua example getting IP configuration of a device
Unfortunately, there is a bug in lgi library causing the incorrect values
being returned and the example crashes. I am going to send a patch to lgi
to fix the issues.
2015-02-10 10:35:41 +01:00
Thomas Haller
95a750e4fa tests: allow running tests without valgrind by setting NMTST_NO_VALGRIND
When configuring with --with-valgrind, tests will be invoked
via valgrind. That significantly slows down the tests. Allow
user to set the environment variable NMTST_NO_VALGRIND to invoke
tests directly, even when valgrind was enabled at configure time.
2015-02-09 15:49:58 +01:00
Lubomir Rintel
2981839bde test: initialize auto-destructed pointers
Otherwise the compiler complains that they could be left uninitialized in case
the function returns too early.

Fixes: 76745817c3
2015-02-09 15:19:30 +01:00
Thomas Haller
b0b15e4718 libnm-glib/tests: fix calling tests without valgrind
Fixes: e7356ef0a6
2015-02-09 14:51:56 +01:00
Thomas Haller
2f595aba80 core: merge branch 'th/memleaks'
Fix memleaks and enable valgrind checks for most unit tests except
ifupdown plugin. For ifupdown tests, there are some leaks that are
not yet fixed. This is still to do.

To run checks with valgrind, configure with --with-valgrind.

Especially for libnm and libnm-glib tests, there are several leaks
that are (probably?) not the fault of NetworkManager code. Hence,
several suppressions were added to valgrind.suppressions.
On different systems and different version of glib, these suppressions
might not match and the test will fail there.

The valgrind.suppressions should be reviewed, cleaned up and adjusted
for more systems (and different glib library versions).
2015-02-09 12:51:43 +01:00
Thomas Haller
cfa4560073 tests: fail valgrind script if log file is non-empty 2015-02-09 12:10:13 +01:00
Thomas Haller
e7356ef0a6 libnm/tests: enable valgrind for libnm tests 2015-02-09 12:10:13 +01:00
Thomas Haller
bf68917ca3 libnm/tests: add valgrind suppressions 2015-02-09 12:10:13 +01:00
Thomas Haller
76745817c3 libnm/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:08 +01:00
Thomas Haller
c50f30e79c tests: enable valgrind tests for tests 2015-02-09 11:51:07 +01:00
Thomas Haller
6853d07f05 platform/tests: reenable valgrind tests
valgrind tests for platform were wrongly disabled.

Fixes: e3784fa618
2015-02-09 11:51:07 +01:00
Thomas Haller
d5f8312996 tests: add valgrind suppression for callouts tests 2015-02-09 11:51:07 +01:00
Thomas Haller
171a9eabc6 tests: add valgrind suppression for test-general-with-expect
==8781== Syscall param rt_sigaction(act->sa_flags) points to uninitialised byte(s)
    ==8781==    at 0x5E547DD: __libc_sigaction (sigaction.c:64)
    ==8781==    by 0x8149025: unref_unix_signal_handler_unlocked (gmain.c:4981)
    ==8781==    by 0x81490BF: g_child_watch_finalize (gmain.c:5025)
    ==8781==    by 0x8149535: g_source_unref_internal (gmain.c:1997)
    ==8781==    by 0x814C377: g_main_context_dispatch (gmain.c:3094)
    ==8781==    by 0x814C627: g_main_context_iterate.isra.24 (gmain.c:3713)
    ==8781==    by 0x814CA39: g_main_loop_run (gmain.c:3907)
    ==8781==    by 0x11AC8B: test_nm_utils_kill_child_async_do (test-general-with-expect.c:90)
    ==8781==    by 0x119769: test_nm_utils_kill_child (test-general-with-expect.c:292)
    ==8781==    by 0x81705E0: g_test_run_suite_internal (gtestutils.c:2067)
    ==8781==    by 0x81707A5: g_test_run_suite_internal (gtestutils.c:2138)
    ==8781==    by 0x8170B1A: g_test_run_suite (gtestutils.c:2189)
    ==8781==  Address 0xffeffed28 is on thread 1's stack
    ==8781==
    {
       <insert_a_suppression_name_here>
       Memcheck:Param
       rt_sigaction(act->sa_flags)
       fun:__libc_sigaction
       fun:unref_unix_signal_handler_unlocked
       fun:g_child_watch_finalize
       fun:g_source_unref_internal
       fun:g_main_context_dispatch
       fun:g_main_context_iterate.isra.24
       fun:g_main_loop_run
       fun:test_nm_utils_kill_child_async_do
       fun:test_nm_utils_kill_child
       fun:g_test_run_suite_internal
       fun:g_test_run_suite_internal
       fun:g_test_run_suite
    }
2015-02-09 11:51:07 +01:00
Thomas Haller
624aa51614 supplicant/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
d74a3d0a02 dhcp/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
63f5a22ad7 config/tests: fix memleak in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
a82d94a64e device: refactor dispose/cleanup of NMDevice to free members in finalize
NMTestDevice does not invoke dispose(), hence it leaks memory which causes
false warnings in testing.
Some minor refactring to let dispose() clear the fields, but free it
later in finalize(). This avoids memleaks in the NMTestDevice stub.
2015-02-09 11:51:07 +01:00
Thomas Haller
ae73320b8c libnm/tests: fix memleaks in tests for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
0750d934bf ifcfg-rh/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
fbe8c0ed87 ibft/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
9a2f2ed7fd keyfile/tests: fix memleaks in test code for valgrind 2015-02-09 11:51:07 +01:00
Thomas Haller
1ba16f44cf callouts/tests: fix memleak in test code for valgrind 2015-02-09 11:51:06 +01:00
Thomas Haller
1680bf3ad1 core/tests: fix memleak in tests to avoid valgrind warnings 2015-02-09 11:51:06 +01:00
Thomas Haller
1935fca09a dhcp: fix memleak in process_dhclient_rfc3442_route() 2015-02-09 11:51:06 +01:00