Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
NetworkManager-l2tp
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
CeRiAl
NetworkManager-l2tp
Commits
d9798da0
Commit
d9798da0
authored
Jan 16, 2011
by
Alexey Torkhov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't create unused secrets file.
parent
37a93a73
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
19 deletions
+0
-19
nm-l2tp-service.c
src/nm-l2tp-service.c
+0
-19
No files found.
src/nm-l2tp-service.c
View file @
d9798da0
...
...
@@ -841,8 +841,6 @@ nm_l2tp_start_l2tpd_binary (NML2tpPlugin *plugin,
g_ptr_array_add
(
l2tpd_argv
,
(
gpointer
)
g_strdup
(
"-D"
));
g_ptr_array_add
(
l2tpd_argv
,
(
gpointer
)
g_strdup
(
"-c"
));
g_ptr_array_add
(
l2tpd_argv
,
(
gpointer
)
g_strdup_printf
(
"/var/run/nm-xl2tpd.conf.%d"
,
my_pid
));
g_ptr_array_add
(
l2tpd_argv
,
(
gpointer
)
g_strdup
(
"-s"
));
g_ptr_array_add
(
l2tpd_argv
,
(
gpointer
)
g_strdup_printf
(
"/var/run/nm-l2tp-secrets.%d"
,
my_pid
));
g_ptr_array_add
(
l2tpd_argv
,
NULL
);
if
(
!
g_spawn_async
(
NULL
,
(
char
**
)
l2tpd_argv
->
pdata
,
NULL
,
...
...
@@ -891,7 +889,6 @@ nm_l2tp_config_write (NML2tpPlugin *plugin,
gint
fdtmp1
=
-
1
;
gint
conf_fd
=
-
1
;
gint
pppopt_fd
=
-
1
;
gint
secret_fd
=
-
1
;
filename
=
g_strdup_printf
(
"/var/run/nm-xl2tpd.conf.%d"
,
pid
);
conf_fd
=
open
(
filename
,
O_RDWR
|
O_CREAT
|
O_TRUNC
,
S_IRUSR
|
S_IWUSR
);
...
...
@@ -920,21 +917,6 @@ nm_l2tp_config_write (NML2tpPlugin *plugin,
return
FALSE
;
}
filename
=
g_strdup_printf
(
"/var/run/nm-l2tp-secrets.%d"
,
pid
);
secret_fd
=
open
(
filename
,
O_RDWR
|
O_CREAT
|
O_TRUNC
,
S_IRUSR
|
S_IWUSR
);
g_free
(
filename
);
if
(
secret_fd
==
-
1
)
{
close
(
conf_fd
);
close
(
pppopt_fd
);
g_set_error
(
error
,
NM_VPN_PLUGIN_ERROR
,
NM_VPN_PLUGIN_ERROR_LAUNCH_FAILED
,
"%s"
,
"Could not write secrets."
);
return
FALSE
;
}
/* L2TP options */
write_config_option
(
conf_fd
,
"[global]
\n
"
);
write_config_option
(
conf_fd
,
"access control = yes
\n
"
);
...
...
@@ -1076,7 +1058,6 @@ nm_l2tp_config_write (NML2tpPlugin *plugin,
close
(
conf_fd
);
close
(
pppopt_fd
);
close
(
secret_fd
);
return
TRUE
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment