Index: tclIO.c
===================================================================
RCS file: /cvsroot/tcl/tcl/generic/tclIO.c,v
retrieving revision 1.56
diff -c -r1.56 tclIO.c
*** tclIO.c	24 May 2002 21:19:05 -0000	1.56
--- tclIO.c	5 Jun 2002 09:57:22 -0000
***************
*** 5453,5459 ****
--- 5453,5467 ----
  		    offset, mode, &result);
  	} else if (offset < Tcl_LongAsWide(LONG_MIN) ||
  		offset > Tcl_LongAsWide(LONG_MAX)) {
+ #ifdef EOVERFLOW
  	    Tcl_SetErrno(EOVERFLOW);
+ #else
+ #   ifdef EFBIG
+ 	    Tcl_SetErrno(EFBIG);
+ #   else
+ 	    Tcl_SetErrno(EINVAL);
+ #   endif
+ #endif
  	    curPos = Tcl_LongAsWide(-1);
  	} else {
  	    curPos = Tcl_LongAsWide((chanPtr->typePtr->seekProc) (

Index: tclIOGT.c
===================================================================
RCS file: /cvsroot/tcl/tcl/generic/tclIOGT.c,v
retrieving revision 1.7
diff -c -r1.7 tclIOGT.c
*** tclIOGT.c	24 May 2002 21:19:06 -0000	1.7
--- tclIOGT.c	5 Jun 2002 09:57:25 -0000
***************
*** 979,985 ****
--- 979,993 ----
       * happens when trying to go out of the representable range.
       */
      if (offset<Tcl_LongAsWide(LONG_MIN) || offset>Tcl_LongAsWide(LONG_MAX)) {
+ #ifdef EOVERFLOW
  	*errorCodePtr = EOVERFLOW;
+ #else
+ #   ifdef EFBIG
+ 	*errorCodePtr = EFBIG;
+ #   else
+ 	*errorCodePtr = EINVAL;
+ #   endif
+ #endif
  	return Tcl_LongAsWide(-1);
      }
      return Tcl_LongAsWide((*parentSeekProc) (parentData,

Index: tclIOUtil.c
===================================================================
RCS file: /cvsroot/tcl/tcl/generic/tclIOUtil.c,v
retrieving revision 1.45
diff -c -r1.45 tclIOUtil.c
*** tclIOUtil.c	28 May 2002 15:05:22 -0000	1.45
--- tclIOUtil.c	5 Jun 2002 10:04:24 -0000
***************
*** 108,121 ****
  		|| OUT_OF_RANGE(buf.st_blocks)
  #endif
  	    ) {
! #ifdef EFBIG
! 	    errno = EFBIG;
! #else
! #  ifdef EOVERFLOW
  	    errno = EOVERFLOW;
! #  else
! #    error  "What status should be returned for file size out of range?"
! #  endif
  #endif
  	    return -1;
  	}
--- 108,122 ----
  		|| OUT_OF_RANGE(buf.st_blocks)
  #endif
  	    ) {
! 
! #ifdef EOVERFLOW
  	    errno = EOVERFLOW;
! #else
! #   ifdef EFBIG
! 	    errno = EFBIG;
! #   else
! 	    errno = EINVAL;
! #   endif
  #endif
  	    return -1;
  	}

Index: tclUnixChan.c
===================================================================
RCS file: /cvsroot/tcl/tcl/unix/tclUnixChan.c,v
retrieving revision 1.35
diff -c -r1.35 tclUnixChan.c
*** tclUnixChan.c	24 May 2002 21:19:08 -0000	1.35
--- tclUnixChan.c	5 Jun 2002 09:57:42 -0000
***************
*** 617,623 ****
--- 617,631 ----
       * Check for expressability in our return type, and roll-back otherwise.
       */
      if (newLoc > Tcl_LongAsWide(INT_MAX)) {
+ #ifdef EOVERFLOW
  	*errorCodePtr = EOVERFLOW;
+ #else
+ #   ifdef EFBIG
+ 	*errorCodePtr = EFBIG;
+ #   else
+ 	*errorCodePtr = EINVAL;
+ #   endif
+ #endif
  	Tcl_PlatformSeek(fsPtr->fd, (Tcl_SeekOffset) oldLoc, SEEK_SET);
  	return -1;
      } else {
