summaryrefslogtreecommitdiffstats
path: root/win/tclWinSerial.c
diff options
context:
space:
mode:
Diffstat (limited to 'win/tclWinSerial.c')
-rw-r--r--win/tclWinSerial.c18
1 files changed, 8 insertions, 10 deletions
diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c
index ecefc2e..c3144e3 100644
--- a/win/tclWinSerial.c
+++ b/win/tclWinSerial.c
@@ -11,13 +11,11 @@
*
* Serial functionality implemented by Rolf.Schroedter@dlr.de
*
- * RCS: @(#) $Id: tclWinSerial.c,v 1.40 2010/01/10 22:58:40 nijtmans Exp $
+ * RCS: @(#) $Id: tclWinSerial.c,v 1.41 2010/01/13 06:46:56 nijtmans Exp $
*/
#include "tclWinInt.h"
-#include <fcntl.h>
-#include <io.h>
#include <sys/stat.h>
/*
@@ -1744,16 +1742,16 @@ SerialSetOptionProc(
dcb.XonLim = (WORD) (infoPtr->sysBufRead*1/2);
dcb.XoffLim = (WORD) (infoPtr->sysBufRead*1/4);
- if (strnicmp(value, "NONE", vlen) == 0) {
+ if (strncasecmp(value, "NONE", vlen) == 0) {
/*
* Leave all handshake options disabled.
*/
- } else if (strnicmp(value, "XONXOFF", vlen) == 0) {
+ } else if (strncasecmp(value, "XONXOFF", vlen) == 0) {
dcb.fOutX = dcb.fInX = TRUE;
- } else if (strnicmp(value, "RTSCTS", vlen) == 0) {
+ } else if (strncasecmp(value, "RTSCTS", vlen) == 0) {
dcb.fOutxCtsFlow = TRUE;
dcb.fRtsControl = RTS_CONTROL_HANDSHAKE;
- } else if (strnicmp(value, "DTRDSR", vlen) == 0) {
+ } else if (strncasecmp(value, "DTRDSR", vlen) == 0) {
dcb.fOutxDsrFlow = TRUE;
dcb.fDtrControl = DTR_CONTROL_HANDSHAKE;
} else {
@@ -1863,7 +1861,7 @@ SerialSetOptionProc(
result = TCL_ERROR;
break;
}
- if (strnicmp(argv[i], "DTR", strlen(argv[i])) == 0) {
+ if (strncasecmp(argv[i], "DTR", strlen(argv[i])) == 0) {
if (!EscapeCommFunction(infoPtr->handle,
(DWORD) (flag ? SETDTR : CLRDTR))) {
if (interp != NULL) {
@@ -1872,7 +1870,7 @@ SerialSetOptionProc(
result = TCL_ERROR;
break;
}
- } else if (strnicmp(argv[i], "RTS", strlen(argv[i])) == 0) {
+ } else if (strncasecmp(argv[i], "RTS", strlen(argv[i])) == 0) {
if (!EscapeCommFunction(infoPtr->handle,
(DWORD) (flag ? SETRTS : CLRRTS))) {
if (interp != NULL) {
@@ -1881,7 +1879,7 @@ SerialSetOptionProc(
result = TCL_ERROR;
break;
}
- } else if (strnicmp(argv[i], "BREAK", strlen(argv[i])) == 0) {
+ } else if (strncasecmp(argv[i], "BREAK", strlen(argv[i])) == 0) {
if (!EscapeCommFunction(infoPtr->handle,
(DWORD) (flag ? SETBREAK : CLRBREAK))) {
if (interp != NULL) {