Repository navigation
Commit 72c3915
committed
context: fix creation failure with disable_searchdirs
Since libyang commit be5a07fea89d ("context UPDATE remove binary
internal modules"), ly_ctx_new() reads its internal modules from the
search dirs. When LY_CTX_DISABLE_SEARCHDIRS is set, it cannot find
them and the context is not created.
Set the option after the context is created. The internal modules are
already loaded at this point, and later module lookups still skip the
search dirs. With older libyang, the result is the same.
The next commit fixes the same libyang change when the search path
does not contain the libyang module dir.
Closes: #172
Closes: #173
Suggested-by: Pepa Hajek <hajekpepa@gmail.com>
Signed-off-by: Samuel Gauthier <samuel.gauthier@6wind.com>1 parent 73ce8cd commit 72c3915
2 files changed
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
219 | | - | |
220 | | - | |
221 | 219 | | |
222 | 220 | | |
223 | 221 | | |
| |||
274 | 272 | | |
275 | 273 | | |
276 | 274 | | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
277 | 280 | | |
278 | 281 | | |
279 | 282 | | |
| |||
0 commit comments