7;s some sort of ordering enforced.
>
> In general, you'll need some way of signalling "I'm done copying stuff
> from zipReader to zipWriter" in the goroutine, and you'll need to
> arrange for some other, longer lived, goroutine to wait for that signal.
>
>
struct{}
> func (m mockB) functionB(...)
>
> On 10.09.20 09:15, Yvonne Zhang wrote:
> > Hi,
> > I have a function streaming a zipreader to browser. It is like this.
> > func functionA()(body io.ReadCloser, err error){
> >
> >// some logic to get
Hi,
I have a function streaming a zipreader to browser. It is like this.
func functionA()(body io.ReadCloser, err error){
// some logic to get a zipreader
body, pipeWriter := io.Pipe()
zipWriter := zip.NewWriter(pipeWriter)
go func(){
// err := functionB(zipReader, zipWrite