Fix issue with dangling pointer in the rbd engine
[fio.git] / engines / rbd.c
index ff35373795af68eaf357043851c6fe2c1c550fab..dc6e7db674ba38c6252a61fde337f061938f0555 100644 (file)
@@ -131,8 +131,10 @@ static int _fio_rbd_connect(struct thread_data *td)
 
 failed_open:
        rados_ioctx_destroy(rbd_data->io_ctx);
+       rbd_data->io_ctx = NULL;
 failed_shutdown:
        rados_shutdown(rbd_data->cluster);
+       rbd_data->cluster = NULL;
 failed_early:
        return 1;
 }