Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: Re: jdgordon: r28714 - trunk/apps/gui/skin_engine

Re: jdgordon: r28714 - trunk/apps/gui/skin_engine

From: Magnus Holmgren <magnushol_at_gmail.com>
Date: Tue, 30 Nov 2010 15:07:01 +0100

On Tue, Nov 30, 2010 at 14:12, <mailer_at_svn.rockbox.org> wrote:
> Date: 2010-11-30 14:12:27 +0100 (Tue, 30 Nov 2010)
> New Revision: 28714
>
> Log Message:
> Very small code shuffle to maybe make parseing %if() a smidgen faster

<...>

> -    if (!strcmp(op, "="))
> +    if (!strncmp(op, "=", 1))

If anything, it actually makes it slower. strcmp aborts as soon as
either string ends. strncmp does that too, but it also need to check
the count (in the implementation Rockbox uses, it is checked two times
per char).

:)

-- 
  Magnus
Received on 2010-11-30

Page was last modified "Jan 10 2012" The Rockbox Crew
aaa