Don't call upgrade callbacks for module with no revision defined

This commit is contained in:
Vladimir Ratnikov 2020-07-28 05:52:07 -04:00
parent 9d2102cebf
commit 8b5c77838b
2 changed files with 3 additions and 1 deletions

View file

@ -412,7 +412,8 @@ mod_ns_upgrade(clicon_handle h,
if ((ymod = yang_find_module_by_namespace(yspec, ns)) == NULL)
goto fail;
if ((yrev = yang_find(ymod, Y_REVISION, NULL)) == NULL)
goto fail;
retval = 1;
goto done;
if (ys_parse_date_arg(yang_argument_get(yrev), &to) < 0)
goto done;
}