commit | 9df820bf9b7d54b58b2462b1ee67c2e13eb749eb | [log] [tgz] |
---|---|---|
author | Vadim Yanitskiy <vyanitskiy@sysmocom.de> | Mon Dec 11 13:34:02 2023 +0700 |
committer | fixeria <vyanitskiy@sysmocom.de> | Sat Dec 30 16:14:38 2023 +0000 |
tree | d9f8218060073973db2ae84e9deb18cb5a52af25 | |
parent | b8f3bba72174e057bf7504db6f6e0999b35633d7 [diff] |
utils: fix OSMO_STRBUF_REMAIN to handle sb.pos == NULL correctly Currently, OSMO_STRBUF_REMAIN would return a huge number if the given strbuf has its .pos pointer set to NULL. This macro is safe against the .buf pointer being NULL, but not against .pos being NULL. Fix this by adding a static inline function (for the sake of code readability) and handle .pos being NULL properly by returning length of the buffer. Add a unit test. Change-Id: I294a74a99c40995cf7fb5520d61f697d967be5a4
This repository contains a set of C-language libraries that form the core infrastructure of many Osmocom Open Source Mobile Communications projects.
Historically, a lot of this code was developed as part of the OpenBSC project, but which are of a more generic nature and thus useful to (at least) other programs that we develop in the sphere of Free Software / Open Source mobile communications.
There is no clear scope of it. We simply move all shared code between the various Osmocom projects in this library to avoid code duplication.
The libosmocore.git repository build multiple libraries:
The official homepage of the project is https://osmocom.org/projects/libosmocore/wiki/Libosmocore
You can clone from the official libosmocore.git repository using
git clone https://gitea.osmocom.org/osmocom/libosmocore
There is a web interface at https://gitea.osmocom.org/osmocom/libosmocore
Doxygen-generated API documentation is generated during the build process, but also available online for each of the sub-libraries at https://ftp.osmocom.org/api/latest/libosmocore/
Discussions related to libosmocore are happening on the openbsc@lists.osmocom.org mailing list, please see https://lists.osmocom.org/mailman/listinfo/openbsc for subscription options and the list archive.
Please observe the Osmocom Mailing List Rules when posting.
Our coding standards are described at https://osmocom.org/projects/cellular-infrastructure/wiki/Coding_standards
We us a gerrit based patch submission/review process for managing contributions. Please see https://osmocom.org/projects/cellular-infrastructure/wiki/Gerrit for more details
The current patch queue for libosmocore can be seen at https://gerrit.osmocom.org/#/q/project:libosmocore+status:open