[syslinux] [PATCH 3/5] COM32: Improve opendir() to deal with no '/' at end of string

Gene Cumm gene.cumm at gmail.com
Mon Mar 9 09:56:14 PDT 2009


On Fri, Mar 6, 2009 at 8:17 PM, H. Peter Anvin <hpa at zytor.com> wrote:
> Gene Cumm wrote:
>> On Fri, Mar 6, 2009 at 1:11 AM, H. Peter Anvin <hpa at zytor.com> wrote:
>>> Gene Cumm wrote:
>>>> Currently, the COMBOOT call required a '/' to recognize that you're
>>>> searching for a directory.  This checks and automatically appends a
>>>> '/' to the end of the pathname string (by creating another string
>>>> temporarily) then making the COMBOOT call.
>>>>
>>> I'm concerned about doing this if we ever intend to make this work
>>> properly over TFTP.
>>>
>>
>> I'm rethinking how I implemented things.
>>
>> Define a new function searchdir4dir and then one of two ideas:
>> 1) rename the existing function searchdir to something like
>> searchdir4file then abstract away for a new function called searchdir
>> 2) create a new function searchdir4all or searchdir4any (or along those lines).
>>
>
> Note how this is already handled in the FAT and ext2 derivatives; they
> have effectively this.
>

At the moment, I'm looking though SYSLINUX and all I'm finding is
searchdir and search_dos_dir.  search_dos_dir searches 1 directory for
a particular name (regardless of file type).  Is this what you meant?

-Gene




More information about the Syslinux mailing list