Message ID | 4ad488d2453525b7196e6d2406ac526412e3c560.1679605352.git.steve@sakoman.com |
---|---|
State | Accepted, archived |
Commit | 4ad488d2453525b7196e6d2406ac526412e3c560 |
Headers | show |
Series | [kirkstone,01/14] curl: Add fix for CVE-2023-23914, CVE-2023-23915 | expand |
diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py index 967d157077..6c4a62b558 100644 --- a/scripts/lib/devtool/upgrade.py +++ b/scripts/lib/devtool/upgrade.py @@ -125,11 +125,8 @@ def _write_append(rc, srctreebase, srctree, same_dir, no_same_dir, rev, copied, return af def _cleanup_on_error(rd, srctree): - rdp = os.path.split(rd)[0] # recipes folder if os.path.exists(rd): shutil.rmtree(rd) - if not len(os.listdir(rdp)): - os.rmdir(rdp) srctree = os.path.abspath(srctree) if os.path.exists(srctree): shutil.rmtree(srctree)