shithub: riscv

Download patch

ref: 8f1954c0dd4ca231d6904fbbd788dbe40ef284e3
parent: 62a4e64d31cc681e891967656dc8fa22cba1eb87
author: Ori Bernstein <[email protected]>
date: Wed Jul 13 17:01:11 EDT 2022

upas/Mail: check if plumb attrs are nil

--- a/sys/src/cmd/upas/Mail/mbox.c
+++ b/sys/src/cmd/upas/Mail/mbox.c
@@ -802,6 +802,8 @@
 
 	digest = plumblookup(pm->attr, "digest");
 	action = plumblookup(pm->attr, "mailtype");
+	if(digest == nil || action == nil)
+		return;
 	if(strcmp(action, "new") == 0){
 		if((m = load(pm->data, digest, 1)) == nil)
 			return;