func (rc *ReadCloser) init(r *tar.Reader) error {
	defer rc.Close()
	rc.File = make([]*tar.Header, 0, 10)
	for {
		h, err := r.Next()
		if err == io.EOF {
			break
		} else if err != nil {
			return err
		}
		rc.File = append(rc.File, h)
	}
	return nil
}
init initializes a new ReadCloser.
package tz
import (
	"archive/tar"
	"compress/gzip"
	"io"
	"os"
	"strings"
	"github.com/unknwon/cae"
)
type ReadCloser struct {
	f    *os.File
	File []*tar.Header
}
func (rc *ReadCloser) Close() error {
	return rc.f.Close()
}
func openFile(name string) (*tar.Reader, *os.File, error) {
	f, err := os.Open(name)
	if err != nil {
		return nil, nil, err
	}
	gr, err := gzip.NewReader(f)
	if err != nil {
		f.Close()
		return nil, nil, err
	}
	return tar.NewReader(gr), f, nil
}
func openReader(name string) (*ReadCloser, error) {
	tr, f, err := openFile(name)
	if err != nil {
		return nil, err
	}
	r := new(ReadCloser)
	if err := r.init(tr); err != nil {
		return nil, err
	}
	r.f = f
	return r, nil
}