From 1c8cc2e1d1328656ef1af94f78c9d8ae9e961691 Mon Sep 17 00:00:00 2001 From: Fred Gleason Date: Tue, 1 Jun 2021 12:55:06 -0400 Subject: [PATCH] 2021-06-01 Fred Gleason * Cleaned up compile warnings in 'lib/rdttydevice.cpp'. Signed-off-by: Fred Gleason --- ChangeLog | 2 ++ lib/rdttydevice.cpp | 12 ++++++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index cd3f26db..3d3df82c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -21788,3 +21788,5 @@ * Cleaned up compile warnings in 'lib/rdsvc.cpp'. 2021-06-01 Fred Gleason * Cleaned up compile warnings in 'lib/rdtextfile.cpp'. +2021-06-01 Fred Gleason + * Cleaned up compile warnings in 'lib/rdttydevice.cpp'. diff --git a/lib/rdttydevice.cpp b/lib/rdttydevice.cpp index 5c18cc4e..5c3da00b 100644 --- a/lib/rdttydevice.cpp +++ b/lib/rdttydevice.cpp @@ -2,8 +2,7 @@ // // A Qt driver for tty ports. // -// (C) Copyright 2010-1018 Fred Gleason -// All Rights Reserved. +// (C) Copyright 2010-1021 Fred Gleason // // This program is free software; you can redistribute it and/or modify // it under the terms of the GNU Library General Public License @@ -26,6 +25,7 @@ #include #include +#include "rdapplication.h" #include "rdttydevice.h" RDTTYDevice::RDTTYDevice(QObject *parent) @@ -593,7 +593,8 @@ void RDTTYDevice::writeTtyData() { char data[2048]; int bytes=0; - + int s; + ioctl(tty_fd,TIOCOUTQ,&bytes); int n=2048-bytes; if((int)tty_write_queue.size() + syslog(LOG_WARNING,"RDTTYDevice::writeTtyData write lost %c bytes",n-s); + } }