func NewReadCloser(r io.Reader, c io.Closer) io.ReadCloser {
	return &readCloser{Reader: r, closer: c}
}
NewReadCloser creates an `io.ReadCloser` with the given `io.Reader` and
`io.Closer`.
package ioutil
import (
	"bufio"
	"context"
	"errors"
	"io"
	"github.com/jbenet/go-context/io"
)
type readPeeker interface {
	io.Reader
	Peek(int) ([]byte, error)
}
var (
	ErrEmptyReader = errors.New("reader is empty")
)
func NonEmptyReader(r io.Reader) (io.Reader, error) {
	pr, ok := r.(readPeeker)
	if !ok {
		pr = bufio.NewReader(r)
	}
	_, err := pr.Peek(1)
	if err == io.EOF {
		return nil, ErrEmptyReader
	}
	if err != nil {
		return nil, err
	}
	return pr, nil
}
type readCloser struct {
	io.Reader
	closer io.Closer
}
func (r *readCloser) Close() error {
	return r.closer.Close()
}