Read from stdin if available.