Tighten nullptr safety for base_string.
Fix strdup behavior on nullptr.