AC: Fix infinite loop when no typed-text is available (fixes #56).