[network-manager-pptp] service: try to load nf_conntrack_pptp kernel module (rh #1214643)
- From: Jiří Klimeš <jklimes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-pptp] service: try to load nf_conntrack_pptp kernel module (rh #1214643)
- Date: Tue, 28 Apr 2015 11:44:45 +0000 (UTC)
commit 695d4f2f3d1003e18be6f97bbb103e44f75d3c2b
Author: Jiří Klimeš <jklimes redhat com>
Date: Fri Apr 17 16:54:49 2015 +0200
service: try to load nf_conntrack_pptp kernel module (rh #1214643)
The module is necessary with newer kernels so that PPTP work correctly.
https://bugzilla.redhat.com/show_bug.cgi?id=1214643
https://bugzilla.redhat.com/show_bug.cgi?id=1187328
src/nm-pptp-service.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/src/nm-pptp-service.c b/src/nm-pptp-service.c
index 28f3313..aadec4a 100644
--- a/src/nm-pptp-service.c
+++ b/src/nm-pptp-service.c
@@ -1313,6 +1313,8 @@ main (int argc, char *argv[])
GMainLoop *main_loop;
gboolean persist = FALSE;
GOptionContext *opt_ctx = NULL;
+ char *conntrack_module[] = { "/sbin/modprobe", "nf_conntrack_pptp", NULL };
+ GError *error = NULL;
GOptionEntry options[] = {
{ "persist", 0, 0, G_OPTION_ARG_NONE, &persist, N_("Don't quit when VPN connection
terminates"), NULL },
@@ -1359,6 +1361,16 @@ main (int argc, char *argv[])
if (!persist)
g_signal_connect (plugin, "quit", G_CALLBACK (quit_mainloop), main_loop);
+ /* Newer kernels require nf_conntrack_pptp kernel module so that PPTP
+ * worked correctly. Load the module now. Ignore errors, the module
+ * might not exist (older kernels).
+ * https://bugzilla.redhat.com/show_bug.cgi?id=1187328
+ */
+ if (!g_spawn_sync (NULL, conntrack_module, NULL, 0, NULL, NULL, NULL, NULL, NULL, &error)) {
+ g_warning ("modprobing nf_conntrack_pptp failed: %s", error->message);
+ g_error_free (error);
+ }
+
g_main_loop_run (main_loop);
g_main_loop_unref (main_loop);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]