summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko2014-01-08 15:25:20 +0100
committerDenys Vlasenko2014-01-08 15:25:20 +0100
commit96f92a1afac1599cc5f6128e7e9a43bdab220bc8 (patch)
treeed5f9d72b52b77ec8e6757e208eee2bef09e330b
parent8e0ad2647a9725f189ad880b437619667e81343c (diff)
downloadbusybox-96f92a1afac1599cc5f6128e7e9a43bdab220bc8.zip
busybox-96f92a1afac1599cc5f6128e7e9a43bdab220bc8.tar.gz
libbb: FreeBSD fix for B<num> baud rate constants not fitting into a short.
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--libbb/speed_table.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libbb/speed_table.c b/libbb/speed_table.c
index 45159f1..174d531 100644
--- a/libbb/speed_table.c
+++ b/libbb/speed_table.c
@@ -10,7 +10,12 @@
#include "libbb.h"
struct speed_map {
+#if defined __FreeBSD__
+ /* On FreeBSD, B<num> constants don't fit into a short */
+ unsigned speed;
+#else
unsigned short speed;
+#endif
unsigned short value;
};