Skip to content
Tcl Source Code History Of Ticket 218047ffffffffff
Login

History Of Ticket 218047ffffffffff

Artifacts Associated With Ticket 218047ffffffffff

  1. Ticket change [52b1b4e2cd] (rid 126360) by nobody on 2000-10-26 00:52:33:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      OriginalBugID: 1398 Bug
      Version: 8.0.4
      SubmitDate: '1999-03-02'
      LastModified: '2000-04-24'
      Severity: SER
      Status: Closed
      Submitter: pat
      ChangedBy: hobbs
      OS: Windows NT
      OSVersion: 4.0, service pack 3
      Machine: X86
      FixedDate: '2000-10-25'
      ClosedDate: '2000-04-24'
      
      
      Name:
      Fred Roeber
      
      Extensions:
      DP
      
      CustomShell:
      patch from Bug ID 893
      
      ReproducibleScript:
      The code we are using to receive data over a TCP socket follows.
      
      # set up a socket to handle upload requests (will call tscan_socket)
      if {[catch {socket -server tscan_socket $tscan_port} tscan_server_id]} {
          # command failed so signal receive disabled
          tscan_display "Error - couldn't connect socket: $tscan_server_id"
      }
      
      proc tscan_socket {chan_id ip_addr port} {
          global tscan_file_id
      
          if {[catch {open "dummy" "w"} tscan_file_id]} {
              # problem opening file
              tscan_display "Error - couldn't open file: $tscan_file_id"
              close $chan_id
              return
          }
          fconfigure $tscan_file_id -translation binary -blocking no
      
          # set up to receive the upload data
          fconfigure $chan_id -translation binary -blocking no
          fileevent $chan_id readable "tscan_socket_read $chan_id $tscan_file_id"
      }
      
      proc tscan_socket_read {chan_id file_id} {
          if {[catch {read $chan_id} data]} {
              tscan_display "problem reading TimeScan data from socket"
          } elseif {[eof $chan_id]} {
              tscan_display "Done"
          } elseif {[catch {puts -nonewline $file_id $data} file_err]} {
              tscan_display "Error writing TimeScan data to file: $file_err"
          } else {
              # everything worked so we are done. Do a display update so that program
              # isn't unresponsive
              update
              return
          }
      
          # we had some problem so shut down channel
          catch {close $chan_id}
          catch {close $file_id}
      }
      
      
      
      
      ObservedBehavior:
      This code above works fine under Solaris. Under windows, we receive an
      extra '0' byte (not '\0') from the socket connection that gets written to the
      output file. If the system sending the data just opens a closes a TCP
      connection, we get a 0 byte file on Solaris but a 1 byte file under
      Windows/NT 4.0.
      
      
      
      
      
      
      DesiredBehavior:
      I expect Solaris and windows to produce the same resultswith the code above.
      
      
      
      
      
      As a note of reference, I found the patch for bug ID 893 on your site. I
      installed it as it was required to have it installed to get asynchronous
      sockets to be properly opened under Windows.
      
      --
      I'm not able to reproduce this with 8.2.3 on NTsp4. 
      -- 04/19/2000 hobbs
      Response from user:
      
      Hello, I had found out the source of this problem after submitting the
      report. The issue was that the sending application was sending up an
      OOB (out of band) message with a '0' in it before closing the socket.
      The intent was the "wake up" the host so it could close the socket
      quickly. Windows doesn't support OOB messages on sockets so added the
      '0' to the output stream. I just chalked this up as one of those Unix
      vs Windows TCP/IP stack differences. Thanks for the response.  Fred
      
         |      Fred J Roeber,  BBN Systems & Technologies      |
       
      -- 04/24/2000 hobbs
      
    4. foundin initialized to: "obsolete: 8.0.4"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "nobody"
    9. subsystem initialized to: "63. (unused)"
    10. title initialized to:
      Reading data from socket on Windows appends extra '0' value
      
    11. type initialized to: "Bug"
  2. Ticket change [f5dcdac884] (rid 130190) by welch on 2000-10-26 08:13:44:

    1. closedate changed to: "2000-10-26T01:13:44"
    2. closer changed to: "welch"
    3. priority changed to: "2"
    4. resolution changed to: "Fixed"
    5. status changed to: "Closed"
  3. Ticket change [300ca1f639] (rid 93179) by dgp on 2001-04-01 01:48:02:

    1. subsystem changed to: "27. Channel Types"
  4. Ticket change [f28d1150db] (rid 109566) by dgp on 2001-04-01 01:48:03:

    1. closedate changed to: "2001-03-31T18:48:03"
    2. closer changed to: "dgp"