Skip to contentSkip to conversation

Re: [[email protected]: Undelivered Mail Returned to Sender]

[email protected]: Undelivered Mail Returned to Sender Serge E. Hallyn 1 participant 1 message Nov 10, 2011 2 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 20111109190829.GA26067@sergelap

A message that is not in the archive (sent off-list or not yet received): CAKiorj6LYYC+rZG5CRKahYuzyXdnGpQJgd4QQUQ9YhHpTV7s=w@mail.gmail.com

#2 lore raw

...

Quoted 21 lines
Quoted 21 lines

 Would you prefer something like:

(quoted diff) +18 -0
+#ifdef CONFIG_USER_NS
+static inline void fixup_uid(struct siginfo *info, struct task_struct *t)
+{
+       if (current_user_ns() == task_cred_xxx(t, user_ns))
+               return;
+
+       if (SI_FROMKERNEL(info))
+               return;
+
+       info->si_uid = user_ns_map_uid(task_cred_xxx(t, user_ns),
+                                       current_cred(), info->si_uid);
+}
+#else
+static inline void fixup_uid(struct siginfo *info, struct task_struct *t)
+{
+               return;
+}
+#endif
Quoted 3 lines
Quoted 1 line

?  It's less sneaky at least.

Very much. The current version looks like a bug.

Thanks, I'll switch to that and hopefully resend the set soon.

-serge