Fix command-line parsing with --keepalive.