cleanup allocated memory on error

31 jobs for 703-resource-leak-in-dlz_filesystem_driver-c in 12 minutes and 56 seconds (queued for 5 seconds)