mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 16:14:40 +00:00
openvpn|wireguard: close-on-exec
This commit is contained in:
parent
033402265e
commit
d08069699f
@ -239,7 +239,7 @@ if (isset($opts['h']) || empty($args) || !in_array($args[0], ['start', 'stop', '
|
||||
$carp_if_flag = 'down';
|
||||
}
|
||||
$server_devs[] = (string)$node->interface;
|
||||
$statHandle = fopen($node->statFilename, "a+");
|
||||
$statHandle = fopen($node->statFilename, 'a+e');
|
||||
if (flock($statHandle, LOCK_EX)) {
|
||||
$ifdetails = legacy_interfaces_details((string)$node->interface);
|
||||
switch ($action) {
|
||||
|
||||
@ -159,7 +159,7 @@ if (isset($opts['h']) || empty($args) || !in_array($args[0], ['start', 'stop', '
|
||||
continue;
|
||||
}
|
||||
$instance_ids[] = $key;
|
||||
$statHandle = fopen($node->statFilename, "a+");
|
||||
$statHandle = fopen($node->statFilename, 'a+e');
|
||||
if (flock($statHandle, LOCK_EX)) {
|
||||
$instance_stats = ovpn_instance_stats($node, $statHandle);
|
||||
$destroy_if = !empty($instance_stats['dev_type']) && $instance_stats['dev_type'] != $node->dev_type;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user