-
Notifications
You must be signed in to change notification settings - Fork 319
Open
Description
/**
- @brief Call plugins_types sort callback or sort values by plugin order.
- @param[in] ctx libyang context.
- @param[in] val1 First value to compare.
- @param[in] val2 Second value to compare.
- @return Negative number if val1 < val2,
- @return Zero if val1 == val2,
- @return Positive number if val1 > val2.
*/
static int
in (const struct ly_ctx *ctx, const struct lyd_value *val1, const struct lyd_value *val2)
{
assert(val1->realtype == val2->realtype);
return val1->realtype->plugin->sort(ctx, val1, val2);
}
we met null-poniter failure when using the interface lyds_merge, we find the val1 could be null-pointer. How should we perform a NULL check on the input parameter.
Best wishes,
ciao
Metadata
Metadata
Assignees
Labels
No labels