tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]


NAME_MAX = 255

dirent uses MAXPATHLEN, namei uses NAME_MAX and does not allow it to exceed
that, so none of the dirent entries actually use > 255. We want to make them

I tried to do this by versioning both kernel and userland. The
kernel portion is fine, but the userland portion is really messy.
To do the userland portion right, we need to version again, all
the *dir*() functions including the internal ones like _scandir().

My opinion is that it is not worth the trouble. The only programs that can
fail are ones that do things like:
     char name[NAME_MAX];
     strcpy(name, d->d_name);

sizeof(d->d_name) does not change. It is just that d_namelen can be
> 255 (NAME_MAX). Only programs that use NAME_MAX to store directory
entries can fail.
My vote is to bump without versioning, what's yours?


Home | Main Index | Thread Index | Old Index