summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir.cohen@xorcom.com>2009-05-08 10:21:05 +0000
committerTzafrir Cohen <tzafrir.cohen@xorcom.com>2009-05-08 10:21:05 +0000
commit2582d2c8824e66d7f378d410b0381057adaf7f88 (patch)
tree1cb54ee102b1a4c4f8a2ea9a27bcf5d7944a9391
parenta8fed829ef0fac114b19db4e29b985d3f1a7abfd (diff)
dahdi-perl: scan only "number" files under /proc .
(In case someone, such as dahdi_dynamic_ethmf adds there some other entries) git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@6579 a0bf4364-ded3-4de4-8d8a-66a801d63aff
-rw-r--r--xpp/perl_modules/Dahdi.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/xpp/perl_modules/Dahdi.pm b/xpp/perl_modules/Dahdi.pm
index 93ce25b..fa5955a 100644
--- a/xpp/perl_modules/Dahdi.pm
+++ b/xpp/perl_modules/Dahdi.pm
@@ -46,6 +46,7 @@ sub spans() {
-d $proc_base or return ();
foreach my $zfile (glob "$proc_base/*") {
$zfile =~ s:$proc_base/::;
+ next unless ($zfile =~ /^\d+$/);
my $span = Dahdi::Span->new($zfile);
push(@spans, $span);
}