On 8/20/23 08:04, Richard Henderson wrote:
On 8/19/23 02:48, Karim Taha wrote:
+#define SHM_PATH(p) ((p) == SHM_ANON ? (p) : path(p))
+ if (arg1 == (uintptr_t)SHM_ANON) {
+ p = SHM_ANON;
+ } else {
+ p = lock_user_string(arg1);
+ if (p == NULL) {
+ return -TARGET_EFAULT;
+ }
+ }
+ ret = get_errno(shm_open(SHM_PATH(p),
Again, SHM_PATH is not needed, because the condition is handled by this IF.
Oh, no, that's something different.
But path() is wrong for shm_open, because it's not a path in the regular file
system.
r~