diff --git a/cores/arduino/SafeRingBuffer.h b/cores/arduino/SafeRingBuffer.h index 7526ae54a..235406fac 100644 --- a/cores/arduino/SafeRingBuffer.h +++ b/cores/arduino/SafeRingBuffer.h @@ -41,6 +41,12 @@ int SafeRingBufferN::read_char() { synchronized { return RingBufferN::read_char(); } + + // We should never reached this line because the synchronized {} block gets + // executed at least once. However the compiler gets confused and prints a + // warning about control reaching the end of a non-void function. This + // silences that warning. + return -1; } template @@ -53,4 +59,4 @@ void SafeRingBufferN::store_char(uint8_t c) { } #endif /* _SAFE_RING_BUFFER_ */ -#endif /* __cplusplus */ \ No newline at end of file +#endif /* __cplusplus */ pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy