Age | Commit message (Collapse) | Author |
|
Avoid reporting a nonexisting final line by not counting the EOF character
as physical newline.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
ci: switch to official openwrt/gh-action-sdk
|
|
Utilize the official openwrt/gh-action-sdk CI actions to
test-build OpenWrt packages.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
lib: support object ordering in `uc_sort()`
|
|
nl80211: add constants for iftypes
|
|
Useful for adding/removing interfaces
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Extend `uc_sort()` to utilize `ucv_object_sort()` in order to support
reordering object keys.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Introduce a new function `ucv_object_sort()` which works similar to
`ucv_array_sort()` and allows reordering the keys of an object.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
README.md: fix debian dependencies
|
|
Fix Coverity Scan CID 1521107 reporting a memory leak in
uc_compiler_compile_import on early exit due to namelist not correctly
put before return.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
[add empty line before return]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Build fails without pkg-config.
Signed-off-by: Luiz Angelo Daros de Luca <luizluca@gmail.com>
|
|
Ensure to release the `this` context and the temporary argument stash
when we raise a non iterable type exception due to non-iterable values
while precessing spread operations in function call arguments.
Those values would've been garbage collected eventually but explicitly
releasing them here will allow the vm to free them immediately.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
|
|
This avoids unnecessary gc calls when configuring a gc interval while also
explicitly calling ucv_gc from C code embedding a vm at convenient points in
time.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
When converting ucode strings to blobmsg, use blobmsg_add_field in order to
explicltly pass the length of the data.
In the other direction, use ucv_string_new_length based on the attribute
length.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
It is unused and I couldn't find any purpose for it
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Allow -L to add library paths that take precedence over the built-in ones.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
program: fix memory leak in read_sourceinfo
|
|
Fix Coverty Scan CID 1521109 reporting a memory leak for path not freed
on read_size_t fail.
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
|
|
ci: unbreak failing builds by using fixed gh-actions-openwrt-ci-sdk
|
|
* use mediatek/mt7622 SDK to have arm64 build test coverage
* use latest Ubuntu container to stay current
* use v3 of checkout action to stay current
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
|
To save some build resources, lets cancel ongoing builds after
force pushing new sources into the pull request branch.
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
|
imx6-generic was renamed to imx-cortexa9
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
|
SDK containers hosted under `openwrtorg` Docker organization were
deprecated so lets use fixed action which uses new `openwrt` organization.
References: https://lists.openwrt.org/pipermail/openwrt-devel/2023-March/040728.html
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
|
uci: fix ctx.commit() without arguments
|
|
A uci commit operation may invalidate the package pointer, leading to an
infinite loop while iterating the packages to commit.
Refactor the code to first build a string list of configurations, then
iterating it in order to avoid the iterator invalidation.
While we're at it, also allow restricting save and revert operations to
single configs, which was rejected as invalid before.
Fixes: #146
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Recent glibc versions require linking libresolv to obtain ns_initparse().
Fixes: #144
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
rtnl: add missing uc_vm_registry_set call
|
|
Fixes maintaining the listener array
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Fix reference count issues
|
|
Arguments stored in the registry need an extra reference
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Arguments stored in the registry need an extra reference
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
nl80211: fix NL80211_ATTR_SURVEY_INFO
|
|
This is the last attribute, adapt .nattr to include it so it gets
parsed.
Signed-off-by: Andre Heider <a.heider@gmail.com>
|
|
rtnl: add support for registering an uloop based listener
|
|
Similar to nl80211 uloop listener
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
nl80211: add support for registering an uloop based listener
|
|
- Fix `ucv_array_unshift()` improperly rejecting operation on empty arrays
- Fix `uc_unshift()` improperly reversing maintaining argument order
- Add missing test coverage for `push()`, `pop()`, `unshift()` and
`shift()` array operations.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
The `pipe()` function takes no arguments and will return a two element
array containing open read- and write file descriptors for a newly
created pipe.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
Can be used to capture nl80211 messages in an event driven program
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
- add missing overflow check
- make array size dynamic
- set all bits if command id is not specified
- add helper function for filling command bits
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Add an `.editorconfig` file to the source root in order to document the
preferred source code indentation style.
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
|
|
fs: add `isatty()` function
|
|
Expose the `isatty(3)` libc function in the fs module to allow checking
whether a file descriptor refers to a terminal.
Signed-off-by: Petr Štetiar <ynezz@true.cz>
|
|
nl80211: add support for NL80211_ATTR_MPATH_INFO
|
|
Signed-off-by: John Crispin <john@phrozen.org>
|
|
include: add uc_fn_thisval()
|
|
Can be used to get rid of a layer of pointer indirection in resource type
handlers.
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|