diff options
author | Kevin Kuehler <keur@xcf.berkeley.edu> | 2019-11-01 19:36:01 -0700 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2019-11-10 10:11:34 -0500 |
commit | ad68a9e4e471eb708893ad16601ab14a4672a2da (patch) | |
tree | a575ea3d868cc5182f7a7243a62bdd2b197b721c | |
parent | 331b915139e23073aa42bf28d67901383dd859ca (diff) | |
download | aerc-ad68a9e4e471eb708893ad16601ab14a4672a2da.tar.gz |
widgets/msgviewer: Don't crash if pager is nil
Signed-off-by: Kevin Kuehler <keur@xcf.berkeley.edu>
-rw-r--r-- | widgets/msgviewer.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/widgets/msgviewer.go b/widgets/msgviewer.go index 05da2a08..7cd55535 100644 --- a/widgets/msgviewer.go +++ b/widgets/msgviewer.go @@ -506,7 +506,7 @@ func (pv *PartViewer) SetSource(reader io.Reader) { } func (pv *PartViewer) attemptCopy() { - if pv.source != nil && pv.pager.Process != nil { + if pv.source != nil && pv.pager != nil && pv.pager.Process != nil { header := message.Header{} header.SetText("Content-Transfer-Encoding", pv.part.Encoding) header.SetContentType(pv.part.MIMEType, pv.part.Params) |