Avoid panic if printer is off or unreachable for some reason.

Closes #16
Closes #17
Closes #15
This commit was merged in pull request #18.
This commit is contained in:
2021-05-23 15:21:31 +00:00
committed by Gitea
parent 72ee8c7d1b
commit 21cf29f651
7 changed files with 35 additions and 19 deletions

View File

@@ -52,6 +52,10 @@ func (r Response) String() string {
return r.header.String() + "\n" + r.a.String()
}
func (r Response) Header() ippResponseHeader {
return r.header
}
// Marshal converts the response object to a wire formatted byte stream.
func (r *Response) Marshal() []byte {
a := make([]byte, 0, 20)