[Asterisk-code-review] loader: Process module dependencies. (asterisk[master])

Kevin Harwell asteriskteam at digium.com
Thu Jan 11 17:25:30 CST 2018


Kevin Harwell has posted comments on this change. ( https://gerrit.asterisk.org/7873 )

Change subject: loader: Process module dependencies.
......................................................................


Patch Set 3: Code-Review-1

(2 comments)

https://gerrit.asterisk.org/#/c/7873/3/main/loader.c
File main/loader.c:

https://gerrit.asterisk.org/#/c/7873/3/main/loader.c@234
PS3, Line 234:  * \param missing Vector to store name of any enhancer that is not running or declined.
I'm not sure if the help text is wrong, the code or I am just all around misreading things :-)

This says it stores names that are not running or declined, but if a module is declined the code continues in the loop and never checks dep was potentially enhanced by the declined module.


https://gerrit.asterisk.org/#/c/7873/3/main/loader.c@1487
PS3, Line 1487: 		if (module_deps_reference(mod, NULL)) {
              : 			ast_log(LOG_WARNING, "Module '%s' could not be loaded due to missing dependencies.\n", resource_name);
              : 			unload_dynamic_module(mod);
              : 
              : 			return required ? AST_MODULE_LOAD_FAILURE : AST_MODULE_LOAD_DECLINE;
              : 		}
Not sure if this would be the best place to do it, but do you think it would be worthwhile to print out the missing dependencies here if this function was called due to a user trying to load an individual module from the cli?



-- 
To view, visit https://gerrit.asterisk.org/7873
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I9be08d1dd331aceadc1dcba00b804d71360b2fbb
Gerrit-Change-Number: 7873
Gerrit-PatchSet: 3
Gerrit-Owner: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
Gerrit-Comment-Date: Thu, 11 Jan 2018 23:25:30 +0000
Gerrit-HasComments: Yes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180111/703f50c1/attachment.html>


More information about the asterisk-code-review mailing list