catta
2 months agoDisable -Wcast-qual and -Wcast-align. master
Guus Sliepen [Mon, 23 Sep 2019 12:14:56 +0000 (14:14 +0200)]
Disable -Wcast-qual and -Wcast-align.

The code heavily relies on the fact that some buffers are properly aligned,
and in fact even <linux/netlink.h> triggers a cast-align warning. To prevent
these warnings from hiding more important warnings, we disable them.

2 months agoFix some compiler warnings found by GCC 9 and Clang 10.
Guus Sliepen [Mon, 23 Sep 2019 12:12:48 +0000 (14:12 +0200)]
Fix some compiler warnings found by GCC 9 and Clang 10.

2 months agoFix varargs warning for catta_server_add_service().
Guus Sliepen [Mon, 23 Sep 2019 12:12:28 +0000 (14:12 +0200)]
Fix varargs warning for catta_server_add_service().

Promote the type of the port argument, which comes right before any variable
arguments, to ensure va_start() doesn't run into undefined behaviour.

The alternative would be to shuffle the arguments so that a pointer is
the last non-variable argument, but that would break the ABI.

2 years agoEnsure make distcheck runs without errors. develop
Guus Sliepen [Sun, 8 Oct 2017 15:32:02 +0000 (17:32 +0200)]
Ensure make distcheck runs without errors.

4 years agoMerge pull request #4 from catta-x/feature/wincompat
vollkorn1982 [Wed, 16 Sep 2015 14:11:12 +0000 (16:11 +0200)]
Merge pull request #4 from catta-x/feature/wincompat

fix msvc _WIN64 ssize_t definition

4 years agofix msvc _WIN64 ssize_t definition
everHannes [Wed, 16 Sep 2015 13:30:18 +0000 (15:30 +0200)]
fix msvc _WIN64 ssize_t definition

4 years agoMerge branch 'develop' of github.com:catta-x/catta into develop
HiveError [Mon, 31 Aug 2015 15:36:35 +0000 (17:36 +0200)]
Merge branch 'develop' of github.com:catta-x/catta into develop

4 years agodisable to send src_address with windows ipv6 as it somehow causes WSASendMsg to...
everHannes [Mon, 31 Aug 2015 15:33:56 +0000 (17:33 +0200)]
disable to send src_address with windows ipv6 as it somehow causes WSASendMsg to fail with an Invalid Argument error 10022 #3

4 years agoadd wsa error code to errnostrsocket for easier error lookup
everHannes [Mon, 31 Aug 2015 15:07:17 +0000 (17:07 +0200)]
add wsa error code to errnostrsocket for easier error lookup

4 years agoAdd support for net/route.h on iOS.
Aaron Krebs [Wed, 26 Aug 2015 13:29:11 +0000 (15:29 +0200)]
Add support for net/route.h on iOS.

net/route.h is included in on OSX and the iPhoneSimulator SDK, but
not the iPhoneOS SDK. As a workaround, include /usr/include/net/route.h from
OSX 10.10 ourselves.

4 years agomoved back windows compat headers and fixed catta headers to stop clutter dependent...
everHannes [Mon, 24 Aug 2015 18:36:08 +0000 (20:36 +0200)]
moved back windows compat headers and fixed catta headers to stop clutter dependent projects with wincompat.h redefines
also fixed WINVER to be a project property set in src/Makefile.am instead of undef/define override in wincompat.h

4 years agofix backend #705
jan [Thu, 20 Aug 2015 13:58:37 +0000 (15:58 +0200)]
fix backend #705

Avoiding a state change callback while still constructing catta server, so
the callback can expect to have a readily constructed catta server
available. This changes the behaviour and catta will only change into
running state when at least one network interface is found and used.

4 years agomove wincompat headers to include path and add to make install
everHannes [Thu, 20 Aug 2015 11:51:12 +0000 (13:51 +0200)]
move wincompat headers to include path and add to make install

4 years agocleaned some compiler warning flags
everHannes [Sun, 16 Aug 2015 11:24:19 +0000 (13:24 +0200)]
cleaned some compiler warning flags
-Wdeclaration-after-statement -> stop confusing c90 warning, compilers by now should support c99 or above
-Wformat -> defined by -Wall
-Wendif-labels -> enabled by default
-Wpointer-arith -> defined by -pedantic
-Wno-cast-qual -> -Wcast-qual, have it or remove it

refer
https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html
https://gcc.gnu.org/onlinedocs/cpp/Invocation.html

4 years agofix gcc mingw compile (gcc 5.1 x86_64)
everHannes [Sun, 16 Aug 2015 09:24:43 +0000 (11:24 +0200)]
fix gcc mingw compile (gcc 5.1 x86_64)

