interfaces: for specific device edit pages avoid reloading device again #5637

The device reconfigure is done unconditionally before configuring the attached
interface.  If we use reload we will configure the interface again, but if the
interface is disabled we wouldn't trigger the device creation.  So go back to
the former code which didn't exhibit any real issue before we used $reload.
This commit is contained in:
Franco Fichtner 2022-06-17 09:29:23 +02:00
parent 7aecb367c8
commit 2862eaf0cc
4 changed files with 4 additions and 4 deletions

View File

@ -225,7 +225,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
ifgroup_setup();
$confif = convert_real_interface_to_friendly_interface_name($bridge['bridgeif']);
if ($confif != '') {
interface_configure(false, $confif, true);
interface_configure(false, $config);
}
header(url_safe('Location: /interfaces_bridge.php'));
exit;

View File

@ -128,7 +128,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
ifgroup_setup();
$confif = convert_real_interface_to_friendly_interface_name($gif['gifif']);
if ($confif != '') {
interface_configure(false, $confif, true);
interface_configure(false, $confif);
}
header(url_safe('Location: /interfaces_gif.php'));
exit;

View File

@ -98,7 +98,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
ifgroup_setup();
$confif = convert_real_interface_to_friendly_interface_name($gre['greif']);
if ($confif != '') {
interface_configure(false, $confif, true);
interface_configure(false, $confif);
}
header(url_safe('Location: /interfaces_gre.php'));
exit;

View File

@ -169,7 +169,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
_interfaces_lagg_configure($lagg);
$confif = convert_real_interface_to_friendly_interface_name($lagg['laggif']);
if ($confif != '') {
interface_configure(false, $confif, true);
interface_configure(false, $confif);
}
header(url_safe('Location: /interfaces_lagg.php'));
exit;