On Friday 25 February 2005 19:04, Vincent Pelletier wrote:
> > grub_strword ("filesystem", "file") returns 0 in your
> > implementation.
>
> Isn't it what should happen ?
s/returns 0/returns 1/;
Okuji
___
Grub-devel mailing list
Grub-devel@gnu.org
htt
Yoshinori K. Okuji wrote:
On Friday 25 February 2005 17:02, Hollis Blanchard wrote:
int
grub_strword (const char *haystack, const char *needle)
{
int pos = 0;
int found = 0;
while (haystack[pos]) {
/* Advance to next word. */
while (grub_iswordseparator (haystack[pos]))
On Friday 25 February 2005 17:02, Hollis Blanchard wrote:
> int
> grub_strword (const char *haystack, const char *needle)
> {
> int pos = 0;
> int found = 0;
>
> while (haystack[pos]) {
> /* Advance to next word. */
> while (grub_iswordseparator (haystack[pos]))
>
On Feb 25, 2005, at 10:13 AM, Aki Tossavainen wrote:
Um, well, it does a lot of unnecessary expensive strcmp's there...
But if you add this, you can at least reduce them abit, since you are
only
interested on the words.
Oops, yes, thanks. :)
-Hollis
___
On Fri, 25 Feb 2005, Hollis Blanchard wrote:
> On Feb 25, 2005, at 5:52 AM, Vincent Pelletier wrote:
> >
> > grub_strword (string, word) : searches for word (a serie of
> > non-word-separators eventualy ended by word-separators) in string (a
> > succession of 0 or more words which can begin by wo
On Feb 25, 2005, at 5:52 AM, Vincent Pelletier wrote:
grub_strword (string, word) : searches for word (a serie of
non-word-separators eventualy ended by word-separators) in string (a
succession of 0 or more words which can begin by word-separator(s))
grub_strword looks a little overcomplicated; wou
dprintf patch, take 2.
grub_strword (string, word) : searches for word (a serie of
non-word-separators eventualy ended by word-separators) in string (a
succession of 0 or more words which can begin by word-separator(s))
grub_iswordseparator : matches any separator
Note : var="value1 value2" current