update: better debug logging for __lm_ctx_resolve
This commit is contained in:
parent
6d4a8c9f9e
commit
1160b4b6a9
@ -22,7 +22,7 @@
|
|||||||
|
|
||||||
// clang-format on
|
// clang-format on
|
||||||
|
|
||||||
#define LM_VERSION "24.08"
|
#define LM_VERSION "24.09"
|
||||||
|
|
||||||
#include "ctx.h"
|
#include "ctx.h"
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
@ -8,7 +8,7 @@ msgid ""
|
|||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: PACKAGE VERSION\n"
|
"Project-Id-Version: PACKAGE VERSION\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2024-08-22 02:54+0300\n"
|
"POT-Creation-Date: 2024-08-22 08:38+0300\n"
|
||||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
@ -20,18 +20,23 @@ bool __lm_ctx_resolve_contains(lm_pkg_t *pkg, lm_ctx_resolve_list_t *list){
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool __lm_ctx_resolve(lm_ctx_t *ctx, lm_ctx_resolve_list_t *list, lm_pkg_t *pkg, bool resolve_depends){
|
bool __lm_ctx_resolve(lm_ctx_t *ctx, lm_ctx_resolve_list_t *list, lm_pkg_t *pkg, bool resolve_depends){
|
||||||
if(__lm_ctx_resolve_contains(pkg, list))
|
if(__lm_ctx_resolve_contains(pkg, list)){
|
||||||
|
pdebug(__func__, "%s is already in the list, skipping", pkg->data.name);
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
if(NULL == list->packages)
|
if(NULL == list->packages)
|
||||||
list->packages = malloc(sizeof(lm_pkg_t *)*(++list->count));
|
list->packages = malloc(sizeof(lm_pkg_t *)*(++list->count));
|
||||||
else
|
else
|
||||||
list->packages = realloc(list->packages, sizeof(lm_pkg_t *)*(++list->count));
|
list->packages = realloc(list->packages, sizeof(lm_pkg_t *)*(++list->count));
|
||||||
|
|
||||||
|
pdebug(__func__, "adding %s to the list", pkg->data.name);
|
||||||
list->packages[list->count-1] = pkg;
|
list->packages[list->count-1] = pkg;
|
||||||
|
|
||||||
if(!resolve_depends || NULL == pkg->data.depends)
|
if(!resolve_depends || NULL == pkg->data.depends){
|
||||||
|
pdebug(__func__, "skipping depend resolve for %s", pkg->data.name);
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
lm_pkg_t *depend = NULL;
|
lm_pkg_t *depend = NULL;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user