diff options
| author | Josef Gustafsson <josef.gson@gmail.com> | 2015-09-10 16:02:44 +0200 |
|---|---|---|
| committer | Josef Gustafsson <josef.gson@gmail.com> | 2015-09-10 16:02:44 +0200 |
| commit | f915c0883091bc63a800f1e264608d14fe94fd64 (patch) | |
| tree | 92fac8388d5749f25ecfb42bc30c43653c79c0b6 /monitor/josef_leveldb.py | |
| parent | fba1ff8104fbe21b3ab647b2dc7cdb7a64a3bf70 (diff) | |
bugfix: finding data when looking in multiple domains
Diffstat (limited to 'monitor/josef_leveldb.py')
| -rwxr-xr-x | monitor/josef_leveldb.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/monitor/josef_leveldb.py b/monitor/josef_leveldb.py index ac96211..23ca90f 100755 --- a/monitor/josef_leveldb.py +++ b/monitor/josef_leveldb.py @@ -67,8 +67,10 @@ def db_add_domain(db, domain, data): next_k = item else: next_k = item + '.' + k + # print "Appending ", k, next_k db_append(db, k, next_k) k = next_k + # print "Appending ", k, data db_append(db, k, data) @@ -109,9 +111,11 @@ def db_lookup_domain(db, domain): return res # Prune next_level = [] + print intermediate for item in intermediate: + print cur_domain, item if match_domain(cur_domain, item): - # print item + print item try: tmp = db.Get(item) if tmp[1] == '{': @@ -121,8 +125,8 @@ def db_lookup_domain(db, domain): # print "Could not find " + item pass - else: - intermediate.remove(item) + # else: + # intermediate.remove(item) intermediate = next_level return res |
