From 7fa1fe8590ce2b887a21b7a593eea01e5e466315 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 9 Jul 2013 17:53:04 +1000 Subject: [PATCH] AP_Param: use 0xFFFF not __UINT16_MAX__ MacOS doesn't have __UINT16_MAX__ --- libraries/AP_Param/AP_Param.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/AP_Param/AP_Param.cpp b/libraries/AP_Param/AP_Param.cpp index fdd8fdf97f..145eb6e9f7 100644 --- a/libraries/AP_Param/AP_Param.cpp +++ b/libraries/AP_Param/AP_Param.cpp @@ -444,7 +444,7 @@ uint8_t AP_Param::type_size(enum ap_var_type type) // return true if found, along with the offset in the EEPROM where // the variable is stored // if not found return the offset of the sentinal -// if the sentinal isn't found either, the offset is set to __UINT16_MAX__ +// if the sentinal isn't found either, the offset is set to 0xFFFF bool AP_Param::scan(const AP_Param::Param_header *target, uint16_t *pofs) { struct Param_header phdr; @@ -469,7 +469,7 @@ bool AP_Param::scan(const AP_Param::Param_header *target, uint16_t *pofs) } ofs += type_size((enum ap_var_type)phdr.type) + sizeof(phdr); } - *pofs = __UINT16_MAX__; + *pofs = 0xffff; serialDebug("scan past end of eeprom"); return false; }