Robustness and the evolution of length control strategies in the T3SS and flagellar hook