Ensure data segment size is never negative