Skip to content

Commit

Permalink
android: suppress filenotfound error when looking for partitions
Browse files Browse the repository at this point in the history
  • Loading branch information
peace-maker committed Dec 12, 2023
1 parent 8ec0925 commit 95fd121
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pwnlib/adb/adb.py
Original file line number Diff line number Diff line change
Expand Up @@ -1491,7 +1491,8 @@ class Partitions(object):
@context.quietfunc
def by_name_dir(self):
try:
return next(find('/dev/block/platform','by-name'))
with context.local(log_level=logging.FATAL):
return next(find('/dev/block/platform','by-name'))
except (StopIteration, PwnlibException):
return '/dev/block'

Expand Down

0 comments on commit 95fd121

Please sign in to comment.