Jesper Weissglas says:
> In order to use http socket 80 streaming the QTSS cannot use the primary
> eth0 ip-addres.
Well, that's not quite true. If the primary ip address is being used by
apache or another webserver, then QTSS can't use it.
But if you want to run both the webserver and QTSS on port 80, they have to
use different IP addresses.
> As far as I understand it, the <PREF NAME="bind_ip_addr">
> should be used to make QTSS bind to an alias ip instead.
>
> It appears to me that the code doesn't quite get the preference. If I
> specify the valid ip for the eth0:0 interface, the server still binds to
> eth0.
>
> If I specify a totally errorneus string, I still don't get any error.
I don't have QTSS 3, but DSS 3 has the exact same problem, obviously.
> (I've tried looking into QTSServerPrefs.cpp, but since I'm a C rather than
> C++ man, it is a little to convolved for me...)
It's actually really simple code. If you look in the header file
QTSServerPrefs.h, you can see that the function GetRTSPIPAddress() just
returns the variable fIPAddress. And looking through the .cpp file, this
variable gets initialized to 0, and is never touched again.
I believe the 2.0 code initialized the value as soon as the preference was
read, but they appear to have forgotten that when they rewrote the prefs
code to use XML.
The best solution would be to copy the exact same code that's in 2.01. But I
was in a hurry, and it was taking too long to download, so I just wrote a
replacement for GetRTSPIPAddress() that ignores the fIPAddress variable and
just converts the string preference (by using inet_aton and, if that fails,
gethostbyname) on the fly. It also tries to generate appropriate errors, but
I'm not sure I did that properly.
Anyway, I'm currently running DSS 3 Preview bound to a single IP address; in
other words, the fix works for me.
I posted it to modifications, but if you want to get the patch, go to
http://www.cubase.net/DSSfix/ and download it. Or, if you're in a big hurry
too, just download ftp://ftp.cubase.net/pub/DSS/DSS3_bind_ip_addr_fix.diff
and install the patch (with -Np1) in the root DarwinStreamingSrvr3_Preview
directory.