small fixes

While trying out parse_rng.py, I wrote these small fixes.