Commit Graph

4279 Commits

Author SHA1 Message Date
Dan Williams
db4f5cedf7 2005-05-05 Dan Williams <dcbw@redhat.com>
* Expose activation stages to NetworkManager clients, like the applet
	* Add Diana's progress icons to the applet, cued off NM activation stage
	* Use more descriptive tooltips, cued off NM activation stage


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@611 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-06 02:58:06 +00:00
Ray Strode
8b6b5aea0f 2005-05-05 Ray Strode <rstrode@redhat.com>
* src/nm-netlink-monitor.c:
		- Use clear_event_source instead of g_nullify_pointer() again.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@610 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-05 23:30:59 +00:00
Dan Williams
1ea8594505 2005-05-05 Dan Williams <dcbw@redhat.com>
* gnome/applet/main.c
		- Fix session management so the applet is actually managed now

	* gnome/applet/passphrase-dialog.c
		- (nmi_passphrase_dialog_show): bash focus-stealing prevention in the face


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@609 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-05 21:07:22 +00:00
Dan Williams
88a56d5435 2005-05-05 Dan Williams <dcbw@redhat.com>
Suggestion from Bill Moss:
	* src/NetworkManagerSystem.c
		- (nm_system_device_set_up_down_with_iface): ignore ENODEV


	* src/NetworkManager.c
		- (nm_data_free): move destruction of the various managers after
			release of device list, because deactivating and freeing a device
			requires at least the named manager
		- (nm_poll_and_update_wireless_link_state):
		  (nm_device_link_activated):
		  (nm_device_link_deactivated):
			don't grab the device list lock when actually updating device
			link status or strength, since nm_device_set_link_active()
			needs to call nm_get_active_device(), which also locks the device list.

	* src/NetworkManagerDevice.c
		- (nm_device_set_link_active): if a device's link switches from off->on,
			and it's wired, and the active device is wireless (or there is no
			active device), activate the new device whose link just came on
		- (link_to_specific_ap): try to smooth over intermittency in wireless links
			my only calling the link to the current ap "failed" when more than 2
			consecutive link checks have failed


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@606 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-05 16:52:04 +00:00
Dan Williams
bf10aaa297 2005-05-04 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_probe_wireless_link_state): don't lock the scan mutex here
			but let link_to_specific_ap() do the locking where it needs

	Patch from Bill Moss:
	* src/NetworkManagerSystem.c
		- Set MTU of VPN devices to 1412


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@605 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-04 21:23:09 +00:00
Dan Williams
279c6d76b0 Remove old file (autoip.h) from Makefile.am
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@603 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-04 18:44:11 +00:00
Dan Williams
276e0a4d30 2005-05-04 Dan Williams <dcbw@redhat.com>
* Remove NM_STATE_SCANNING from NetworkManager.h and applet code

	* Fix some holes in device activation and retaining the currently connected
		access point


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@602 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-04 18:11:40 +00:00
Dan Williams
7397161e03 Patch from Colin Walters: fix g_assert() usage
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@599 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-03 21:06:28 +00:00
Dan Williams
567b5e3d31 2005-05-03 Dan Williams <dcbw@redhat.com>
* Kill dhcpcd.  We now use "dhcdbd", a dbus daemon that controls dhclient.
	  This means that NetworkManager shouldn't have DHCP issues anymore.  It also
	  means you need dhcdbd, which you can get here (get the latest one):

		http://people.redhat.com/jvdias/dhcdbd/

	  Technically NetworkManager can use any DHCP daemon that uses the same DBUS
	  interface as dhcdbd.

	* Rewrite device activation to facilitate the new DHCP infrastructure and
	  future improvements.  Its now "activation request" based, ie there is a single
	  activation request composed of the device, access point, and other info which
	  follows the entire activation process.  There are 5 stages of the activation
	  process which correspond to:

		1) Device preparation
		2) Device configuration (bring it up, set ESSID/Key/etc)
		3) IP Config Start (fire off DHCP if we're using it)
		4) IP Config Get (grab config from DHCP or static config files)
		5) IP Config Commit (set device's IP address, DNS, etc)

	  Note that there is no longer a "scanning" step, since the access point must
	  be known _before_ activation starts.  If the access point drops out or does
	  not exist for some reason, the entire activation process fails and must be
	  restarted for a different access point or device.

	Patch from Bill Moss:
	* gnome/applet/applet.c
		- Fix type of vpn_failure dialog -> vpn_banner dialog


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@597 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-05-03 20:41:36 +00:00
Dan Williams
b3f87f16ab 2005-04-27 Dan Williams <dcbw@redhat.com>
* gnome/applet/applet-dbus-vpn.c
	  gnome/applet/applet.c
	  gnome/applet/applet.h
		- Fix up active VPN handling so that we reliably know when a VPN
			connection has been deactivated

	* src/vpn-manager/nm-vpn-manager.c
		- Remove duplicate VPNConnectionChange signal


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@593 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-28 12:09:15 +00:00
Dan Williams
aac770c185 2005-04-27 Dan Williams <dcbw@redhat.com>
Patch from Peter Jones:
	* Remove usage of varargs to fix crashes on PPC (RH #154336)

	Patch from Bill Moss:
	* src/NetworkManagerSystem.c
		- Fix checking of return value from ioctl()


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@592 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-28 02:50:54 +00:00
Dan Williams
14ae87c1a1 2005-04-27 Dan Williams <dcbw@redhat.com>
* Fix choosing of wireless networks and "Other wireless network..." from the applet
	* Warn and exit if icons cannot be found


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@590 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-28 01:54:46 +00:00
Dan Williams
20f9ccd86f 2005-04-27 Dan Williams <dcbw@redhat.com>
Patch from Tom Parker:
	* Update debian backend


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@588 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-28 01:37:37 +00:00
Dan Williams
a5dd14c305 2005-04-27 Dan Williams <dcbw@redhat.com>
* Merge the applet and the info-daemon, and move the converged
                applet under gnome/applet
        * Move libnm_glib to gnome/libnm_glib
        * Convert most dbus calls between the applet, info-daemon, and NM
                into async calls
        * Fix a few things valgrind noticed
        * Make NM broadcast state more reliably


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@586 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-27 18:05:16 +00:00
Dan Williams
7337e8132a 2005-04-15 Dan Williams <dcbw@redhat.com>
Patches from Tom Parker:
	- Fix memleaks
	- Join with worker thread rather than polling for its exit

	Patch from Bill Moss:
	- Cull duplicate ESSIDs from the scan list, taking highest strength AP


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@573 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-15 20:00:28 +00:00
Dan Williams
b6215ff296 2005-04-15 Dan Williams <dcbw@redhat.com>
- Fixes to pass 'make distcheck'


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@572 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-15 16:37:26 +00:00
Dan Williams
de1d417198 2005-04-15 Dan Williams <dcbw@redhat.com>
Initial VPN Support
		- supports 'vpnc'
		- reworks device IP configuration, backend files have changed and will need
			to be updated for all distributions.  I will try to do what I can for
			them, but I cannot test them.

	- Move named directory to src/named-manager
	- Make backends directory self-contained


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@571 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-15 15:43:42 +00:00
Dan Williams
294e4df1fb Fix debug message when setting broadcast address fails.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@565 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-06 19:36:03 +00:00
Dan Williams
66198cd398 Fix log message for ethtool check failure.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@562 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-06 19:16:31 +00:00
Dan Williams
3f811157c3 Fix warning messages somewhat
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@560 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-06 19:05:10 +00:00
Dan Williams
7136220856 2005-04-06 Dan Williams <dcbw@redhat.com>
Add debug code for socket/file descriptor leaks.  We register every socket
	that we open (except for stuff in dhcpcd/) for tracking, and print out the
	list of sockets that we forgot to close on shutdown.  This also consolidates
	about 4 places where we opened sockets into 1 function in NetworkManagerUtils.c


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@559 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-06 16:45:48 +00:00
Dan Williams
044014b1be 2005-04-04 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessAppletDbus.c
		- (nmwa_dbus_call_nm_method): remove some commented code

	* src/NetworkManagerAPList.[ch]
		- (nm_ap_list_remove_ap_by_essid): new function

	* src/NetworkManagerDevice.c
		- (nm_device_wireless_force_use): remove access points from the ignore list
			when the user forces them

	* src/nm-dbus-device.c
		- (nm_dbus_device_get_active_network): fix up escaping of object paths


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@557 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-04 21:24:58 +00:00
Dan Williams
85aa633ec8 Remove duped code, done below somewhere
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@555 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-04 18:56:26 +00:00
Dan Williams
1e22dba1ca 2005-04-04 Dan Williams <dcbw@redhat.com>
Patch from Tom Parker: include "nm-utils.h" for backend files that need it


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@553 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-04 16:24:36 +00:00
Dan Williams
737dce1fd7 2005-04-01 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c:
		- (nm_completion_scan_has_results): restore pre-completion-patch behavior
			of only erroring after the second consecutive scan times out.  Also
			don't exit when the card requires more time than we can give it, just
			log the event and continue.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@552 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-04 16:22:03 +00:00
Dan Williams
aba1b105ba Add missing signal.h
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@549 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-03 02:10:27 +00:00
Dan Williams
04eadd092c 2005-04-01 Dan Williams <dcbw@redhat.com>
Perform scans during device activation, if needed.  Both activation
	and scans run in the same GMainContext.  Therefore, if an access point
	is not found by the time the device starts activation, it will not
	be available until after activation.  We now try to scan during
	activation (in nm_wa_test) every 15s so that all available access
	points are more likely to be found and available for the activation
	procedure.

	Also change nm_wireless_link_state_handle() to only update the "best"
	AP if we are not forcing a device and if we are not about to change
	state.  This attempts to work around a race when forcing a device,
	where the forced AP would get cleared out too soon by the link state
	checking timeout in the main thread, and the activation attempt with
	that AP would fail.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@545 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-04-01 21:30:12 +00:00
Dan Williams
5ea536fa14 Fix debug code in nm_wireless_qual_to_percent() to actually compile
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@535 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-31 21:42:04 +00:00
Dan Williams
c1979229b6 2005-03-31 Dan Williams <dcbw@redhat.com>
Tighten up handling of wireless devices that don't support wireless
	scanning (ie, Orinoco).  Due to restructuring of code, these devices
	hadn't been doing pseudo-scanning for a while either and would just
	spin waiting for an access point.  They are now manual devices where
	the user must choose the access point from the menu every time.  All
	"allowed" access points are listed in the applet's menu regardless
	of whether or not they can be seen by the card, since it can't scan
	anyway.

	* src/NetworkManager.c
		- (nm_wireless_link_state_handle): new function, but only update
			the "best" ap for non-scanning devices when its not activating,
			and when no device is being forced on the card
		- (nm_link_state_monitor): split wireless link state handling out
			into separate function

	* src/NetworkManagerDevice.c
		- (nm_device_copy_allowed_to_dev_list): new function
		- (nm_device_new): populate non-scanning cards' AP lists with
			access points from the "allowed" list
		- (nm_device_new): don't start a scanning timeout for devices that
			can't scan
		- (nm_device_activation_schedule_finish): new parameter, should be
			the AP that failed to be connected to, pass it on to the
			activation finish function in NetworkManagerPolicy.c
		- (nm_device_activate_wireless): don't ever try to get a new AP
			for non-scanning devices, just fail.  The user must choose
			a new access point manually.
		- (nm_device_activate): grab the AP that failed connection and
			pass it on
		- (nm_device_update_best_ap): Clear the best AP if we don't have
			a link to it, user must manually choose a new one
		- (nm_device_do_pseudo_scan): remove function
		- (nm_device_wireless_process_scan_results): remove bits for non-
			scanning cards since they never get here
		- (nm_device_wireless_scan): remove bits for non-scanning devices,
			and fake the scan list for test devices a bit earlier

	* src/NetworkManagerPolicy.c
		- (nm_policy_activation_finish): use the failed_ap that we get
			passed rather than getting the best_ap from the card, which
			may have changed since we were scheduled
		- (nm_policy_allowed_ap_list_update): for non-scanning devices,
			update their scan list directly from the allowed list when
			we get updates to the allowed list from NetworkManagerInfo

	* src/NetworkManagerPolicy.h
		- New member for failed access point in NMActivationResult

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

	Driver Notification patch: notifies the user when their driver
		sucks.  Gives them the option to ignore further insertions
		of the card that has the sucky driver.

	* NetworkManager.h
		- Remove the SEMI_SUPPORTED member from the NMDriverSupportLevel
			enum and replace it with NO_CARRIER_DETECT and
			NO_WIRELESS_SCAN

	* panel-applet/NMWirelessApplet.[ch]
		- Merge essid.glade -> wireless-applet.glade
		- Implement the "Your driver sucks" notification dialog

	* panel-applet/NMWirelessAppletDbus.c
		- Change stuff from getSupportsCarrierDetect->getDriverSupportLevel
		- Grab hardware address for each device from NM too
		- Check whether the driver for each device sucks or not whenever
			a new device is noticed

	* panel-applet/NMWirelessAppletOtherNetworkDialog.c
		- Deal with stuff being in wireless-applet.glade now rather than essid.glade

	* src/NetworkManager.c
		- Fix a double-unref on device removal

	* src/NetworkManagerUtils.c
		- Set appropriate driver support level on a device that doesn't
			support scanning or carrier detection

	* src/nm-dbus-device.c
		- New "getHWAddress" dbus method on devices
		- getSupportsCarrierDetect -> getDriverSupportLevel


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@534 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-31 21:02:21 +00:00
Dan Williams
4c4be4c15e 2005-03-31 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_wireless_scan): Fix leak of scan results in some
			instances


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@532 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-31 16:13:06 +00:00
Dan Williams
66039f43b3 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManager.c
		- (nm_poll_and_update_wireless_link_state): make code less indented

	Patch from Bill Moss:
	* src/NetworkManager.c
		- (nm_device_update_link_state): Update signal strength on wireless
			devices every time we update link state too.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@531 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-30 04:39:35 +00:00
Dan Williams
17fd25ccf2 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_set_essid): Work around Orinoco cards which need
			extra time after setting the ESSID


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@530 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-29 22:15:28 +00:00
Dan Williams
7142df50e0 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- Merge one more bit of Peter Jones' completion patch


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@529 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-29 22:10:21 +00:00
Dan Williams
578f8d89f6 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_force_use): Fix possible segfault


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@526 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-29 21:55:03 +00:00
Dan Williams
4c462f46de 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- Use iw_get_ext() where we should rather than iw_set_ext()


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@524 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-29 21:44:38 +00:00
Dan Williams
767f1ea24f 2005-03-29 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_set_up_down): remove check for unsupported devices
			that caused NM to not bring devices up when they were
			added to the device list.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@523 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-29 16:47:21 +00:00
