From 15baee5af91546c04a79e0a0b4e19d204fdc5da3 Mon Sep 17 00:00:00 2001 From: Ralf Corsepius Date: Sun, 8 Nov 2009 08:15:59 +0000 Subject: [PATCH] =?UTF-8?q?2009-11-08=09Ralf=20Cors=C3=A9pius=20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libmisc/capture/capture.h (RTEMS_CAPTURE_CONTROL_FROM_MASK): Use UINT32_C(1) to avoid overflow in implict typecast on 16bit targets. --- cpukit/ChangeLog | 6 ++++++ cpukit/libmisc/capture/capture.h | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog index 691aa40069..58064a8220 100644 --- a/cpukit/ChangeLog +++ b/cpukit/ChangeLog @@ -1,3 +1,9 @@ +2009-11-08 Ralf Corsépius + + * libmisc/capture/capture.h (RTEMS_CAPTURE_CONTROL_FROM_MASK): + Use UINT32_C(1) to avoid overflow in implict typecast on 16bit + targets. + 2009-11-03 Ralf Corsépius * itron/src/chg_pri.c, itron/src/cre_tsk.c, diff --git a/cpukit/libmisc/capture/capture.h b/cpukit/libmisc/capture/capture.h index acc5fcd912..b96582f6bf 100644 --- a/cpukit/libmisc/capture/capture.h +++ b/cpukit/libmisc/capture/capture.h @@ -88,7 +88,7 @@ typedef struct rtems_capture_control_s * The from_valid mask. */ #define RTEMS_CAPTURE_CONTROL_FROM_MASK(_s) \ - (1 << (RTEMS_CAPTURE_TRIGGER_TASKS - ((_s) + 1))) + (UINT32_C(1) << (RTEMS_CAPTURE_TRIGGER_TASKS - ((_s) + 1))) /** * Control flags.