Mono expecting /proc/net/route
Romain Tartière
romain at FreeBSD.org
Tue Sep 23 22:56:52 UTC 2014
Hi
On Fri, Sep 19, 2014 at 11:03:27PM +0800, Ben Woods wrote:
> In the process of trying to get http://mediabrowser.tv/ to work on FreeBSD,
> I have come across a bug in the port of mono to FreeBSD where it expects to
> be able to use /proc/net/route to find the IP address of the computer.
>
> Reviewing the mono code it appears it expects a few other things from /proc
> which don't exist in FreeBSD, even with linprocfs (e.g. /proc/net/snmp).
> https://github.com/mono/mono/search?utf8=%E2%9C%93&q=%22proc%2Fnet%22&type=Code
>
> Any ideas about the best way to resolve this?
>
> More details with my specific issues relating to MediaBrowser can be found
> here:
> http://mediabrowser.tv/community/index.php?/topic/2636-mb3-on-freenas-plugin/page-4
Are you refering to this?
https://github.com/mono/mono/blob/effa4c07ba850bedbe1ff54b2a5df281c058ebcb/mcs/class/System/System.Net.NetworkInformation/IPInterfaceProperties.cs#L77
AFAICR, the information should be available from a sysctl (what
netstat(8) does) or from a PF_ROUTE socket (what route(8) does), but it
may be easier to parse the output of netstat(8) instead of
reimplementing parts of netstat(8) or route(8) in managed code…
If you have a patch, feel free to share it here so that I can include it
;-)
--
Romain Tartière <romain at FreeBSD.org> http://people.FreeBSD.org/~romain/
pgp: 8234 9A78 E7C0 B807 0B59 80FF BA4D 1D95 5112 336F (ID: 0x5112336F)
(plain text =non-HTML= PGP/GPG encrypted/signed e-mail much appreciated)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 648 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-mono/attachments/20140924/f20831ed/attachment.sig>
More information about the freebsd-mono
mailing list