summaryrefslogtreecommitdiffstats
path: root/generic/tkText.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2003-11-10 21:02:35 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2003-11-10 21:02:35 (GMT)
commit89616a36f9c3d31b0da35547101986b962641ed8 (patch)
treef2d7e13290c29ed8d3059a97cedf97d0be85f00f /generic/tkText.c
parent388100bece4ccadd2e908108a4f1de2733a7ad25 (diff)
downloadtk-89616a36f9c3d31b0da35547101986b962641ed8.zip
tk-89616a36f9c3d31b0da35547101986b962641ed8.tar.gz
tk-89616a36f9c3d31b0da35547101986b962641ed8.tar.bz2
Minor int vs. unsigned fixes to stop GCC warnings
Diffstat (limited to 'generic/tkText.c')
-rw-r--r--generic/tkText.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/generic/tkText.c b/generic/tkText.c
index 5b9c515..ed826db 100644
--- a/generic/tkText.c
+++ b/generic/tkText.c
@@ -14,7 +14,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkText.c,v 1.40 2003/11/07 15:36:26 vincentdarley Exp $
+ * RCS: @(#) $Id: tkText.c,v 1.41 2003/11/10 21:02:35 dkf Exp $
*/
#include "default.h"
@@ -688,8 +688,9 @@ TextWidgetObjCmd(clientData, interp, objc, objv)
for (i = 2; i < objc-2; i++) {
int value;
- int length;
- CONST char *option = Tcl_GetStringFromObj(objv[i],&length);
+ unsigned length;
+ CONST char *option = Tcl_GetStringFromObj(objv[i],
+ (int *)&length);
char c;
if (length < 2 || option[0] != '-') {
badOption:
@@ -1051,7 +1052,7 @@ TextWidgetObjCmd(clientData, interp, objc, objv)
if (objc > 3) {
name = Tcl_GetStringFromObj(objv[i], &length);
if (length > 1 && name[0] == '-') {
- if (strncmp("-displaychars", name, length) == 0) {
+ if (strncmp("-displaychars", name, (unsigned)length)==0) {
i++;
visible = 1;
name = Tcl_GetStringFromObj(objv[i], &length);
@@ -4336,7 +4337,8 @@ SearchCore(interp, searchSpecPtr, patObj)
p = startOfLine + lastOffset -1;
}
while (p >= startOfLine + firstOffset) {
- if (p[0] == c && !strncmp(p, pattern, matchLength)) {
+ if (p[0] == c && !strncmp(p, pattern,
+ (unsigned)matchLength)) {
goto backwardsMatch;
}
p--;