Better Null Checking (PR for CI testing)

Some cleanup on the string-based TCP algorithm to reduce reprocessing of null-searched string segments.