Dan Williams
b09c5c6d27 2005-03-28 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (mdio_read): Fix two bugs that caused all devices to fail
			the MII carrier detection support checks


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@514 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-28 15:29:46 +00:00
Dan Williams
2c976390c5 2005-03-26 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerDevice.c
		- (nm_device_wireless_scan): Remove duplicated scanning code


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@513 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-27 01:04:48 +00:00
Dan Williams
4acd2f31dc 2005-03-25 Dan Williams <dcbw@redhat.com>
* panel-applet/NMWirelessApplet.c
		- (nmwa_about_cb): Add some more contributors
		- (nmwa_update_state): show the applet when there's no connection
		- Enable the "Stop/Resume all wireless devices" option in the
			context menu
		- New "no connection" icon

	* src/NetworkManager.c
		- (nm_poll_and_update_wireless_link_state): don't do anything if
			wireless is disabled or we're asleep

	* src/NetworkManagerDHCP.c
		- Remove trailing "\n" on debug messages

	* src/NetworkManagerDbus.c
		- (nm_dbus_network_status_from_data): new state "asleep"

	* src/NetworkManagerDevice.c
		- Merge most of Peter Jones' "completion" patch that greatly reduces
			latency and wait times for most operations
		- (nm_device_wireless_scan): Don't scan when asleep

	* src/NetworkManagerPolicy.c
		- (nm_policy_get_best_device): return no device when asleep
		- (nm_policy_allowed_ap_list_update): From Bill Moss: merge properties
			for all wireless devices on update, not just active device

	* src/NetworkManagerUtils.c
		- Merge Peter Jones' "completion" patch

	* src/nm-dbus-nm.c
		- (nm_dbus_nm_set_wireless_enabled): bring down wireless devices when
			we're told to disable them
		- (nm_dbus_nm_sleep, nm_dbus_nm_wake): new functions for sleep/wake

	* utils/nm-utils.h
		- New variants of the warn/info/error/debug print functions that can take
			variables rather than static strings


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@510 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-26 03:42:05 +00:00
Dan Williams
8284a62c39 2005-03-24 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerUtils.c
		- (nm_get_device_driver_name): driver names are now on the parents of
			"Network Interface" objects, so look for them there


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@509 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-24 18:56:23 +00:00
Dan Williams
ce7587a331 2005-03-24 Dan Williams <dcbw@redhat.com>
* dhcpcd/dhcpcd.[ch]
	  src/NetworkManagerDHCP.c
		- Switch names from "*_record_*" -> "*_element_*" to clarify things a bit
			(ie, dhcp_option_record_len -> dhcp_option_element_len)

	* src/NetworkManagerDbus.c
		- spacing cleanups

	* src/nm-dbus-dhcp.c
		- Make the API suck less.  There is now only 1 type of each function,
			ie only "getInteger" and no longer also "getIntegerv".  All types
			are returned encapsulated in a DBUS_TYPE_ARRAY, even for options
			that will never have more than 1 element.  This should simplify
			things greatly.

	* test/nm-dhcp-opt-test.c
		- Make the tool not segfault
		- adapt to new DHCP Options API


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@506 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-24 18:25:36 +00:00
Dan Williams
b90aa8077a 2005-03-22 Dan Williams <dcbw@redhat.com>
* src/NetworkManager.c
		- (nm_wired_link_deactivated): actually ignore netlink events from
			wireless devices.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@504 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-22 21:27:51 +00:00
