diff options
author | David Cantrell <dcantrell@redhat.com> | 2008-12-17 19:33:47 -1000 |
---|---|---|
committer | David Cantrell <dcantrell@redhat.com> | 2008-12-18 10:18:03 -1000 |
commit | 649b32204bfb7386cdc5eda213721d698fea2a08 (patch) | |
tree | c56bd69121498c166ba40f5f63cd020aaee5a22d /loader | |
parent | eca10a326af815cbb08b306881d559f1da28743f (diff) | |
download | anaconda-649b32204bfb7386cdc5eda213721d698fea2a08.tar.gz anaconda-649b32204bfb7386cdc5eda213721d698fea2a08.tar.xz anaconda-649b32204bfb7386cdc5eda213721d698fea2a08.zip |
Reduce direct D-Bus calls in isys/iface.c.
The first patch in a two (possibly three) patch series that replaces
some direct D-Bus code with libnm-glib calls. Much less verbose,
easier to read, etc, etc.
Tested this patch locally and all seems well. Calling it a day for
now.
[rawhide]
Diffstat (limited to 'loader')
-rw-r--r-- | loader/loader.c | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/loader/loader.c b/loader/loader.c index a028f1c0d..ec54d6f59 100644 --- a/loader/loader.c +++ b/loader/loader.c @@ -1781,10 +1781,6 @@ int main(int argc, char ** argv) { struct loaderData_s loaderData; - char *error_str = NULL; - DBusError error; - DBusConnection *connection = NULL; - char *path; char * cmdLine = NULL; char * ksFile = NULL; @@ -1950,21 +1946,8 @@ int main(int argc, char ** argv) { } /* Start NetworkManager now so it's always available to talk to. */ - dbus_error_init(&error); - connection = dbus_bus_get(DBUS_BUS_SYSTEM, &error); - if (connection == NULL) { - if (dbus_error_is_set(&error)) { - logMessage(DEBUGLVL, "%s (%d): %s: %s", __func__, - __LINE__, error.name, error.message); - dbus_error_free(&error); - } - } else { - rc = iface_start_NetworkManager(connection, &error_str); - if (rc != 0) { - logMessage(INFO, "failed to start NetworkManager (%d): error %d (%s)", - __LINE__, rc, error_str ? error_str : "unknown"); - } - } + if (iface_start_NetworkManager()) + logMessage(INFO, "failed to start NetworkManager"); if (!FL_CMDLINE(flags)) startNewt(); |