diff options
Diffstat (limited to 'proxy/copier.go')
-rw-r--r-- | proxy/copier.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/proxy/copier.go b/proxy/copier.go new file mode 100644 index 0000000..e10cba6 --- /dev/null +++ b/proxy/copier.go | |||
@@ -0,0 +1,8 @@ | |||
1 | package proxy | ||
2 | |||
3 | import "io" | ||
4 | |||
5 | func CopyWithErrors(dst io.Writer, src io.Reader, errc chan<- error) { | ||
6 | _, err := io.Copy(dst, src) | ||
7 | errc <- err | ||
8 | } | ||