diff --git a/edosl0util/crio.py b/edosl0util/crio.py
index e308b87f811bdbf5263baa43418f9771d905cfd3..c125c406f1b6e9bbc311e87caddba65adb8ce218 100644
--- a/edosl0util/crio.py
+++ b/edosl0util/crio.py
@@ -2,6 +2,7 @@
 """PDS construction record input and output"""
 
 import ctypes as c
+import numbers
 from edosl0util.headers import BaseStruct, DaySegmentedTimecode
 
 
@@ -50,8 +51,7 @@ def read(cr_file):
     def read_struct(f, struct):
         rv = struct_to_dict(struct.from_buffer_copy(f.read(c.sizeof(struct))))
         rv = {k: v for k, v in rv.items() if not k.startswith('spare_')}  # no spare fields
-        return {k: int(v) if isinstance(v, long) else v for k, v in rv.items()}  # no longs
-
+        return {k: int(v) if isinstance(v, numbers.Integral) else v for k, v in rv.items()}  # no longs
     return main()