Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix dhchap & tls key mem leaks #884

Merged
merged 3 commits into from
Sep 16, 2024
Merged

Commits on Sep 13, 2024

  1. tree: fix dhchap_key mem leak

    Valgrind revealed a mem leak when specifying the dhchap host key
    through the config JSON file. This was because additional memory
    was allocated while assigning the dhchap host key through strdup
    calls via both nvme_ctrl_set_dhchap_host_key() and
    nvme_get_ctrl_attr(), but only one of them was freed. Fix the same.
    
    Signed-off-by: Martin George <marting@netapp.com>
    martin-gpy committed Sep 13, 2024
    Configuration menu
    Copy the full SHA
    2d784d4 View commit details
    Browse the repository at this point in the history
  2. tree: fix dhchap_ctrl_key mem leak

    Valgrind revealed mem leaks when specifying the dhchap ctrl key
    through both the config JSON file and the CLI. This was because
    additional memory was allocated while assigning the dhchap ctrl
    key through strdup calls via both nvme_ctrl_set_dhchap_key() and
    nvme_get_ctrl_attr(), but only one of them was freed. Fix the same.
    
    Signed-off-by: Martin George <marting@netapp.com>
    martin-gpy committed Sep 13, 2024
    Configuration menu
    Copy the full SHA
    bdb9a83 View commit details
    Browse the repository at this point in the history

Commits on Sep 15, 2024

  1. tree: fix tls key mem leak

    Valgrind revealed a mem leak when specifying the tls key through
    both the config JSON file and the CLI. This was because memory
    allocated through strdup via the nvme_get_ctrl_attr() while
    fetching the tls key was not getting freed. Fix it.
    
    Signed-off-by: Martin George <marting@netapp.com>
    martin-gpy committed Sep 15, 2024
    Configuration menu
    Copy the full SHA
    4d7eacb View commit details
    Browse the repository at this point in the history