tree: do not try to strdup NULL pointer#1046
Conversation
blktests nvme/003 using the loop transport fails because nvme_ctrl_alloc tries to strdup NULL pointers (address or sysfs_dir). Introduce a 'safe' strdup version and start this version. Reported-by: Tomáš Bžatek <[email protected]> Reported-by: Yi Zhang <[email protected]> Fixes: e642498 ("tree: free ctrl attributes when (re)configure ctrl") Signed-off-by: Daniel Wagner <[email protected]>
|
I am running blktests tr=loop with this version. Looks good so far. @MaisenbacherD do you think it would be simple to get a nightly build with blktests setup? I think you are finished with the heavy lifting for the in tree tests. Now it would be awesome to have blktests also run with the latest nvme-cli. |
|
Thanks! |
Yes, this should be fairly easy to set up now. |
|
We have blktests running in nvme-cli: linux-nvme/nvme-cli#2915 |
blktests nvme/003 using the loop transport fails because nvme_ctrl_alloc tries to strdup NULL pointers (address or sysfs_dir).
Introduce a 'safe' strdup version and start this version.
Reported-by: Tomáš Bžatek [email protected]
Reported-by: Yi Zhang [email protected]
Fixes: e642498 ("tree: free ctrl attributes when (re)configure ctrl")
Fixes: #1045 #linux-nvme/nvme-cli#2885