diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2006-07-22 11:59:28 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2006-07-22 11:59:28 +0200 |
commit | bd6046c37de262af7ddeb9a26b613c4488312ad0 (patch) | |
tree | 7ff6469774ed4c4e220b25a40a9396ad50b6f261 /config.c | |
parent | 5f0b2fbf2e54724af021e5f1b1a803d0936d5f3d (diff) | |
download | vdr-bd6046c37de262af7ddeb9a26b613c4488312ad0.tar.gz vdr-bd6046c37de262af7ddeb9a26b613c4488312ad0.tar.bz2 |
Fixed handling network masks in the svdrphosts.conf file
Diffstat (limited to 'config.c')
-rw-r--r-- | config.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: config.c 1.145 2006/04/17 11:00:00 kls Exp $ + * $Id: config.c 1.146 2006/07/22 11:57:51 kls Exp $ */ #include "config.h" @@ -106,8 +106,10 @@ bool cSVDRPhost::Parse(const char *s) *(char *)p = 0; // yes, we know it's 'const' - will be restored! if (m == 0) mask = 0; - else - mask >>= (32 - m); + else { + mask <<= (32 - m); + mask = htonl(mask); + } } int result = inet_aton(s, &addr); if (p) |