mirror of
https://github.com/SagerNet/sing-shadowsocks.git
synced 2025-04-05 04:47:41 +03:00
Fix std read for server conn
This commit is contained in:
parent
ebbaadcae0
commit
91d2780bfc
2 changed files with 8 additions and 0 deletions
|
@ -176,6 +176,10 @@ func (c *serverConn) writeResponse(payload []byte) (n int, err error) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *serverConn) Read(b []byte) (n int, err error) {
|
||||||
|
return c.reader.Read(b)
|
||||||
|
}
|
||||||
|
|
||||||
func (c *serverConn) Write(p []byte) (n int, err error) {
|
func (c *serverConn) Write(p []byte) (n int, err error) {
|
||||||
if c.writer != nil {
|
if c.writer != nil {
|
||||||
return c.writer.Write(p)
|
return c.writer.Write(p)
|
||||||
|
|
|
@ -319,6 +319,10 @@ func (c *serverConn) writeResponse(payload []byte) (n int, err error) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (c *serverConn) Read(b []byte) (n int, err error) {
|
||||||
|
return c.reader.Read(b)
|
||||||
|
}
|
||||||
|
|
||||||
func (c *serverConn) Write(p []byte) (n int, err error) {
|
func (c *serverConn) Write(p []byte) (n int, err error) {
|
||||||
if c.writer != nil {
|
if c.writer != nil {
|
||||||
return c.writer.Write(p)
|
return c.writer.Write(p)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue