From b940cb0c6bc38dd3f7a0bdeb7ca92810beaa2c71 Mon Sep 17 00:00:00 2001 From: markj Date: Tue, 31 Mar 2015 02:49:05 +0000 Subject: [PATCH] Fix a misparenthesization that could cause a crash if TERM is not set. Reported by: Coverity (internal) MFC after: 3 days Sponsored by: EMC / Isilon Storage Division --- cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c index da804eef87b5..04c022b7ad00 100644 --- a/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c +++ b/cddl/contrib/opensolaris/lib/libdtrace/common/dt_consume.c @@ -727,8 +727,8 @@ dt_print_packed(dtrace_hdl_t *dtp, FILE *fp, utf8 = B_TRUE; } else if ((term = getenv("TERM")) != NULL && (strcmp(term, "sun") == 0 || - strcmp(term, "sun-color") == 0) || - strcmp(term, "dumb") == 0) { + strcmp(term, "sun-color") == 0 || + strcmp(term, "dumb") == 0)) { utf8 = B_FALSE; } else { utf8 = B_TRUE;