summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tclCmdMZ.c16
-rw-r--r--generic/tclUtil.c4
2 files changed, 10 insertions, 10 deletions
diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c
index 5a3833b..dddad59 100644
--- a/generic/tclCmdMZ.c
+++ b/generic/tclCmdMZ.c
@@ -13,7 +13,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclCmdMZ.c,v 1.6 1999/05/06 18:46:42 stanton Exp $
+ * RCS: @(#) $Id: tclCmdMZ.c,v 1.7 1999/05/06 19:21:11 stanton Exp $
*/
#include "tclInt.h"
@@ -848,10 +848,10 @@ Tcl_StringObjCmd(dummy, interp, objc, objv)
for (i = 2; i < objc-2; i++) {
string2 = Tcl_GetStringFromObj(objv[i], &length2);
if ((length2 > 1)
- && strncmp(string2, "-nocase", length2) == 0) {
+ && strncmp(string2, "-nocase", (size_t) length2) == 0) {
nocase = 1;
} else if ((length2 > 1)
- && strncmp(string2, "-length", length2) == 0) {
+ && strncmp(string2, "-length", (size_t) length2) == 0) {
if (i+1 >= objc-2) {
goto str_cmp_args;
}
@@ -1024,10 +1024,10 @@ Tcl_StringObjCmd(dummy, interp, objc, objv)
for (i = 3; i < objc-1; i++) {
string2 = Tcl_GetStringFromObj(objv[i], &length2);
if ((length2 > 1) &&
- strncmp(string2, "-strict", length2) == 0) {
+ strncmp(string2, "-strict", (size_t) length2) == 0) {
strict = 1;
} else if ((length2 > 1) &&
- strncmp(string2, "-failindex", length2) == 0) {
+ strncmp(string2, "-failindex", (size_t) length2) == 0) {
if (i+1 >= objc-1) {
Tcl_WrongNumArgs(interp, 3, objv,
"?-strict? ?-failindex var? str");
@@ -1321,7 +1321,7 @@ Tcl_StringObjCmd(dummy, interp, objc, objv)
if (objc == 5) {
string2 = Tcl_GetStringFromObj(objv[2], &length2);
if ((length2 > 1) &&
- strncmp(string2, "-nocase", length2) == 0) {
+ strncmp(string2, "-nocase", (size_t) length2) == 0) {
nocase = 1;
} else {
Tcl_AppendStringsToObj(resultPtr, "bad option \"",
@@ -1564,8 +1564,8 @@ Tcl_StringObjCmd(dummy, interp, objc, objv)
start = Tcl_UtfAtIndex(string1, first);
end = Tcl_UtfAtIndex(start, last - first + 1);
length2 = end-start;
- string2 = ckalloc(length2+1);
- memcpy(string2, start, length2);
+ string2 = ckalloc((size_t) length2+1);
+ memcpy(string2, start, (size_t) length2);
string2[length2] = '\0';
if ((enum options) index == STR_TOLOWER) {
length2 = Tcl_UtfToLower(string2);
diff --git a/generic/tclUtil.c b/generic/tclUtil.c
index 16ec609..fa4c22f 100644
--- a/generic/tclUtil.c
+++ b/generic/tclUtil.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclUtil.c,v 1.10 1999/05/06 18:46:42 stanton Exp $
+ * RCS: @(#) $Id: tclUtil.c,v 1.11 1999/05/06 19:21:11 stanton Exp $
*/
#include "tclInt.h"
@@ -2063,7 +2063,7 @@ TclGetIntForIndex(interp, objPtr, endValue, indexPtr)
bytes = Tcl_GetStringFromObj(objPtr, &length);
if ((*bytes != 'e') ||
- (strncmp(bytes, "end", (length > 3) ? 3 : length) != 0)) {
+ (strncmp(bytes, "end", (size_t)((length > 3) ? 3 : length)) != 0)) {
if (Tcl_GetIntFromObj(NULL, objPtr, &offset) != TCL_OK) {
goto intforindex_error;
}