4 years agoclean incomplete mingw32 4.8.1 wincompat.h defines
Hannes [Tue, 23 Jun 2015 13:14:45 +0000 (15:14 +0200)]
clean incomplete mingw32 4.8.1 wincompat.h defines

4 years agofix headers to be used with Visual Studio 2015 RC
Hannes [Tue, 23 Jun 2015 13:08:39 +0000 (15:08 +0200)]
fix headers to be used with Visual Studio 2015 RC

4 years agogenerate .def file to be used for porting the mingw compiled library to windows visua...
Hannes [Tue, 23 Jun 2015 13:06:02 +0000 (15:06 +0200)]
generate .def file to be used for porting the mingw compiled library to windows visual studio

5 years agofix mingw c compiler casting
Hannes [Sat, 22 Nov 2014 18:36:25 +0000 (19:36 +0100)]
fix mingw c compiler casting

5 years agoavoid implicit conversion from void* to char*
Niklas Hofmann [Thu, 20 Nov 2014 23:22:49 +0000 (00:22 +0100)]
avoid implicit conversion from void* to char*

5 years agoapple compatibility
Niklas Hofmann [Mon, 27 Oct 2014 05:45:59 +0000 (06:45 +0100)]
apple compatibility

5 years agoMerge tag '0.0.1' into develop
Niklas Hofmann [Mon, 20 Oct 2014 12:18:02 +0000 (14:18 +0200)]
Merge tag '0.0.1' into develop

0.0.1

5 years agoMerge branch 'release/0.0.1'
Niklas Hofmann [Mon, 20 Oct 2014 12:17:48 +0000 (14:17 +0200)]
Merge branch 'release/0.0.1'

5 years agoMerge pull request #2 from everbase/feature/windows
Niklas [Mon, 20 Oct 2014 12:08:11 +0000 (14:08 +0200)]
Merge pull request #2 from everbase/feature/windows

Port the library to Windows

5 years agoremove network traffic debug output
Sven M. Hallberg [Thu, 16 Oct 2014 15:44:17 +0000 (17:44 +0200)]
remove network traffic debug output

5 years agoremove simple-watch debug output
Sven M. Hallberg [Thu, 16 Oct 2014 15:41:43 +0000 (17:41 +0200)]
remove simple-watch debug output

5 years agomake ioctl() work for setting values
Sven M. Hallberg [Thu, 16 Oct 2014 15:36:58 +0000 (17:36 +0200)]
make ioctl() work for setting values

5 years agocheck for failure of catta_set_nonblock in simple-watch and iface-windows
Sven M. Hallberg [Thu, 16 Oct 2014 15:36:14 +0000 (17:36 +0200)]
check for failure of catta_set_nonblock in simple-watch and iface-windows

5 years agoadd some debug output to simple-watch poll implementation
Sven M. Hallberg [Thu, 16 Oct 2014 15:29:03 +0000 (17:29 +0200)]
add some debug output to simple-watch poll implementation

5 years agonetwork traffic debug output, including source address on recvmsg
Sven M. Hallberg [Wed, 15 Oct 2014 15:39:31 +0000 (17:39 +0200)]
network traffic debug output, including source address on recvmsg

5 years agochange some printf format specifiers in tests that are unrecognized by MingW
Sven M. Hallberg [Wed, 15 Oct 2014 10:10:46 +0000 (12:10 +0200)]
change some printf format specifiers in tests that are unrecognized by MingW

5 years agodon't set -Wmissing-noreturn on Windows because libtool
Sven M. Hallberg [Wed, 15 Oct 2014 09:53:06 +0000 (11:53 +0200)]
don't set -Wmissing-noreturn on Windows because libtool

5 years agopublish example: exit cleanly on SIGINT, SIGTERM
Sven M. Hallberg [Tue, 14 Oct 2014 13:27:45 +0000 (15:27 +0200)]
publish example: exit cleanly on SIGINT, SIGTERM

5 years agoexplicitly ignore return value when writing to pipe
Sven M. Hallberg [Wed, 17 Sep 2014 10:32:46 +0000 (12:32 +0200)]
explicitly ignore return value when writing to pipe

5 years agoremove debug output on interface changes
Sven M. Hallberg [Thu, 11 Sep 2014 20:00:48 +0000 (22:00 +0200)]
remove debug output on interface changes

5 years agoremove debug output on initial interface enumeration
Sven M. Hallberg [Thu, 11 Sep 2014 19:59:31 +0000 (21:59 +0200)]
remove debug output on initial interface enumeration

