comdb2 icon indicating copy to clipboard operation
comdb2 copied to clipboard

A comparison is always evaluated to be true

Open Ljiee opened this issue 6 years ago • 1 comments

At line 919-920 of /bdb/temptable.c,

if (cur->tbl->temp_table_type != TEMP_TABLE_TYPE_BTREE ||
        cur->tbl->temp_table_type != TEMP_TABLE_TYPE_ARRAY) {
        logmsg(LOGMSG_ERROR, "bdb_temp_table_update operation "
                             "only supported for btree or array.\n");
        return -1;
    }

this comparison is always evaluated to be true. I think the "||" should be replaced with "&&".

Ljiee avatar May 08 '20 01:05 Ljiee

Thank you for submitting the issue.

riverszhang89 avatar Jun 12 '20 17:06 riverszhang89