// decompress fills the dictionary unless no space for new data is
// available. If the end of the LZMA stream has been reached io.EOF will
// be returned.
decompress fills the dictionary unless no space for new data is
available. If the end of the LZMA stream has been reached io.EOF will
be returned.
// decompress fills the dictionary unless no space for new data is // available . If the end of the LZMA stream has been reached io . EOF will // be returned .
func (d *decoder) decompress() error {
	if d.eos {
		return io.EOF
	}
	for d.Dict.Available() >= maxMatchLen {
		op, err := d.readOp()
		switch err {
		case nil:
			break
		case errEOS:
			d.eos = true
			if !d.rd.possiblyAtEnd() {
				return errDataAfterEOS
			}
			if d.size >= 0 && d.size != d.Decompressed() {
				return errSize
			}
			return io.EOF
		case io.EOF:
			d.eos = true
			return io.ErrUnexpectedEOF
		default:
			return err
		}
		if err = d.apply(op); err != nil {
			return err
		}
		if d.size >= 0 && d.Decompressed() >= d.size {
			d.eos = true
			if d.Decompressed() > d.size {
				return errSize
			}
			if !d.rd.possiblyAtEnd() {
				switch _, err = d.readOp(); err {
				case nil:
					return errSize
				case io.EOF:
					return io.ErrUnexpectedEOF
				case errEOS:
					break
				default:
					return err
				}
			}
			return io.EOF
		}
	}
	return nil
}
func ( d * decoder ) decompress ( ) error { if d . eos { return io . EOF } for d . Dict . Available ( ) >= maxMatchLen { op , err := d . readOp ( ) switch err { case nil : break case errEOS : d . eos = true if ! d . rd . possiblyAtEnd ( ) { return errDataAfterEOS } if d . size >= 0 && d . size != d . Decompressed ( ) { return errSize } return io . EOF case io . EOF : d . eos = true return io . ErrUnexpectedEOF default : return err } if err = d . apply ( op ) ; err != nil { return err } if d . size >= 0 && d . Decompressed ( ) >= d . size { d . eos = true if d . Decompressed ( ) > d . size { return errSize } if ! d . rd . possiblyAtEnd ( ) { switch _ , err = d . readOp ( ) ; err { case nil : return errSize case io . EOF : return io . ErrUnexpectedEOF case errEOS : break default : return err } } return io . EOF } } return nil }
decompress fills the dictionary unless no space for new data is
available.
decompress fills the dictionary unless no space for new data is available .