Le 23/09/2016 à 10:43, Aleksandar Markovic a écrit :
>     > - changed PATH_MAX to 128 in sysfs() patch (last remaining item
>     > that was supposed to be in the previous version)/
> 
>     At first glance of the patch, you didn't change the good PATH_MAX...
> 
>     Laurent/
> 
> It slipped through the cracks. Sorry. :( My bad. But all other changes
> are in. Rebase is also good, this series sits *after* 26-patch
> linux-user change. Speaking about PATH_MAX, I intended to replace it
> with hardcoded 128. However, another possibility is replacing it with
> NAME_MAX (255). Or to leave PATH_MAX (4096)? Or something else
> altogether? What do you think? Thanks, Aleksandar

I've looked at the kernel code and there is no defined value for this
length (this is a pointer to a string), but it seems the length of the
longest string is 14 [1]. So 4096 seems really overkill.

Laurent

[1] grep -rh -A3 "struct file_system_type " . |grep "\.name" |sed -n
's/[^"]*"\([^"]*\)".*/\1/p'|while read name; do echo $name|wc -c;
done|sort -n|tail -1

Reply via email to