2
0
mirror of https://github.com/munin-monitoring/contrib.git synced 2018-11-08 00:59:34 +01:00

Place "use threads" within "eval" to make it pass syntax checks on travis-ci

This commit is contained in:
Stig Sandbeck Mathisen 2014-10-05 20:38:16 +02:00
parent 632c24d0a9
commit ff4c91acb8

View File

@ -72,7 +72,14 @@ USA.
use strict;
use warnings;
use threads;
# This evil "eval" is to make Travis CI able to test the plugin syntax
# without having a perl built with threads.
#
# Also: The use of interpreter-based threads in perl is officially
# discouraged.
eval 'use threads; 1;' or die 'Could not use threads';
use Net::Ping;
my (%defaults, @hosts, $cmd_arg);