Comparing version 1.1.6 to 1.1.7
@@ -22,3 +22,3 @@ | ||
if (error) { | ||
pollCb (error, device); | ||
pollCb (error, null); | ||
} else { | ||
@@ -43,4 +43,4 @@ for (var i = 0; i < varbinds.length; i++) { | ||
function pollVlans () { | ||
if (device.VlandIds.length > 0) { | ||
var vlanId = device.VlandIds.pop (); | ||
if (device.vlandIds.length > 0) { | ||
var vlanId = device.vlandIds.pop (); | ||
var session = snmp.createSession (target, | ||
@@ -55,3 +55,3 @@ community + "@" + vlanId, {version: version}); | ||
if (error) { | ||
pollCb (error, device); | ||
pollCb (error, null); | ||
} else { | ||
@@ -66,5 +66,6 @@ for (index in table) { | ||
device.devices[vlanId] = table; | ||
if (device.VlandIds.length > 0) { | ||
if (device.vlandIds.length > 0) { | ||
pollVlans (); | ||
} else { | ||
delete device.vlandIds; | ||
pollCb (null, device); | ||
@@ -79,5 +80,6 @@ } | ||
if (device.VlandIds.length > 0) { | ||
if (device.vlandIds.length > 0) { | ||
pollVlans (); | ||
} else { | ||
delete device.vlandIds; | ||
pollCb (null, device); | ||
@@ -93,3 +95,3 @@ } | ||
if (error) { | ||
pollCb (error, device); | ||
pollCb (error, null); | ||
} else { | ||
@@ -109,6 +111,6 @@ device.intefaces = table; | ||
if (error) { | ||
pollCb (error, device); | ||
pollCb (error, null); | ||
} else { | ||
device.vlans = table; | ||
device.VlandIds = []; | ||
device.vlandIds = []; | ||
device.devices = {}; | ||
@@ -124,3 +126,3 @@ | ||
if (table[vlanId][3] == 1) | ||
device.VlandIds.push (vlanId); | ||
device.vlandIds.push (vlanId); | ||
} | ||
@@ -127,0 +129,0 @@ } |
{ | ||
"name": "net-snmp", | ||
"version": "1.1.6", | ||
"version": "1.1.7", | ||
"description": "JavaScript implementation of the Simple Network Management Protocol (SNMP)", | ||
@@ -34,3 +34,3 @@ "main": "index.js", | ||
"author": "Stephen Vickers <stephen.vickers.sv@gmail.com>", | ||
"license": "GPL" | ||
"license": "MIT" | ||
} |
@@ -1085,2 +1085,6 @@ | ||
## Version 1.1.7 - 11/05/2013 | ||
* Use MIT license instead of GPL | ||
# Roadmap | ||
@@ -1096,18 +1100,24 @@ | ||
This program is free software: you can redistribute it and/or modify it under | ||
the terms of the GNU General Public License as published by the Free Software | ||
Foundation, either version 3 of the License, or (at your option) any later | ||
version. | ||
Copyright (c) 2013 Stephen Vickers | ||
This program is distributed in the hope that it will be useful, but WITHOUT | ||
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS | ||
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more | ||
details. | ||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
You should have received a copy of the GNU General Public License along with | ||
this program. If not, see | ||
[http://www.gnu.org/licenses](http://www.gnu.org/licenses). | ||
The above copyright notice and this permission notice shall be included in | ||
all copies or substantial portions of the Software. | ||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. | ||
# Author | ||
Stephen Vickers <stephen.vickers.sv@gmail.com> |
Misc. License Issues
License(Experimental) A package's licensing information has fine-grained problems.
Found 1 instance in 1 package
505912
0
1577
1122