Version 0 of Peer to peer

Updated 2005-07-25 01:23:04

Zarutian 2005-07-27-01:15 Here is a super simple peer-to-peer system:

  set listening_port 8050
  rename send old_send
  proc log {message {level 1}} {
    # levels
    #   1 mind numbing detail
    #   2 less numbing
    #   3 noteworthy for causual debuging
    puts "[clock seconds]:[set level]: $message"
  }
  proc send {chan data} {
    log 
    catch {
      puts $chan $data
      flush $chan
    }
  }
  proc accept {chan ipnr portnr} {

...work in progress