Mailing List Archive

bug in brancid handling of prompts
I have just come across a bug in the handling of the prompt in brancid. It occurs
when handling prompts with 'special' characters in them such as [UK-ISP1]>

I found that rrancid already had code to handle it so the following diff against
brancid should fix the problem.

172a173
> $prompt =~ s/([][])/\\$1/g;
235c236,239
< if (!defined($prompt)) {$prompt = ($_ =~ /^([^>]+>)/)[0]; }
---
> if (!defined($prompt)) {
> $prompt = ($_ =~ /^([^>]+>)/)[0];
> $prompt =~ s/([][])/\\$1/g;
> }

HTH

Mark