[mythtv-users] using mythtv as clockradio

Michael T. Dean mtdean at thirdcontact.com
Thu Jan 21 12:25:17 UTC 2016


On 01/21/2016 07:08 AM, Hika van den Hoven wrote:
>> Ah you're right they are lowercase in the database. I'm so used that
>> hostnames are case-insensitive and I always use the form with
>> mnemonic capitals!
>> config.xml has no hostname set on any machine. I have a very stable
>> DNS, which also has the strings with the mnemonic capitals, so MythTV
>> must have automatically reverted the dns names to lowercase!

MythTV doesn't use DNS to generate the profile ID when one isn't given 
in config.xml.  It uses the gethostname() system call, which gives 
exactly the same value given by the hostname command.  I'd guess it 
does--or did at the time you first set up your system--give the 
all-lowercase value.

> But what I then do not understand is why it accepts the capitalized
> host when requesting the full list?
>
> <backend>:6544/Myth/GetSetting?HostName=pc-Hika
>
> and not when querying a specific value?

Because when querying the whole list, we don't do any in-code (in-C++) 
comparisons, so the only comparison is by MySQL, and since we're using 
the utf8_general_ci (meaning UTF-8 general case-insensitive) collation 
for the settings table, it does case-insensitive comparisons.  This 
inconsistency is yet another reason why the issue in #12320 is important.

Mike


More information about the mythtv-users mailing list