R: [AD] Allegro 5 new config routines, alpha 2 |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
> > /* Avoid collisions (if any) */
> > while ((strcmp(entry->name, name)) && (entry->next))
> > entry = entry->next;
> > if (strcmp(entry->name, name))
> > return NULL;
>
> Just quickly, there seems to be lots of these. strcmp'ing
> might be unnecessarily called twice.
>
> while (entry && strcmp(entry->name, name))
> entry = entry->next;
> if (!entry)
> return NULL;
>
> .. or something like that might be better.
Point taken; I'll update the code. The more optimized these routines
will be, the better...
--
Angelo Mottola
a.mottola@xxxxxxxxxx
http://www.ecplusplus.com