5 years agoremove debug output on network traffic
Sven M. Hallberg [Thu, 11 Sep 2014 19:56:02 +0000 (21:56 +0200)]
remove debug output on network traffic

5 years agoprocess change events in the order they are received
Sven M. Hallberg [Thu, 11 Sep 2014 19:53:02 +0000 (21:53 +0200)]
process change events in the order they are received

5 years agohandle address change events
Sven M. Hallberg [Thu, 11 Sep 2014 18:55:17 +0000 (20:55 +0200)]
handle address change events

5 years agohandle interface change events
Sven M. Hallberg [Thu, 11 Sep 2014 15:45:55 +0000 (17:45 +0200)]
handle interface change events

5 years agoskeleton implementation of interface change event handling
Sven M. Hallberg [Wed, 10 Sep 2014 17:58:38 +0000 (19:58 +0200)]
skeleton implementation of interface change event handling

5 years agoreadpipe/writepite/closepipe for fake pipes on Windows
Sven M. Hallberg [Wed, 10 Sep 2014 17:56:26 +0000 (19:56 +0200)]
readpipe/writepite/closepipe for fake pipes on Windows

5 years agochange some int declarations that should have said CattaIfIndex
Sven M. Hallberg [Mon, 8 Sep 2014 20:09:42 +0000 (22:09 +0200)]
change some int declarations that should have said CattaIfIndex

5 years agocomment about IP_ADAPTER_ADDRESS_DNS_ELIGIBLE (should we use it?)
Sven M. Hallberg [Mon, 8 Sep 2014 20:01:58 +0000 (22:01 +0200)]
comment about IP_ADAPTER_ADDRESS_DNS_ELIGIBLE (should we use it?)

5 years agoskip transient ("cluster") addresses on Windows, as per MSDN
Sven M. Hallberg [Mon, 8 Sep 2014 20:01:40 +0000 (22:01 +0200)]
skip transient ("cluster") addresses on Windows, as per MSDN

5 years agoinclude address flags in debug output
Sven M. Hallberg [Mon, 8 Sep 2014 20:01:03 +0000 (22:01 +0200)]
include address flags in debug output

5 years agoset IPv4 source address correctly on Windows
Sven M. Hallberg [Mon, 8 Sep 2014 19:03:48 +0000 (21:03 +0200)]
set IPv4 source address correctly on Windows

5 years agofor posterity: some debug output in sendmsg/recvmsg
Sven M. Hallberg [Mon, 8 Sep 2014 19:03:06 +0000 (21:03 +0200)]
for posterity: some debug output in sendmsg/recvmsg

5 years agodo use the interface index provided by Windows
Sven M. Hallberg [Mon, 8 Sep 2014 17:10:06 +0000 (19:10 +0200)]
do use the interface index provided by Windows

5 years agobe more specific in an error message when receiving packets
Sven M. Hallberg [Mon, 8 Sep 2014 16:21:39 +0000 (18:21 +0200)]
be more specific in an error message when receiving packets

5 years agofix an error message for IPv6
Sven M. Hallberg [Mon, 8 Sep 2014 15:06:23 +0000 (17:06 +0200)]
fix an error message for IPv6

5 years agouse WSAGetlastError/FormatMessage in place of strerror(errno) on Windows
Sven M. Hallberg [Mon, 8 Sep 2014 14:37:32 +0000 (16:37 +0200)]
use WSAGetlastError/FormatMessage in place of strerror(errno) on Windows

5 years agoenumerate network adapter addresses
Sven M. Hallberg [Mon, 8 Sep 2014 13:22:52 +0000 (15:22 +0200)]
enumerate network adapter addresses

5 years agomight as well make the debugging code a bit pretty
Sven M. Hallberg [Fri, 5 Sep 2014 19:00:47 +0000 (21:00 +0200)]
might as well make the debugging code a bit pretty

5 years agofix flags_ok computation (IfType and OperStatus are ordinals, not flags)
Sven M. Hallberg [Fri, 5 Sep 2014 18:52:33 +0000 (20:52 +0200)]
fix flags_ok computation (IfType and OperStatus are ordinals, not flags)

5 years agocoding style consistency
Sven M. Hallberg [Fri, 5 Sep 2014 18:34:46 +0000 (20:34 +0200)]
coding style consistency

5 years agoget human-readable interface names
Sven M. Hallberg [Fri, 5 Sep 2014 18:33:16 +0000 (20:33 +0200)]
get human-readable interface names

5 years agostart of windows interface detection
Sven M. Hallberg [Fri, 5 Sep 2014 18:19:49 +0000 (20:19 +0200)]
start of windows interface detection

