OpenCPN/OpenCPN — pull request #86 by stripydog (2014-01-02 11:58:24+00:00)
Title: Added multicast support

Hello,

this is my first experience with github so please go easy on me :-)

This patch is really simple and was originally submitted to flyspray as FS#1063. All it does is to check whether the address a user inputs for a UDP data connection is an IPv4 multicast address. If it is it adds membership of that group on the default multicast interface. Code is also added to the datastream destructor to remove group membership when the datastream is destroyed.

This patch should have no impact on anything without a UDP multicast address.

Currently if a user requests a datastream with a multicast address he/she will not receive anything as group membership won't be added to the interface.

NOTE!! I only have a linux development platform. This compiles fine on linux. It *should* compile on MacOS. For Windows I checked technet to ensure that I wasn't doing anything not in windows APIs but you may need to tweak included header files for different versions of windows: I have no facilities for windows development. It *should* only be header files which need adding though.