gvisor/pkg/sentry
Wei Zhang 17ff6063a3 Bugfix: fix fstatat symbol link to dir
For a symbol link to some directory, eg.

`/tmp/symlink -> /tmp/dir`

`fstatat("/tmp/symlink")` should return symbol link data, but
`fstatat("/tmp/symlink/")` (symlink with trailing slash) should return
directory data it points following linux behaviour.

Currently fstatat() a symlink with trailing slash will get "not a
directory" error which is wrong.

Signed-off-by: Wei Zhang <zhangwei198900@gmail.com>
Change-Id: I63469b1fb89d083d1c1255d32d52864606fbd7e2
PiperOrigin-RevId: 244783916
2019-04-22 20:07:06 -07:00
..
arch Internal change 2019-04-10 18:00:18 -07:00
context Decouple filemem from platform and move it to pgalloc.MemoryFile. 2019-03-14 08:12:48 -07:00
control Clean up state error handling 2019-04-22 18:20:51 -07:00
device Save/restore simple devices. 2019-04-01 15:39:16 -07:00
fs Fix doc typo 2019-04-22 18:22:19 -07:00
hostcpu Remove license comments 2019-01-31 11:12:53 -08:00
inet Remove license comments 2019-01-31 11:12:53 -08:00
kernel Clean up state error handling 2019-04-22 18:20:51 -07:00
limits Allow threads with CAP_SYS_RESOURCE to raise hard rlimits. 2019-04-10 12:36:45 -07:00
loader Use open fids when fstat()ing gofer files. 2019-04-11 00:43:04 -07:00
memmap Call memmap.Mappable.Translate with more conservative usermem.AccessType. 2019-03-25 12:42:43 -07:00
memutil Decouple filemem from platform and move it to pgalloc.MemoryFile. 2019-03-14 08:12:48 -07:00
mm Internal change 2019-04-10 18:00:18 -07:00
pgalloc Decouple filemem from platform and move it to pgalloc.MemoryFile. 2019-03-14 08:12:48 -07:00
platform Allow BP and OF can be called from user space 2019-03-21 22:04:50 -07:00
safemem Priority-inheritance futex implementation 2019-03-05 23:40:18 -08:00
sighandling Remove license comments 2019-01-31 11:12:53 -08:00
socket Add support for the MSG_TRUNC msghdr flag. 2019-04-19 16:17:01 -07:00
state Treat ENOSPC as a state-file error during save. 2019-03-29 12:26:25 -07:00
strace Format struct pollfd in poll(2)/ppoll(2) 2019-04-18 15:24:07 -07:00
syscalls Bugfix: fix fstatat symbol link to dir 2019-04-22 20:07:06 -07:00
time Move package sync to third_party 2019-01-31 17:49:14 -08:00
unimpl Remove license comments 2019-01-31 11:12:53 -08:00
uniqueid Remove license comments 2019-01-31 11:12:53 -08:00
usage Decouple filemem from platform and move it to pgalloc.MemoryFile. 2019-03-14 08:12:48 -07:00
usermem Convert []byte to string without copying in usermem.CopyStringIn. 2019-03-27 10:46:28 -07:00
watchdog Remove license comments 2019-01-31 11:12:53 -08:00
BUILD Remove license comments 2019-01-31 11:12:53 -08:00