[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: general aliasing



Will,

I just made a quick scan of your code and I can't see how you include any
subtrees that are referenced by aliases within the scope of the orignal
search. For example, given

                                a=1
                               /   \
                              /     \
                             /       \
                            /         \
                         b=1           b=2
                        /   \         /   \
                       /     \       /     \
                      c=1   c=2     c=3   c=4
                     /   \
                    /     \
                   d=1   d=2

If you're doing a subtree-scope search of base of "b=1" (I'll just use RDNs
for shorthand) and "d=2" is an alias for "b=2" then you have to include the
"b=2" subtree in the original search. This is what I was referring to when
I talked about modifying the search filter. You have to first find all
of the aliases within the scope of "base," find any additional vertices
that need to be included in the search, and then "or" in scoping filters
for the additional vertices. This means that you also have to change the
scoping tests when verifying the candidates.

I also noticed at least one memory leak where you dup "base" into "realBase"
and then later assign to realBase without freeing the duped string.

Since you were working with suffixes, maybe you can answer a question for
me. I don't see why in subtree_candidates() it doesn't add a scoping filter
if "base" is a suffix. Do you know the logic behind this?

I'd like to gather up all of the aliases within ldbm_back_search(), but since
I want to reuse the scoping filters created in the xx_candidate() searches
I may not be able to do this anyway. Either way, I'd like to understand the
logic behind this one.

bob

Robert Streich			streich@slb.com
Schlumberger			512-331-3318 (voice)
Austin Research			512-331-3760 (fax)