Fixed invalid reads