This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Redboot size_t signedness issue


Gary Thomas wrote:

> A better solution would be to remove any signed/unsigned ambiguity.
> This test can be written equivalently as:
>  if (((CYGNUM_REDBOOT_FIS_DIRECTORY_ENTRY_COUNT * CYGNUM_REDBOOT_FIS_DIRECTORY_ENTRY_SIZE) + cfg_size) > fisdir_size) {
> 
> If you can try this to see if it works on your setup, I'll commit
> a proper change/patch.

Yup, this is even better.

I no more have the configuration values that caused this to
happen (was in the middle of experimenting) so I can't test
it right now, but it looks correct.

Thanks
-- 
                                   Stano

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]