[PATCH v5 3/3] test_firmware: fix the memory leak of the allocated firmware buffer