mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-08-29 07:09:49 +08:00
2009-10-22 Ralf Corsépius <ralf.corsepius@rtems.org>
* libblock/include/rtems/flashdisk.h: Use UINT32_C consts to avoid implicit int-cast overflows in RTEMS_FDISK_KBYTES.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2009-10-22 Ralf Corsépius <ralf.corsepius@rtems.org>
|
||||
|
||||
* libblock/include/rtems/flashdisk.h: Use UINT32_C consts to
|
||||
avoid implicit int-cast overflows in RTEMS_FDISK_KBYTES.
|
||||
|
||||
2009-10-22 Ralf Corsépius <ralf.corsepius@rtems.org>
|
||||
|
||||
* libcsupport/include/rtems/error.h: Use ordinal constants for
|
||||
|
||||
@@ -95,7 +95,7 @@ typedef struct rtems_fdisk_segment_desc
|
||||
/**
|
||||
* Return the number of kilo-bytes.
|
||||
*/
|
||||
#define RTEMS_FDISK_KBYTES(_k) ((_k) * 1024)
|
||||
#define RTEMS_FDISK_KBYTES(_k) (UINT32_C(1024) * (_k))
|
||||
|
||||
/**
|
||||
* Forward declaration of the device descriptor.
|
||||
|
||||
Reference in New Issue
Block a user