summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@vyos.io>2025-07-31 15:35:36 +0100
committerGitHub <noreply@github.com>2025-07-31 15:35:36 +0100
commit9401f1a5399e4386244c9bce8017a0d455bdb188 (patch)
treead2f392d9dbe9772cfefc796775ad4dc008578ba /src
parentab106ad654cb9ac7a511306759d6e37da2d6b8c4 (diff)
parent9724b301a0d44854ef7f334de5aedf727713bc52 (diff)
downloadvyos-1x-9401f1a5399e4386244c9bce8017a0d455bdb188.tar.gz
vyos-1x-9401f1a5399e4386244c9bce8017a0d455bdb188.zip
Merge pull request #4631 from sever-sever/T7668
T7668: Fix image update due to None kernel options
Diffstat (limited to 'src')
-rwxr-xr-xsrc/op_mode/image_installer.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/op_mode/image_installer.py b/src/op_mode/image_installer.py
index 8c9d7eddd..2a9830f37 100755
--- a/src/op_mode/image_installer.py
+++ b/src/op_mode/image_installer.py
@@ -494,10 +494,10 @@ def get_cli_kernel_options(config_file: str) -> list:
config = ConfigTree(read_file(config_file))
config_dict = loads(config.to_json())
kernel_options = dict_search('system.option.kernel', config_dict)
- k_cpu_opts = kernel_options.get('cpu', {})
- k_memory_opts = kernel_options.get('memory', {})
if kernel_options is None:
kernel_options = {}
+ k_cpu_opts = kernel_options.get('cpu', {})
+ k_memory_opts = kernel_options.get('memory', {})
cmdline_options = []
# XXX: This code path and if statements must be kept in sync with the Kernel