util-linux: Fix build with glibc 2.29

(From OE-Core rev: f2646ea56e5ce82561089956c4a1f0d3c81087b1)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Khem Raj
2019-01-04 22:47:10 -08:00
committed by Richard Purdie
parent 3bbd3b0a7e
commit 96dee0ab5c
2 changed files with 17 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
Checking for exitence of the define is not enough since
it will be defined with 0 or 1 value
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
--- a/sys-utils/ldattach.c
+++ b/sys-utils/ldattach.c
@@ -242,7 +242,7 @@ static int my_cfsetspeed(struct termios
* -- we have to bypass glibc and set the speed manually (because glibc
* checks for speed and supports Bxxx bit rates only)...
*/
-#ifdef _HAVE_STRUCT_TERMIOS_C_ISPEED
+#if _HAVE_STRUCT_TERMIOS_C_ISPEED
# define BOTHER 0010000 /* non standard rate */
dbg("using non-standard speeds");
ts->c_ospeed = ts->c_ispeed = speed;