fixed the error string
now we only allocate more memory if we need it