Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: TagLib messages

by stevieb (Canon)
on Jun 24, 2015 at 17:12 UTC ( [id://1131845]=note: print w/replies, xml ) Need Help??


in reply to TagLib messages

One way is to put the specific code that is generating the warning into a block that redirects STDOUT. You'll want to ensure you limit the scope, because if any other warnings are generated, you won't see them.

#!/usr/bin/perl use warnings; use strict; sub warning { print "ERROR!!!\n"; } my $out; open my $stdout, '>', \$out or die $!; { local *STDOUT = $stdout; warning(); }

-stevieb

Replies are listed 'Best First'.
Re^2: TagLib messages
by jfroebe (Parson) on Jun 24, 2015 at 19:21 UTC

    Perhaps a patch to the maintainer providing a method to categorize the warnings so you can silence the warnings of only the type you want?

    Jason L. Froebe

    Tech Blog

Re^2: TagLib messages
by Anonymous Monk on Jun 25, 2015 at 06:34 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1131845]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (7)
As of 2024-03-29 00:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found