[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Usher pattern matching (was Re: [Monotone-devel] Usher crashes)
From: |
Timothy Brownawell |
Subject: |
Re: Usher pattern matching (was Re: [Monotone-devel] Usher crashes) |
Date: |
Sat, 13 May 2006 23:19:19 -0500 |
On Sat, 2006-05-13 at 23:29 -0300, Jeronimo Pellegrini wrote:
> OK, I'll compile the problems I found before:
>
> > If I use:
>
> > server "main"
> > host "localhost"
> > pattern "info.aleph0"
> > local "-d" "/home/jeronimo/monotone/main.db" "*"
>
> > And try to sync brahch info.aleph0.my_branch
>
> It won't work.
>
> > Neither if I try:
> > pattern "info.aleph0.*"
>
> > But if I use:
> > pattern "info.aleph0.my_branch"
>
> It works, but only if I fix line 185 of server_manager::connect_to_server
> where it matches pattern against host:
>
> if (!srv && !pattern.empty() && !by_pattern.empty())
> {
> i = by_pattern.lower_bound(pattern);
> if (i != by_pattern.end() && i->first == prefix(host))
> ^^^^
Um, that should be fixed now.
> And even if I try to make it match against pattern, it fails,
> because of the way operator== works for struct prefix. Is this
> intentional? Shouldn't it also do partial matches?
It should, and I think now it does.
As you can probably tell, this hasn't exactly had extensive testing
since being reorganized. ;-p
Tim