aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp/src/agent/snmpa_mib_lib.erl
diff options
context:
space:
mode:
authorMicael Karlberg <[email protected]>2012-01-20 11:14:06 +0100
committerMicael Karlberg <[email protected]>2012-01-20 11:14:06 +0100
commitef4af949a1f946c965997957e10cb638e7d01c22 (patch)
tree60dd18f1c5709dd0c219d2adfd97b626dc25ca3a /lib/snmp/src/agent/snmpa_mib_lib.erl
parent65db6eb562b0376dd29fc60e9378d7b3b8ac386b (diff)
parenta1c84a9eb253f8b7aa5cdc8b88ca17691ed52c14 (diff)
downloadotp-ef4af949a1f946c965997957e10cb638e7d01c22.tar.gz
otp-ef4af949a1f946c965997957e10cb638e7d01c22.tar.bz2
otp-ef4af949a1f946c965997957e10cb638e7d01c22.zip
Merge branch 'bmk/snmp/agent/get_bulk_with_large_max_reps/OTP-9700' into bmk/snmp/snmp4173_integration/r13
Diffstat (limited to 'lib/snmp/src/agent/snmpa_mib_lib.erl')
-rw-r--r--lib/snmp/src/agent/snmpa_mib_lib.erl20
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/snmp/src/agent/snmpa_mib_lib.erl b/lib/snmp/src/agent/snmpa_mib_lib.erl
index 441228b9ee..ae94aca6d8 100644
--- a/lib/snmp/src/agent/snmpa_mib_lib.erl
+++ b/lib/snmp/src/agent/snmpa_mib_lib.erl
@@ -60,23 +60,23 @@ table_del_row({Tab, Db} = TabDb, Key) ->
get_table(NameDb, FOI) ->
(catch get_table(NameDb, FOI, [], [])).
-get_table(NameDb, FOI, Oid, Acc) ->
- case table_next(NameDb, Oid) of
+get_table(NameDb, FOI, Key, Acc) ->
+ case table_next(NameDb, Key) of
endOfTable ->
?vdebug("end of table",[]),
{ok, lists:reverse(Acc)};
- Oid ->
+ Key ->
%% Crap, circular ref
- ?vinfo("cyclic reference: ~w -> ~w", [Oid,Oid]),
- throw({error, {cyclic_db_reference, Oid, Acc}});
- NextOid ->
- ?vtrace("get row for oid ~w", [NextOid]),
- case table_get_row(NameDb, NextOid, FOI) of
+ ?vinfo("cyclic reference: ~w -> ~w", [Key, Key]),
+ throw({error, {cyclic_db_reference, Key, Acc}});
+ NextKey ->
+ ?vtrace("get row for key ~w", [NextKey]),
+ case table_get_row(NameDb, NextKey, FOI) of
undefined ->
- throw({error, {invalid_rowindex, NextOid, Acc}});
+ throw({error, {invalid_rowindex, NextKey, Acc}});
Row ->
?vtrace("row: ~w", [Row]),
- get_table(NameDb, FOI, NextOid, [{NextOid, Row}|Acc])
+ get_table(NameDb, FOI, NextKey, [{NextKey, Row}|Acc])
end
end.