Read buffer overflow fix.