Handle case where string has length 0 #3573