Opened 15 years ago

Closed 15 years ago

#1566 closed defect (fixed)

Recorded Programs page displays incorrect file sizes

Reported by: derek@… Owned by: xris
Priority: minor Milestone: unknown
Component: mythweb Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

The recorded programs page is displaying the incorrect file sizes (using SVN 9441).

The first problem seems to be that all file sizes are off by a factor of 1024:

On the recorded programs page of mythweb, my recording of 'The Colbert Report' shows a file size of 1.1 TB. The actual file size should be 1.1 GB. All file sizes are off by this factor of 1024, so the first thing I did was remove the gmp_mul('1024', ...) on line 279 of includes/programs.php. This showed the proper unit of the file.

The other problem is that some files are showing a negative file size (even after removing the gmp_mul('1024', ...) call.

Using the original SVN 9441 source, the recorded programs page of mythweb shows a 
file size for my L&O: SVU recording as '-2009402966016 B'.  When I remove the 
multiply by 1024 call above the number changes to: '-1962307584 B'.  The actual file 
size is ~2.2GB (it's a one hour recording from a PVR-250 card using the default 
settings for bitrate, etc.).

mythtv@mythtv-server:/myth/tv$ ls -l 2017_20060321220000.mpg
-rw-r--r--  1 mythtv mythtv 2332659712 Mar 21 23:00 2017_20060321220000.mpg

This would appear to be an integer overflow, perhaps? I'm running this on Apache 2.0.55 and PHP 5.0.5 on an Intel 32-bit architecture. I'm going to try to investigate the negative numbers when I have more time later in the week. I'll try to submit a single patch that covers both issues, but if not I'll at least add one that removes the extra multiplying by 1024.

Change History (1)

comment:1 Changed 15 years ago by derek@…

Resolution: fixed
Status: newclosed

Appears to have been fixed in [9476].

Note: See TracTickets for help on using tickets.