mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-01-02 23:47:07 -05:00
check empty
This commit is contained in:
parent
47f1399995
commit
3b0bfe9422
@ -205,6 +205,9 @@ func (w *ReceivingWorker) ReadMultiBuffer() buf.MultiBuffer {
|
||||
|
||||
func (w *ReceivingWorker) Read(b []byte) int {
|
||||
mb := w.ReadMultiBuffer()
|
||||
if mb.IsEmpty() {
|
||||
return 0
|
||||
}
|
||||
nBytes, err := mb.Read(b)
|
||||
common.Must(err)
|
||||
if !mb.IsEmpty() {
|
||||
|
Loading…
Reference in New Issue
Block a user