mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-06 22:08:54 +00:00
scripts: check if dl directory exist in dl_cleanup script
Check if the provided dl directory exist and return on error. Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com> Signed-off-by: maurerr <mariusd84@gmail.com>
This commit is contained in:
parent
1225aacb94
commit
619578062f
@ -169,6 +169,11 @@ def main(argv):
|
||||
usage()
|
||||
return 1
|
||||
directory = args[0]
|
||||
|
||||
if not os.path.exists(directory):
|
||||
print("Can't find dl path", directory)
|
||||
return 1
|
||||
|
||||
for (o, v) in opts:
|
||||
if o in ("-h", "--help"):
|
||||
usage()
|
||||
|
Loading…
Reference in New Issue
Block a user