Skip to content
This repository was archived by the owner on Feb 17, 2026. It is now read-only.

Latest commit

 

History

History
34 lines (24 loc) · 553 Bytes

File metadata and controls

34 lines (24 loc) · 553 Bytes

Moved to https://codeberg.org/plusmid/tcpchan

tcpchan

A network communication channel for Google Go

Usage

Server:

ch, err := tcpchan.Listen("<local ip>:8976")
if err != nil {
    ...
}

ch <- "Test"
fmt.Println(<-ch)
close(ch)

Client:

ch, err := tcpchan.Dial("<remote ip>:8976")
if err != nil {
    ...
}

fmt.Println(<-ch)
ch <- "Hello!"

Known issues

When the application is terminated before all data is sent the remaining data is lost.

License

Zlib-License