UPSTREAM: selinux: improve error checking in sel_write_load()
Move our existing input sanity checking to the top of sel_write_load() and add a check to ensure the buffer size is non-zero. Move a local variable initialization from the declaration to before it is used. Minor style adjustments. Reported-by:Sam Sun <samsun1006219@gmail.com> Signed-off-by:
Paul Moore <paul@paul-moore.com> Bug: 400329784 Bug: 386755977 Change-Id: I76ec20258a8ef8a2966e98d523b58a0aa8b49bda (cherry picked from commit 42c77323) Signed-off-by:
yaozhongmin <yaozhongmin@xiaomi.com> (cherry picked from commit 37c8296c)
Please register or sign in to comment