function result(error, varbinds) {
        if (combinedTimeoutExpired) {
            return;
        }
        if (error) {
            clearTimeout(combinedTimeoutTimer);
            callback(error);
        } else {
            if (inTree(options.startOid, varbinds[0].oid)) {
                if (varbinds[0].value === 'endOfMibView' || varbinds[0].value === 'noSuchObject' || varbinds[0].value === 'noSuchInstance') {
                    clearTimeout(combinedTimeoutTimer);
                    callback(null, vbs);
                } else if (vbs.length && compareOids(vbs.slice(-1)[0].oid, varbinds[0].oid) !== 1) {
                    return callback(new Error('OID not increasing'));
                } else {
                    vbs.push(varbinds[0]);
                    var next = { oid: varbinds[0].oid };
                    defaults(next, options);
                    self.getNext(next, result);
                }
            } else {
                clearTimeout(combinedTimeoutTimer);
                callback(null, vbs);
            }
        }
    }
function result(error, varbinds) {
        if (combinedTimeoutExpired) {
            return;
        }
        if (error) {
            clearTimeout(combinedTimeoutTimer);
            callback(error);
        } else {
            if (inTree(options.startOid, varbinds[0].oid)) {
                if (varbinds[0].value === 'endOfMibView' || varbinds[0].value === 'noSuchObject' || varbinds[0].value === 'noSuchInstance') {
                    clearTimeout(combinedTimeoutTimer);
                    callback(null, vbs);
                } else if (vbs.length && compareOids(vbs.slice(-1)[0].oid, varbinds[0].oid) !== 1) {
                    return callback(new Error('OID not increasing'));
                } else {
                    vbs.push(varbinds[0]);
                    var next = { oid: varbinds[0].oid };
                    defaults(next, options);
                    self.getNext(next, result);
                }
            } else {
                clearTimeout(combinedTimeoutTimer);
                callback(null, vbs);
            }
        }
    }
function result ( error , varbinds ) { if ( combinedTimeoutExpired ) { return ; } if ( error ) { clearTimeout ( combinedTimeoutTimer ) ; callback ( error ) ; } else { if ( inTree ( options . startOid , varbinds [ 0 ] . oid ) ) { if ( varbinds [ 0 ] . value === 'endOfMibView' || varbinds [ 0 ] . value === 'noSuchObject' || varbinds [ 0 ] . value === 'noSuchInstance' ) { clearTimeout ( combinedTimeoutTimer ) ; callback ( null , vbs ) ; } else if ( vbs . length && compareOids ( vbs . slice ( - 1 ) [ 0 ] . oid , varbinds [ 0 ] . oid ) !== 1 ) { return callback ( new Error ( 'OID not increasing' ) ) ; } else { vbs . push ( varbinds [ 0 ] ) ; var next = { oid : varbinds [ 0 ] . oid } ; defaults ( next , options ) ; self . getNext ( next , result ) ; } } else { clearTimeout ( combinedTimeoutTimer ) ; callback ( null , vbs ) ; } } }
Helper to handle the result of getNext and call the user's callback as appropriate. The callback will see one of the following patterns: - callback([an Error object], undefined) -- an error ocurred. - callback(null, [a Packet object]) -- data from under the tree. - callback(null, null) -- end of tree.
Helper to handle the result of getNext and call the user s callback as appropriate . The callback will see one of the following patterns : - callback ( [ an Error object ] undefined ) -- an error ocurred . - callback ( null [ a Packet object ] ) -- data from under the tree . - callback ( null null ) -- end of tree .