From 4ecf30d8e9b6b15082de01ce1cb30bc05605b2b8 Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Fri, 22 Feb 2008 18:41:06 +0000 Subject: [PATCH] dont fail getNetInterfaceStat for aliases --- bindings/java/src/org/hyperic/sigar/test/TestNetIf.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bindings/java/src/org/hyperic/sigar/test/TestNetIf.java b/bindings/java/src/org/hyperic/sigar/test/TestNetIf.java index c3be5c05..f84edfa4 100644 --- a/bindings/java/src/org/hyperic/sigar/test/TestNetIf.java +++ b/bindings/java/src/org/hyperic/sigar/test/TestNetIf.java @@ -61,8 +61,10 @@ public class TestNetIf extends SigarTestCase { } catch (SigarNotImplementedException e) { //ok } catch (SigarException e) { - fail("getNetInterfaceStat(" + name + "): " + - e.getMessage()); + if (name.indexOf(':') == -1) { + fail("getNetInterfaceStat(" + name + "): " + + e.getMessage()); + } //else alias may not have metrics } } }