5 years agodo not build dns-spin-test on Windows (for the time being)
Sven M. Hallberg [Thu, 4 Sep 2014 18:46:21 +0000 (20:46 +0200)]
do not build dns-spin-test on Windows (for the time being)

5 years agocheck for both EAGAIN and EWOULDBLOCK from sendmsg
Sven M. Hallberg [Thu, 4 Sep 2014 18:39:52 +0000 (20:39 +0200)]
check for both EAGAIN and EWOULDBLOCK from sendmsg

5 years agowrap lifetimes of CattaServer and CattaSimplePoll in WSAStartup/WSACleanup
Sven M. Hallberg [Wed, 3 Sep 2014 14:36:30 +0000 (16:36 +0200)]
wrap lifetimes of CattaServer and CattaSimplePoll in WSAStartup/WSACleanup

5 years agowork around picky SO_REUSEADDR semantics on Windows
Sven M. Hallberg [Wed, 3 Sep 2014 12:50:44 +0000 (14:50 +0200)]
work around picky SO_REUSEADDR semantics on Windows

5 years agouse rand() because random() isn't available on windows
Sven M. Hallberg [Mon, 1 Sep 2014 22:45:28 +0000 (00:45 +0200)]
use rand() because random() isn't available on windows

5 years agosupport building a DLL (needs --disable-stack-protector right now)
Sven M. Hallberg [Mon, 1 Sep 2014 22:37:00 +0000 (00:37 +0200)]
support building a DLL (needs --disable-stack-protector right now)

5 years agoremove some C++ remnants
Sven M. Hallberg [Mon, 1 Sep 2014 22:35:51 +0000 (00:35 +0200)]
remove some C++ remnants

5 years agodon't call pthread_sigmask on windows (MingW defines it as a no-op anyway)
Sven M. Hallberg [Mon, 1 Sep 2014 21:53:00 +0000 (23:53 +0200)]
don't call pthread_sigmask on windows (MingW defines it as a no-op anyway)

5 years agoadd an alias for poll and implement pipe in terms of sockets
Sven M. Hallberg [Mon, 1 Sep 2014 21:21:27 +0000 (23:21 +0200)]
add an alias for poll and implement pipe in terms of sockets

5 years agowork around lack of fcntl on Windows
Sven M. Hallberg [Fri, 29 Aug 2014 18:31:44 +0000 (20:31 +0200)]
work around lack of fcntl on Windows

5 years agosilence "unused parameter" warning
Sven M. Hallberg [Fri, 29 Aug 2014 17:25:05 +0000 (19:25 +0200)]
silence "unused parameter" warning

5 years agoon Windows this argument is not marked const
Sven M. Hallberg [Fri, 29 Aug 2014 17:19:19 +0000 (19:19 +0200)]
on Windows this argument is not marked const

5 years agoavoid pointer type warnings from setsockopt
Sven M. Hallberg [Fri, 29 Aug 2014 17:17:11 +0000 (19:17 +0200)]
avoid pointer type warnings from setsockopt

5 years agoadd ioctl as a wrapper around ioctlsocket
Sven M. Hallberg [Fri, 29 Aug 2014 16:51:12 +0000 (18:51 +0200)]
add ioctl as a wrapper around ioctlsocket

5 years agosocket.c needs closesocket from internal.h
Sven M. Hallberg [Fri, 29 Aug 2014 12:25:00 +0000 (14:25 +0200)]
socket.c needs closesocket from internal.h

5 years agoset the include flag for windows compat headers in configure
Sven M. Hallberg [Fri, 29 Aug 2014 12:24:21 +0000 (14:24 +0200)]
set the include flag for windows compat headers in configure

5 years agoWindows does not support in_pktinfo.ipi_spec_dst
Sven M. Hallberg [Fri, 29 Aug 2014 11:46:41 +0000 (13:46 +0200)]
Windows does not support in_pktinfo.ipi_spec_dst

5 years agoadd (untested) implementation of sendmsg in terms of WSASendMsg
Sven M. Hallberg [Fri, 29 Aug 2014 11:24:17 +0000 (13:24 +0200)]
add (untested) implementation of sendmsg in terms of WSASendMsg

5 years agoadd (untested) implementation of recvmsg in terms of WSARecvMsg
Sven M. Hallberg [Thu, 28 Aug 2014 18:36:55 +0000 (20:36 +0200)]
add (untested) implementation of recvmsg in terms of WSARecvMsg

5 years agoaesthetics
Sven M. Hallberg [Thu, 28 Aug 2014 18:18:19 +0000 (20:18 +0200)]
aesthetics

