*** tclScan.c.orig	Fri Mar 30 20:29:33 2001
--- tclScan.c	Sat Mar 31 07:27:53 2001
***************
*** 694,705 ****
  	    case 'o':
  		op = 'i';
  		base = 8;
! 		fn = (long (*)())strtol;
  		break;
  	    case 'x':
  		op = 'i';
  		base = 16;
! 		fn = (long (*)())strtol;
  		break;
  	    case 'u':
  		op = 'i';
--- 694,707 ----
  	    case 'o':
  		op = 'i';
  		base = 8;
! 		flags |= SCAN_UNSIGNED;
! 		fn = (long (*)())strtoul;
  		break;
  	    case 'x':
  		op = 'i';
  		base = 16;
! 		flags |= SCAN_UNSIGNED;
! 		fn = (long (*)())strtoul;
  		break;
  	    case 'u':
  		op = 'i';
***************
*** 858,864 ****
  			case '0':
  			    if (base == 0) {
  				base = 8;
! 				flags |= SCAN_XOK;
  			    }
  			    if (flags & SCAN_NOZERO) {
  				flags &= ~(SCAN_SIGNOK | SCAN_NODIGITS
--- 860,867 ----
  			case '0':
  			    if (base == 0) {
  				base = 8;
! 				flags |= SCAN_XOK | SCAN_UNSIGNED;
! 				fn = (long (*)())strtoul;
  			    }
  			    if (flags & SCAN_NOZERO) {
  				flags &= ~(SCAN_SIGNOK | SCAN_NODIGITS
***************
*** 895,900 ****
--- 898,905 ----
  				break;
  			    }
  			    flags &= ~(SCAN_SIGNOK | SCAN_XOK | SCAN_NODIGITS);
+ 			    flags |= SCAN_UNSIGNED;
+ 			    fn = (long (*)())strtoul;
  			    goto addToInt;
  
  			case '+': case '-':
***************
*** 908,913 ****
--- 913,920 ----
  			    if ((flags & SCAN_XOK) && (end == buf+1)) {
  				base = 16;
  				flags &= ~SCAN_XOK;
+ 				flags |= SCAN_UNSIGNED;
+ 				fn = (long (*)())strtoul;
  				goto addToInt;
  			    }
  			    break;
