Skip Menu |

This queue is for tickets about the Audio-Wav CPAN distribution.

Report information
The Basics
Id: 116394
Status: new
Priority: 0/
Queue: Audio-Wav

People
Owner: Nobody in particular
Requestors: g.zouganelis [...] microbase.gr
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: BUG: Read.pm v0.14 - Illegal division by zero at line 430
Date: Fri, 22 Jul 2016 12:20:03 +0300
To: <bug-Audio-Wav [...] rt.cpan.org>
From: "George Zouganelis" <g.zouganelis [...] microbase.gr>
Greetings, While using your Audio::Wav module, we discovered a minor issue due to improper safety checks in divisions: For example, when trying to read the length of an invalid/empty wav file, an Illegal division by zero exception is thrown in length_seconds() function at Read.pm@430 Here is a suggested patch: sub length_seconds { my $self = shift; my $data = $self -> {data}; if($data -> {bytes_sec}>0) { return $data -> {data_length} / $data -> {bytes_sec}; } else { return 0; } } I suppose length_samples() should be changed accordingly. Regards, George Zouganelis / Senior Developer <http://www.microbase.gr/> 14 Iteas Str., Argyroupoli, 16452, Athens, Greece Tel: +30.212.000.5300 | Fax: +30.212.000.5800 <http://www.microbase.gr/> www.microbase.gr <https://twitter.com/MicrobaseGr> <https://www.linkedin.com/company/microbase-greece> Disclaimer. Privileged/Confidential information may be contained in this message and may be subject to legal privilege. Access to this email by anyone other than the intended recipient is unauthorized. If you are not the intended recipient (or responsible for delivery of the message to such person), you may not use, copy, distribute or deliver to anyone this message (or any part of its contents) or take any action in reliance on it. In such case, you should destroy this message, and notify us immediately. All reasonable precautions have been taken to ensure no viruses are present in this email. As we cannot accept responsibility for any loss or damage arising from the use of this email or attachments we recommend that you subject these to your virus checking procedures prior to use. The views, opinions, conclusions and other information expressed in this electronic mail are not given or endorsed by Microbase unless otherwise indicated by an authorized company representative independent of this message. Microbase Ltd.

Message body is not shown because it is too large.

Download image003.png
image/png 4.3k
image003.png
Download image002.png
image/png 4.3k
image002.png
Download image001.png
image/png 8.8k
image001.png