[mythtv-commits] Ticket #2621: Perl bindings - leading zero on 24 hour hour in Program.pm
MythTV
mythtv at cvs.mythtv.org
Fri Oct 27 03:32:31 UTC 2006
#2621: Perl bindings - leading zero on 24 hour hour in Program.pm
----------------------------------------------+-----------------------------
Reporter: sphery <mtdean at thirdcontact.com> | Owner: ijr
Type: patch | Status: new
Priority: minor | Milestone: unknown
Component: mythtv | Version: 0.20
Severity: medium |
----------------------------------------------+-----------------------------
The use of the localtime function (which returns elements as ints), which
is new since formatting was moved to the perl bindings, means that in
addition to conditionally (<10) prepending a leading zero to the 12-hour
hour (which previously was converted to an int), we now need to prepend a
leading zero to the 24-hour hour (which was previously retrieved as a
string from the query).
The attached patch does the comparison and prepends a zero, as required.
I changed the value after using the int value for creation of the 12-hour
hour (rather than convert the 24-hour value to string and back to int for
the 12-hour comparison/assignment, which would require converting back to
string, again, for 9 of 12 possible values).
--
Ticket URL: <http://svn.mythtv.org/trac/ticket/2621>
MythTV <http://www.mythtv.org/>
MythTV
More information about the mythtv-commits
mailing list