Skip to content

Commit

Permalink
plugins BUGFIX static run-time plugin support
Browse files Browse the repository at this point in the history
  • Loading branch information
michalvasko committed Apr 2, 2024
1 parent 4363428 commit 7efb69e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/plugins.c
Original file line number Diff line number Diff line change
Expand Up @@ -618,9 +618,9 @@ lyplg_add_plugin(struct ly_ctx *ctx, uint32_t version, enum LYPLG type, const vo

LY_CHECK_ARG_RET(NULL, recs, LY_EINVAL);

if (version != plugins_load_info[type].apiver) {
LOGERR(ctx, LY_EINVAL, "Adding user %s plugin failed, wrong API version - %d expected, %d found.",
plugins_load_info[type].id, plugins_load_info[type].apiver, version);
if (version != LYPLG_TYPE_API_VERSION) {
LOGERR(ctx, LY_EINVAL, "Adding user %s plugin failed, wrong API version - %d expected, %" PRIu32 " found.",
(type == LYPLG_TYPE) ? "type" : "extension", LYPLG_TYPE_API_VERSION, version);
return LY_EINVAL;
}

Expand Down

0 comments on commit 7efb69e

Please sign in to comment.