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: settings.c confuses me
From: Björn Stenberg (bjorn_at_haxx.se)
Date: 2003-03-24


TP Diffenbach wrote:
> Why not just read the settings on disk into global settings:
> read( fd, &global_settings, sizeof( global_settings)?, with some additional
> code for the RTC?

The config block is packed into 512 bytes, while the global_settings struct is unpacked and thus bigger. The memory we waste using a bigger struct is saved by enabling simpler code to access the data. (Booleans as ints instead of bits, for example.)

-- 
Björn



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