Common library for all Osmocom projects (libosmocore, libosmogsm, libosmovty, libosmogb, libosmosim, libosmousb, ...) https://osmocom.org/projects/libosmocore
Go to file
Harald Welte aeecc48c45 Introduce osmo_strlcpy() function so we can stop using strncpy()
I'm aware of the existing criticism on stlrcpy(), but I think it is
still better than what we have now: stnrcpy(), sometimes with Coverity
warnings and sometimes with a manual setting of the termination byte.

The implementation follows the linux kernel strlcpy() which is claimed
to be BSD compatible.

We could of course link against libbsd on Linux instead, but I think
it's reasonably small and simple to provide our own implementation.
Future versions of libosmocore could use some autoconf magic and
preprocessor macros to use the system-provided strlcpy() if it exists.

Change-Id: Ifdc99b0e3b8631f1e771e58acaf9efb00a9cd493
2016-11-26 16:42:17 +00:00
contrib configure: add --enable-sanitize, use in jenkins.sh 2016-10-12 22:50:24 +00:00
debian debian: Fix packaging by requiring python-minimal 2016-05-10 11:43:25 +00:00
doc merge_doc.xsl: Don't copy the 'descripiton' element of commands 2016-03-11 22:05:25 +07:00
include Introduce osmo_strlcpy() function so we can stop using strncpy() 2016-11-26 16:42:17 +00:00
m4 Create a dummy m4 directory to make autoreconf --install --force work 2010-03-24 02:55:33 +01:00
src Introduce osmo_strlcpy() function so we can stop using strncpy() 2016-11-26 16:42:17 +00:00
tests build: make check: disable sim_test when built with --disable-pcsc 2016-11-16 16:40:44 +00:00
utils osmo-sim-test.c: Fix rmsg check 2016-11-26 14:03:04 +01:00
.gitignore utils/conv_gen.py: generate a single file 2016-10-23 07:38:15 +00:00
.gitreview add .gitreview 2016-05-19 06:39:13 +00:00
.mailmap Add .mailmap file for mapping mail addresses in shortlog 2016-08-08 13:12:17 +02:00
COPYING add GPL to project source 2010-02-21 09:21:30 +01:00
Doxyfile.codec.in Doxygen: enable tagfile generation and usage for cross-project references 2016-04-24 19:48:05 +02:00
Doxyfile.core.in Doxygen: enable tagfile generation and usage for cross-project references 2016-04-24 19:48:05 +02:00
Doxyfile.gsm.in Doxygen: enable tagfile generation and usage for cross-project references 2016-04-24 19:48:05 +02:00
Doxyfile.vty.in Doxygen: enable tagfile generation and usage for cross-project references 2016-04-24 19:48:05 +02:00
Makefile.am doxygen: Remove the tag file on uninstall as well 2016-04-24 20:57:30 +02:00
TODO-RELEASE Revert "Constify ctrl_cmd struct fields where appropriate" 2016-10-20 17:53:10 +02:00
configure.ac build: make check: disable sim_test when built with --disable-pcsc 2016-11-16 16:40:44 +00:00
git-version-gen add git-version-gen magic to automatically generate package version 2010-03-23 00:30:19 +08:00
libosmocodec.pc.in codec: Add the missing bits for include to install and pkgconfig to work 2010-10-24 18:23:10 +02:00
libosmocore.pc.in talloc: Untested change to unbreak build 2015-12-10 19:50:29 +01:00
libosmoctrl.pc.in remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00
libosmogb.pc.in remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00
libosmogsm.pc.in remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00
libosmosim.pc.in remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00
libosmovty.pc.in remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00