apparmor: fix error code to failure message mapping for name lookup
-ESTALE used to be incorrectly used to indicate a disconnected path, when name lookup failed. This was fixed in commit e1b0e444 to correctly return -EACCESS, but the error to failure message mapping was not correctly updated to reflect this change. Signed-off-by: John Johansen <john.johansen@canonical.com> Acked-by: Steve Beattie <sbeattie@ubuntu.com>
This commit is contained in:
parent
50c5ecd5d8
commit
e573cc30bb
1 changed files with 1 additions and 1 deletions
|
@ -174,7 +174,7 @@ static int get_name_to_buffer(struct path *path, int flags, char *buffer,
|
||||||
if (info && error) {
|
if (info && error) {
|
||||||
if (error == -ENOENT)
|
if (error == -ENOENT)
|
||||||
*info = "Failed name lookup - deleted entry";
|
*info = "Failed name lookup - deleted entry";
|
||||||
else if (error == -ESTALE)
|
else if (error == -EACCES)
|
||||||
*info = "Failed name lookup - disconnected path";
|
*info = "Failed name lookup - disconnected path";
|
||||||
else if (error == -ENAMETOOLONG)
|
else if (error == -ENAMETOOLONG)
|
||||||
*info = "Failed name lookup - name too long";
|
*info = "Failed name lookup - name too long";
|
||||||
|
|
Loading…
Reference in a new issue