mirror of
https://git.yoctoproject.org/poky
synced 2026-04-18 12:32:12 +02:00
sstatesig: Improve debug output if getpwuid() fails
If getpwduid fails, we don't see which file it failed on which is key information to aid debugging. Print this information when exceptions are raised. (From OE-Core rev: 2bba0052597020ea887c84419440df11f9859283) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> (cherry picked from commit 9d7a5219713af8117eda145052c6d9abdf577d8f) Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
@@ -521,8 +521,12 @@ def OEOuthashBasic(path, sigfile, task, d):
|
||||
add_perm(stat.S_IXOTH, 'x')
|
||||
|
||||
if include_owners:
|
||||
update_hash(" %10s" % pwd.getpwuid(s.st_uid).pw_name)
|
||||
update_hash(" %10s" % grp.getgrgid(s.st_gid).gr_name)
|
||||
try:
|
||||
update_hash(" %10s" % pwd.getpwuid(s.st_uid).pw_name)
|
||||
update_hash(" %10s" % grp.getgrgid(s.st_gid).gr_name)
|
||||
except KeyError:
|
||||
bb.warn("KeyError in %s" % path)
|
||||
raise
|
||||
|
||||
update_hash(" ")
|
||||
if stat.S_ISBLK(s.st_mode) or stat.S_ISCHR(s.st_mode):
|
||||
|
||||
Reference in New Issue
Block a user