From 097752bcb135407f404fd8b6478a31b1e24a7f97 Mon Sep 17 00:00:00 2001 From: Evgeny Zinoviev Date: Tue, 9 Feb 2021 20:18:05 +0300 Subject: fix --- get_mbp101_ramcfg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'get_mbp101_ramcfg') diff --git a/get_mbp101_ramcfg b/get_mbp101_ramcfg index 0eef4e5..7cead1e 100755 --- a/get_mbp101_ramcfg +++ b/get_mbp101_ramcfg @@ -40,7 +40,7 @@ def main(): # reverse bit order ramcfg = int('{:04b}'.format(ramcfg)[::-1], 2) - if ramcfg > len(ramconfigs): + if ramcfg >= len(ramconfigs): print("unsupported memory configuration %d" % ramcfg) else: print(ramconfigs[ramcfg]) -- cgit v1.2.3