lkml.org 
[lkml]   [2013]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC] teach argv_split() to ignore the spaces surrounded by \e
On 05/13, Colin Walters wrote:
>
> On Mon, 2013-05-13 at 16:35 +0200, Oleg Nesterov wrote:
>
> > Yes, we can change format_corename() to construct "argv" by hand, and
> > this was my iniital plan. But perhaps it would be better to not uglify
> > this code even more?
>
> Sure this \e is less code, but it seems pretty ugly to me.

Yes, I am not proud of this idea. But it is simple.

> Maybe a way
> to keep fs/coredump.c sane would be always constructing an argv, and
> then in the !ispipe case just join them into one string.

I don't think we should construct an argv if !ispipe, but this is minor.
The patch should be simple anyway. Just I do not want to touch this code ;)
and to complicate it more. and create another (2nd) case when when we need
to construct argv by hand.

> Though I'm still inclined to change systemd to read /proc/pid/cmdline
> like abrt does; that way it works on current kernels too.

Oh, I will be really happy to leave this this code alone and do nothing ;)

except format_corename() has another bug, it can leak ->corename but this
is another story (I'll send the patch).

Oleg.



\
 
 \ /
  Last update: 2013-05-13 19:41    [W:0.106 / U:0.348 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site