diff options
author | jan.nijtmans <jan.nijtmans@noemail.net> | 2011-08-18 06:47:51 (GMT) |
---|---|---|
committer | jan.nijtmans <jan.nijtmans@noemail.net> | 2011-08-18 06:47:51 (GMT) |
commit | 58425cc29e7dd28493aad277a0f13d01f9e900e7 (patch) | |
tree | 55eff3f3a1abf7dec86fd3947941fec40f83e1f1 | |
parent | 637991f011ba2ffb2cb1b6cb5a0008a6f73c0557 (diff) | |
download | tcl-58425cc29e7dd28493aad277a0f13d01f9e900e7.zip tcl-58425cc29e7dd28493aad277a0f13d01f9e900e7.tar.gz tcl-58425cc29e7dd28493aad277a0f13d01f9e900e7.tar.bz2 |
A few more compiler warnings
FossilOrigin-Name: b7e85cb558a69bf822ca51e7e74432c1c5567f5d
-rw-r--r-- | generic/tclIOCmd.c | 2 | ||||
-rw-r--r-- | unix/tclUnixFCmd.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/generic/tclIOCmd.c b/generic/tclIOCmd.c index 44c2738..7d54156 100644 --- a/generic/tclIOCmd.c +++ b/generic/tclIOCmd.c @@ -779,7 +779,7 @@ Tcl_ExecObjCmd(dummy, interp, objc, objv) argv = argStorage; argc = objc - skip; - if ((argc + 1) > sizeof(argv) / sizeof(argv[0])) { + if ((argc + 1) > (int)(sizeof(argv) / sizeof(argv[0]))) { argv = (CONST char **) ckalloc((unsigned)(argc + 1) * sizeof(char *)); } diff --git a/unix/tclUnixFCmd.c b/unix/tclUnixFCmd.c index 1fbe384..50e1921 100644 --- a/unix/tclUnixFCmd.c +++ b/unix/tclUnixFCmd.c @@ -536,10 +536,10 @@ CopyFile(src, dst, statBufPtr) buffer = ckalloc(blockSize); while (1) { nread = read(srcFd, buffer, blockSize); - if ((nread == -1) || (nread == 0)) { + if ((nread == (size_t) -1) || (nread == 0)) { break; } - if (write(dstFd, buffer, nread) != nread) { + if (write(dstFd, buffer, nread) != (int)nread) { nread = (size_t) -1; break; } @@ -547,7 +547,7 @@ CopyFile(src, dst, statBufPtr) ckfree(buffer); close(srcFd); - if ((close(dstFd) != 0) || (nread == -1)) { + if ((close(dstFd) != 0) || (nread == (size_t) -1)) { unlink(dst); /* INTL: Native. */ return TCL_ERROR; } |