summaryrefslogtreecommitdiff
path: root/sys/src/libaml
diff options
context:
space:
mode:
authorSigrid <ftrvxmtrx@gmail.com>2020-08-20 08:28:24 +0200
committerSigrid <ftrvxmtrx@gmail.com>2020-08-20 08:28:24 +0200
commitb6fde0c7b9fd2f02372e6276f0321cd195fabbdb (patch)
treec181ad14c63cfedc90488053c11e89fa4592098f /sys/src/libaml
parentde34481f8b80306b58687c1a3039feb785c4f98f (diff)
libaml: fix fault when the second operand of comparison cannot be converted
Diffstat (limited to 'sys/src/libaml')
-rw-r--r--sys/src/libaml/aml.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/libaml/aml.c b/sys/src/libaml/aml.c
index 9f030462f..8549740e3 100644
--- a/sys/src/libaml/aml.c
+++ b/sys/src/libaml/aml.c
@@ -1524,7 +1524,7 @@ cmp1(void *a, void *b)
tag = TAG(a);
if(b == nil || TAG(b) != tag)
b = copy(tag, b);
- if(TAG(b) != tag)
+ if(b == nil || TAG(b) != tag)
return -1; /* botch */
switch(tag){
default: