[openbeosstorage] Re: ddm questions
- From: Tyler Dauwalder <tyler@xxxxxxxxxxxxx>
- To: openbeosstorage@xxxxxxxxxxxxx
- Date: Sat, 25 Oct 2003 01:25:01 -0700
> > > Yep, the non-const was chosen intentionally. I had the feeling, that
> > > e.g.
> > > truncating a name wouldn't be too unusual.
> >
> > So do you not want me to return B_NAME_TOO_LONG if the name is larger than
> > B_OS_NAME_LENGTH and instead let the validate function handle things?
>
> That's what I was trying to say. :-) The string is passed to the disk
> system,
> which will truncate the name, if necessary, and the syscall just needs to
> copy it back into userland space.
Are you okay with truncating it when copying from userland at the start of
the respective _kern_XYZ() function (but not returning an error if truncation
occurs)? This is what I've done for the moment, as it seems more efficient
than arbitrarily allocating and copying the entire string and then forcing
the validate function to truncate it.
-Tyler
- Follow-Ups:
- [openbeosstorage] Re: ddm questions
- From: Ingo Weinhold
- References:
- [openbeosstorage] Re: ddm questions
- From: Ingo Weinhold
Other related posts:
- » [openbeosstorage] ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- » [openbeosstorage] Re: ddm questions
- [openbeosstorage] Re: ddm questions
- From: Ingo Weinhold
- [openbeosstorage] Re: ddm questions
- From: Ingo Weinhold