From 6443c492857e37fd2e7e77544803f11da03917a1 Mon Sep 17 00:00:00 2001 From: Bertrand Songis Date: Sat, 12 Mar 2016 20:52:03 +0100 Subject: [PATCH] Try to have everything compiling in the same time! --- radio/src/sdcard.cpp | 5 ++++- radio/src/storage/rlc.cpp | 6 +++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/radio/src/sdcard.cpp b/radio/src/sdcard.cpp index e8517766a..f2b64043d 100644 --- a/radio/src/sdcard.cpp +++ b/radio/src/sdcard.cpp @@ -19,9 +19,12 @@ */ #include -#include "diskio.h" #include "opentx.h" +#if !defined(SIMU) +#include "diskio.h" +#endif + const char * sdCheckAndCreateDirectory(const char * path) { DIR archiveFolder; diff --git a/radio/src/storage/rlc.cpp b/radio/src/storage/rlc.cpp index 7ff3c3374..ba2b87a11 100644 --- a/radio/src/storage/rlc.cpp +++ b/radio/src/storage/rlc.cpp @@ -23,7 +23,7 @@ #include "debug.h" #define CHECK_DST_SIZE() \ - if (cur-dst >= dstsize) { \ + if (cur-dst >= (int)dstsize) { \ TRACE("RLC encoding size too big"); \ return 0; \ } @@ -75,7 +75,7 @@ unsigned int compress(uint8_t * dst, unsigned int dstsize, const uint8_t * src, #undef CHECK_DST_SIZE #define CHECK_DST_SIZE() \ - if (cur-dst >= dstsize) { \ + if (cur-dst >= (int)dstsize) { \ TRACE("RLC decoding size too big"); \ return 0; \ } @@ -126,4 +126,4 @@ unsigned int uncompress(uint8_t * dst, unsigned int dstsize, const uint8_t * src } } -#undef CHECK_DST_SIZE \ No newline at end of file +#undef CHECK_DST_SIZE