simulavr-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Simulavr-devel] [PATCH 2/3] Fix compiler warning, compiler does not kno


From: Stefan Brüns
Subject: [Simulavr-devel] [PATCH 2/3] Fix compiler warning, compiler does not know about limited range of prescalers
Date: Sun, 19 Jan 2014 18:14:06 +0100
User-agent: KMail/4.11.3 (Linux/3.11.6-4-desktop; KDE/4.11.3; x86_64; ; )

Signed-off-by: Stefan Brüns <address@hidden>
---
 src/hwtimer/hwtimer.cpp | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/hwtimer/hwtimer.cpp b/src/hwtimer/hwtimer.cpp
index 74d3b3c..691f9b1 100644
--- a/src/hwtimer/hwtimer.cpp
+++ b/src/hwtimer/hwtimer.cpp
@@ -1537,6 +1537,9 @@ bool HWTimerTinyX5::PrescalerMux(void) {
 
     case 15: // CKx16384
         return (bool)((prescaler % 16384) == 0);
+
+    default: // not reached
+        return false;
     }
 }
 
@@ -1558,6 +1561,9 @@ bool HWTimerTinyX5::DeadTimePrescalerMux(void) {
 
     case 3: // CKx8
         return (bool)((dtprescaler % 8) == 0);
+
+    default: // not reached
+        return false;
     }
 }
 
-- 
1.8.4




reply via email to

[Prev in Thread] Current Thread [Next in Thread]