Tk Source Code

Diff
Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Differences From Artifact [10023589]:

To Artifact [9cf86629]:


  1075   1075    */
  1076   1076   
  1077   1077   static int
  1078   1078   GetByte(
  1079   1079       Tcl_Channel chan)	/* The channel we read from. */
  1080   1080   {
  1081   1081       char buffer;
  1082         -    int size;
         1082  +    size_t size;
  1083   1083   
  1084   1084       size = Tcl_Read(chan, &buffer, 1);
  1085         -    if (size <= 0) {
         1085  +    if ((size + 1) < 2) {
  1086   1086   	return EOF;
  1087   1087       } else {
  1088   1088   	return buffer;
  1089   1089       }
  1090   1090   }
  1091   1091   
  1092   1092   /*