hw/cxl: Fix memory leak in error paths