5 years agolink the library with -lws2_32
Sven M. Hallberg [Wed, 27 Aug 2014 11:48:53 +0000 (13:48 +0200)]
link the library with -lws2_32

5 years agows2tcpip.h defines socklen_t
Sven M. Hallberg [Wed, 27 Aug 2014 10:28:57 +0000 (12:28 +0200)]
ws2tcpip.h defines socklen_t

5 years agouse closesocket() on windows
Sven M. Hallberg [Tue, 26 Aug 2014 19:39:24 +0000 (21:39 +0200)]
use closesocket() on windows

5 years agoignore .dirstamp
Sven M. Hallberg [Tue, 26 Aug 2014 19:38:16 +0000 (21:38 +0200)]
ignore .dirstamp

5 years agoMerge branch 'feature/windows' of github.com:everbase/catta into feature/windows
Sven M. Hallberg [Tue, 26 Aug 2014 19:14:55 +0000 (21:14 +0200)]
Merge branch 'feature/windows' of github.com:everbase/catta into feature/windows

5 years agooh, we need the machine field, not nodename. also some gitignores
Sven M. Hallberg [Tue, 26 Aug 2014 18:50:46 +0000 (20:50 +0200)]
oh, we need the machine field, not nodename. also some gitignores

5 years agosome gitignores
Sven M. Hallberg [Tue, 26 Aug 2014 18:50:46 +0000 (20:50 +0200)]
some gitignores

5 years agoadd uname and socklen_t to windows compat layer
Sven M. Hallberg [Tue, 26 Aug 2014 18:49:49 +0000 (20:49 +0200)]
add uname and socklen_t to windows compat layer

5 years agorename interface -> iface everywhere
Sven M. Hallberg [Tue, 26 Aug 2014 17:11:39 +0000 (19:11 +0200)]
rename interface -> iface everywhere

5 years agostart of a windows compatibility layer
Sven M. Hallberg [Tue, 26 Aug 2014 12:50:53 +0000 (14:50 +0200)]
start of a windows compatibility layer

5 years agofix pthread shared linking check for MingW32
Sven M. Hallberg [Mon, 25 Aug 2014 18:17:16 +0000 (20:17 +0200)]
fix pthread shared linking check for MingW32

5 years agoMerge pull request #1 from everbase/feature/stripdown
Niklas [Fri, 22 Aug 2014 08:24:06 +0000 (10:24 +0200)]
Merge pull request #1 from everbase/feature/stripdown

Stripdown

5 years agorename everything avahi to catta
Sven M. Hallberg [Wed, 20 Aug 2014 13:43:39 +0000 (15:43 +0200)]
rename everything avahi to catta

5 years agomove public headers into their own directory
Sven M. Hallberg [Wed, 20 Aug 2014 12:44:21 +0000 (14:44 +0200)]
move public headers into their own directory

5 years agoremove disused i18n stuff
Sven M. Hallberg [Wed, 20 Aug 2014 11:52:08 +0000 (13:52 +0200)]
remove disused i18n stuff

5 years agorename 'common' directory to 'm4' (because really, forget doxygen.mk)
Sven M. Hallberg [Wed, 20 Aug 2014 11:46:35 +0000 (13:46 +0200)]
rename 'common' directory to 'm4' (because really, forget doxygen.mk)

5 years agomove tests into their own directory
Sven M. Hallberg [Wed, 20 Aug 2014 11:43:56 +0000 (13:43 +0200)]
move tests into their own directory

5 years agoremove a left-over reference to boostrap.sh and autogen.sh
Sven M. Hallberg [Wed, 20 Aug 2014 11:23:52 +0000 (13:23 +0200)]
remove a left-over reference to boostrap.sh and autogen.sh

5 years agocombine avahi-core and avahi-common components into one library
Sven M. Hallberg [Wed, 20 Aug 2014 11:23:27 +0000 (13:23 +0200)]
combine avahi-core and avahi-common components into one library

5 years agoforgot to pull the publish_no_reverse change to the example.
Sven M. Hallberg [Tue, 19 Aug 2014 13:30:16 +0000 (15:30 +0200)]
forgot to pull the publish_no_reverse change to the example.

5 years agoremove some more unneeded checks
Sven M. Hallberg [Tue, 19 Aug 2014 13:22:05 +0000 (15:22 +0200)]
remove some more unneeded checks

5 years agoremove some unneeded tests
Sven M. Hallberg [Tue, 19 Aug 2014 13:15:03 +0000 (15:15 +0200)]
remove some unneeded tests