Dan Williams
a068f66a28 2005-03-22 Dan Williams <dcbw@redhat.com>
* src/NetworkManager.c
		- (nm_wired_link_activated): actually ignore netlink events from
			wireless devices.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@503 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-22 21:25:36 +00:00
Dan Williams
809915938f 2005-03-17 Dan Williams <dcbw@redhat.com>
Patch from Tom Parker:
	* src/nm-netlink-monitor.c
		- Include unistd.h
	* info-daemon/NetworkManagerInfoDbus.c
		- (nmi_dbus_update_network_auth_method): free GConf values

	Patch from Nathaniel McCallum <npmccallum@gentoo.org>:
	* src/NetworkManagerDevice.c
		- (nm_device_set_wireless_config): wait for successful
			association longer for some cards (Atheros a/b/g)


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@502 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-17 21:43:21 +00:00
Ray Strode
a750e3c2aa 2005-03-15 Ray Strode <rstrode@redhat.com>
* src/NetworkManager.c:
	(sigterm_pipe_handler):
	remove bogus FIXME


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@500 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-15 18:11:29 +00:00
Ray Strode
3e34da5beb 2005-03-15 Ray Strode <rstrode@redhat.com>
* src/NetworkManagerDbus.c:
	Fix some sign weirdness that gcc4 doesn't like,
	and add a header file so PPC can hopefully find
	SIGTRAP


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@499 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-15 15:32:50 +00:00
Ray Strode
dfcc12908b 2005-03-15 Ray Strode <rstrode@redhat.com>
Fix a few -Wall -Werror warnings

	* info-daemon/NetworkManagerInfo.c:
	(main): remove unused loop variable.

	* info-daemon/NetworkManagerInfoDbus.c:
	(nmi_dbus_nm_is_running): comment out
	unused static function

	* src/nm-netlink-monitor.c:
	(receive_pending_bytes):
	initialize output variables to NULL/0,
	on function failure (Problem pointed out
	by Bryan Clark).


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@498 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-15 15:08:38 +00:00
Ray Strode
278e500f99 2005-03-14 Ray Strode <rstrode@redhat.com>
Fourth (probably working) cut at porting to
	dbus 0.30 api and new hal. This cut adds
	some new logging macros to make debugging
	easier.

	* dispatcher-daemon/NetworkManagerDispatcher.c:
	* info-daemon/NetworkmanagerInfo.c:
	* info-daemon/NetworkManagerInfoPassphraseDialog.c:
	* info-daemon/NetworkManagerInfoVPN.c:
	* src/NetworkManager.c:
	* src/NetworkManagerAP.c:
	* src/NetworkManagerAPList.c:
	* src/NetworkManagerDHCP.c:
	* src/NetworkManagerDbus.c:
	* src/NetworkManagerDevice.c:
	* src/NetworkManagerPolicy.c:
	* src/NetworkManagerSystem.c:
	* src/NetworkManagerUtils.c:
	* src/NetworkManagerWireless.c:
	* src/autoip.c:
	* src/nm-dbus-nm.c:
	* src/backends/NetworkManagerDebian.c:
	* src/backends/NetworkManagerGentoo.c:
	* src/backends/NetworkManagerRedHat.c:
	* src/backends/NetworkManagerSlackware.c:
	use new logging macros.

	* dispatcher-daemon/NetworkManagerDispatcher.c:
	(nmd_dbus_filter): s/dbus_free/g_free/

	* info-daemon/Makefile.am: link in utils library.
	* info-daemon/NetworkmanagerInfo.c: use new logging
	macros.
	(nmi_dbus_get_network): don't assume enumerations
	are 32-bit.
	(nmi_dbus_nmi_message_handler): don't free what
	doesn't belong to us.

	* libnm_glib/libnm_glib.c:
	(libnm_glib_get_nm_status):
	(libnm_glib_init): don't free what doesn't
	belong to us.
	(libnm_glib_dbus): strdup result, so it doesn't get
	lost when message is unref'd.

	* panel-applet/NMWirelessAppletDbus.c:
	(nmwa_dbus_update_devices): s/dbus_free/g_free/

	* src/NetworkManager.c:
	(nm_monitor_wired_link_state): request initial status
	dump of all cards when we start up, instead of relying
	on /sys/.../carrier.
	(nm_info_handler), (nm_set_up_log_handlers):
	log handlers to specify what syslog priorites
	the logging macros default to.

	* src/NetworkManagerAPList.c:
	(nm_ap_list_populate_from_nmi):
	s/dbus_free_string_array/g_strfreev/

	* src/NetworkManagerDbus.c:
	(nm_dbus_get_network_object):
	validate d-bus message argument types.
	Advance message iterator after reading argument,
	prepend instead of append to GSList.

	* src/NetworkManagerDevice.c:
	(nm_device_probe_wired_link_status):
	remove redundant /sys in /sys path. remove wrong
	contents == NULL means has carrier assumption.

	* src/nm-netlink-monitor.c
	(nm_netlink_monitor_request_status): implement
	function to ask kernel to dump interface link
	status over netlink socket.

	* test/*.c: s/dbus_free/g_free/

	* utils/nm-utils.h:
	(nm_print_backtrace): new macro to print backtrace.
	(nm_get_timestamp): new macro to get sub-second precise
	unix timestamp.
	(nm_info), (nm_debug), (nm_warning), (nm_error):
	new logging functions. nm_info just prints,
	nm_debug includes timestamp and function,
	nm_warning includes function, nm_error includes
	backtrace and sigtrap.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@497 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-15 05:30:15 +00:00
Ray Strode
0790d2fc3e 2005-03-11 Ray Strode <rstrode@redhat.com>
Third (unfinished, partially working) cut at porting to
	dbus 0.30 api and new hal.

	* info-daemon/NetworkManagerInfoDbus.c:
		don't free null arrays.

	* panel-applet/NMWirelessAppletDbus.c:
	* src/nm-dbus-device.c:
	* src/nm-dbus-net.c:
	* src/NetworkManagerDbus.c: more
 	STRING -> OBJECT_PATH fun
	* src/NetworkManagerDevice.c:
	* src/NetworkManagerDevice.h:
	(rename nm_device_get_link_active): rename to
	nm_device_has_active_link
	(nm_device_wireless_link_active): rename to
	nm_device_probe_wireless_link_state
	(nm_device_wired_link_active): rename to
	nm_device_probe_wired_link_state.  Rewrite to
	use carrier file since hal doesn't maintain
	link state anymore.
	(nm_device_update_link_active): rename to
	nm_device_update_link_state
	* src/NetworkManagerPolicy.c
	  (nm_policy_activation_finish): check for NULL
	  MAC address.

	* src/Makefile.am:
	* src/NetworkManagerMain.h:
	* src/NetworkManager.c:
	* src/nm-netlink-monitor.c:
	* src/nm-netlink-monitor.h: New class to support
	monitoring wired ethernet link status, since HAL
	doesn't export that information anymore.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@495 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-11 20:12:57 +00:00
Ray Strode
587a50e6e8 2005-03-09 Ray Strode <rstrode@redhat.com>
Second (unfinished, unworking) cut at porting to
	dbus 0.30 api.

	* dispatcher-daemon/NetworkManagerDispatcher.c
	* info-daemon/NetworkManagerInfoDbus.c:
	* panel-applet/NMWirelessAppletDbus.c:
	* src/NetworkManagerDbusUtils.c:
	* src/NetworkManagerDbusUtils.h:
	* src/nm-dbus-device.c:
	* src/nm-dbus-nm.c:
	* test/nmtest.c: support dbus "object path" type

	* configure.in:
	* Makefile.am:
	* info-daemon/Makefile.am:
	* libnm_glib/Makefile.am:
	* panel-applet/Makefile.am:
	* dispatcher-daemon/Makefile.am
	* src/Makefile.am:
	* test/Makefile.am:
	* utils/Makefile.am:
	* utils/nm-utils.c:
	* utils/nm-utils.h: new utils static lib


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@494 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2005-03-09 16:39:15 +00:00