Age | Commit message (Collapse) | Author | Files | Lines |
|
Change-Id: Ibd81efc1dc61b8c2019d55a8fa6e3bb99b5acb20
|
|
Functions introduced in 9ec26583cd807e0aeaa3b9de927f3d8a768c3a71 are
using the bool type without referencing stdbool.h as include file.
Change-Id: I736cb04629d516c10c7d5f42f792ed3d5ae6658f
|
|
In a659590e29412588bca2243b8329e82286244b00 we fixed endianness issues
with the Stream ID field, but at the same time mistook the PPID field
for 16bits. In reality it is 32bits, and hence our 'htons' is rendering
wrong PPID values.
Change-Id: I1b60523044835ee630dba9a43d26af4f1ebd1ced
|
|
Using this function, the user can configure if sockets related to the
respective stream client or server should have the NODELAY socket
option set in order to avoid Nagle algorithm or related algorithms
that may introduce packet delay on the transmitter side.
Change-Id: Ibeb9ba227bab18f7f4f16518c0022c4f003cc8e9
|
|
In their infinite wisdom, the inventors of SCTP designed an API (the
sockets API described in RFC6458), where some members are in host byte
order (like the stream identifier), while other members are in network
byte order (like the PPID).
Let's handle this properly (we assumed both are network byte order), and
also use 16-bit htons/ntohs fo the PPID, rather than htonl/ntohl.
Change-Id: I777174ca2915c6de0063db41a745c71b4a09bbec
|
|
* when using osmo_*_destroy(), always call *_close() internally to
make sure we don't free memory holding references to sockets that are
still open
* when closing the socket, always make sure to set the fd to -1 in all
cases, to avoid attempts to avoid later close() on a new file using
the same fd number as the socket closed previously.
Change-Id: I29c37da6e8f5be8ab030e68952a8f92add146821
|
|
during osmo_*_set_addr(), we must make sure to talloc_free() any old
address before copying in the new address. Not all functions did this,
and those that did implemented it manually. Let's use
osmo_talloc_replace_string() which is exactly intended for this case.
Change-Id: Ie1b140a160c66e8b62c745174865d5ba525cb2c2
|
|
This uses the new osmo_sock_init2() features introduced in libosmocore
Change-Id Idab124bcca47872f55311a82d6818aed590965e6 to bind *and*
connect a given socket during creation.
Change-Id: I013f4cc10b26d332d52d231f252bb0f03df8c54b
|
|
Change-Id: I87e08bd84236ae5d5c057bca96d122e568a6b52a
|
|
We should have doxygen documentation for all libosmo-* APIs.
libosmo-netif is currently devoid of any API docs. Let's start with the
stream and datagram socket related functions.
Change-Id: I589a5e60d9df2b8a65fbaf68f80e3ae0039d8c2a
|
|
Change-Id: If0875cfa3eba9ef36acc0c4bfd0d168a45c380b9
|
|
without setting the BSC_FD_* flags prior to reconnection, the re-connect
would happen silently and the client program would not be notified via the
connect_cb().
Change-Id: Iaf8ec8662cf83476eee1b76fa41dc57f063f0ad3
|
|
Change-Id: I5a5659afde32f08b324e602b7b1f96de805ba031
|
|
In case the application is using the read-callback and a read returns 0,
then the application itself would want to trigger the reconnect. This
is different from the osmo_stream_cli_recv() case where the reconnect
can be handled internally to the library.
Change-Id: I41314bad4a9f44e8a61b9d2ba33d1a76b25bd145
|
|
if osmo_stream_cli_destroy() is called while the reconnect timer is
running, we would end up in a crash.
Change-Id: If6597130f472f1e2b8d9682002250ecd54675bb0
|
|
We use the magic value '-1' in case the file descriptor is not yet
initialized. If somebody calls osmo_stream_*_close() before this
changes, we used to crash. Let's check for this and avoid a crash.
Also, after close let's change the fd to -1 again to mark the fd
invalidity.
Change-Id: I3aa04999ab01cb7971ee2dad45dfc31ab4142868
|
|
The reconnect behavior was likely broken in commit
de3f57a8293a5b39435d6f283da23e0172bad8bb
If the user requests a re-connect, we should start it. Not only in case
the connection drops later, but also if the initial connection itself
fails.
Change-Id: I817e026404cbd9145cae2ce90bc57a1db1d2e12b
|
|
Change-Id: If7f6dce2b8325d4f2f732e1c14d6a1082e122584
Depends: libosmocore change-id I2bc93ab4781487e7685cfb63091a489cd126b1a8
|
|
Change-Id: Idfc804740e5a086701017d55c86aaf3304c84148
|
|
Change-Id: I5baf369dbf3948565614476980a32be59abaf42a
|
|
The library version does not match LIBVERSION from Makefile.am and -dev
package dependency - bump it.
Change-Id: Ie9bcd71ffcaeaa78aeef74ec329a6966ce1f1ba6
Related: OS#1860
|
|
Change-Id: I7c73d1a0b15cfb2a729687cde6f9a8e62a230fd7
|
|
Make it simple to setup and use this repo with 'git review' command.
Change-Id: I4fc8b17a0cbea16c7bdd7e50d106ef4aa35780e0
|
|
debian/control:
* restructure to make it easier to incorporate further changes
* update package descriptions
* update project URL
debian/rules:
* use proper hardening syntax
* restructure to make it easier to incorporate further changes
* add cleanup override
debian/copyright: add file matching Debian format
Change-Id: I9174b34a79c0562ef43f757ea76d67301088f109
Related: OS#1694
|
|
Fixes: CID#57922
Change-Id: Ibaafdd49d9446a12fe7d0e2f5b2039da3ffc7ea9
|
|
This lead to compiler warnings on FreeBSD, as setsockopt() is undefined.
Change-Id: Ie0ee3e48adfd0cd252703ec020cef28cf76ca223
|
|
osmo_sock_init() never returns -1 + errno EINPROGRESS. It will return a
positive fd in case the connect operation is in progress. Therefore,
the related code in osmo_stream_cli_open2() was impossible to execute.
Change-Id: Id3483d1d1d4d2eabba94729ea29e5c93b33abff0
Fixes: Coverity CID 57861
|
|
Change-Id: Ia777221cd0472cd1e7aa79e5146b07048a545dd8
Fixes: Coverity CID 57860
|
|
memcpy
Change-Id: Id962821c71b3a1c4c01c1131eb809b8ec8eaa062
Fixes: Coverity CID 57859
|
|
Change-Id: I1b5fa97d14e69ff502b6deba0fd898a01e53420f
Fixes: Coverity CID 57633
|
|
Change-Id: If40e85600ca1dfbda5975d7aa92cccdb11f9c34d
Fixes: Coverity CID 57632
|
|
When the setsockopt() in sctp_sock_activate_events() indicates an error,
let's print an error message in the log about this.
Change-Id: I5920154e23debe6d01eaa156005db0842f1a18cc
Fixes: Coverity CID 57634
|
|
lapd-over-datagram-network.c:38:12: warning: ‘sapi’ defined but not used [-Wunused-variable]
static int sapi = 63, tei = 0;
^~~~
Change-Id: If367deb0e0d7d5e031db2bd905179263d18703f0
|
|
FreeBSD etc...)
Change-Id: If4f2a99b2baf143551a7122f40ed1f9088c5936c
Signed-off-by: Arran Cudbard-Bell <a.cudbardb@freeradius.org>
|
|
Like in libosmo-abis' jenkins.sh
Change-Id: I022fbaaa1d211f68b38f18cfaf338ece51198c34
|
|
Change-Id: Ifaea95befa3d1d8f6f047e22efcd62cb0bd8b287
|
|
Explicitly set AC_CONFIG_AUX_DIR.
To reproduce the error avoided by this patch:
rm install-sh # in case it was already generated.
touch ../install-sh # yes, outside this source tree
autoreconf -fi
This will produce an error like
...
configure.ac:16: error: required file '../ltmain.sh' not found
configure.ac:5: installing '../missing'
src/Makefile.am: installing '../depcomp'
autoreconf: automake failed with exit status: 1
See also automake (vim `which automake`) and look for 'sub locate_aux_dir'.
Change-Id: Idcce286e83b802b9cd96cee6230aedd51a660b12
|
|
Change-Id: Ia0380da1f4980035938ec39cd2b5674f0400fbb3
|
|
Introduce a local #define to disable the real-time constraint from osmux-test.
It would make sense to remove this completely, but in case anyone may be
interested in the timing on a specific platform, I've just #defined it away.
The real-time constraint to pass or fail the test is a bad idea in terms of our
build server. Whenever the server is loaded, the tests will fail for no reason,
like here: https://gerrit.osmocom.org/474
The real time to calculate is highly dependent also on the hardware platform.
The arbitrarity of the time constraint is sort of proven by dd24cdd95f3fb8c8f
which simply doubles the time to pass the test.
Change-Id: Ic1da4bd22411652334f73195b2e37853e0738906
|
|
Make sure the version number of this sourcepackage is higher than
the one found in Debian SID.
Change-Id: I6486f91bc11e0828b4ccd0e22f8e2135af0d271a
Reviewed-on: https://gerrit.osmocom.org/111
Tested-by: Jenkins Builder
Reviewed-by: Holger Freyther <holger@freyther.de>
|
|
Use this function in osmux_batch_del_circuit() since msgs are stored in a list
per circuit. After the circuit is free()d the msgs are lost.
Before this patch any messages enqueued inside a batch when the circiut is
deleted were leaking.
Change-Id: Ib0311652183332d0475bf7347023d518d38487ef
Ticket: OS#1733
Reviewed-on: https://gerrit.osmocom.org/120
Tested-by: Jenkins Builder
Reviewed-by: Holger Freyther <holger@freyther.de>
|
|
Change-Id: If224980123d4a369133499ab7b577d02511f4055
Ticket: OS#1733
Reviewed-on: https://gerrit.osmocom.org/119
Tested-by: Jenkins Builder
Reviewed-by: Holger Freyther <holger@freyther.de>
|
|
This seems to be a copy of paste of libsomo-abis. Let us just drop
it here and be done with it.
Change-Id: Ia5cb2b572fb5597605284d1c3f657d548aa790f2
Reviewed-on: https://gerrit.osmocom.org/64
Tested-by: Jenkins Builder
Reviewed-by: Holger Freyther <holger@freyther.de>
|
|
This can be used to replicate a build issue more easily.
|
|
We need to have the sctp-dev headers to be installed to be able
to build this package.
|
|
|
|
|
|
Coverity points out that buf might not be NULL terminated. For the
memcpy ret was already used, so use ret for msgb_put as well.
Fixes: CID#57922
|
|
|
|
On some systems sctp_* is part of the standard libc, so do not
use AC_CHECK_LIB but AC_SEARCH_LIBS to find the symbol we need.
Both macros modify LIBS which means all applications will link
again libsctp and this is not what we want. Undo the side-effect
of LIBS and export LIBSCTP_LIBS which is already used in the
Makefile.am.
|