[Patch] Fix a path problem with registry related ldb

Matthieu Patou mat+Informatique.Samba at matws.net
Wed Apr 7 09:37:02 MDT 2010


On 07/04/2010 16:43, Matthias Dieter Wallnöfer wrote:
> No, Matthieu - this patch isn't right. The provision calls 
> "setup_registry" with the registry LDB file names as argument without 
> path specification. This method calls "registry.open_ldb" (you can 
> find it in "pyregistry.c") which is basically a wrapper for 
> "ldb_wrap_connect" (the standard s4 LDB opener). Here the interesting 
> part (the path is called "url" in this call):
>
> line 204 >         real_url = private_path(ldb, lp_ctx, url);
>
> You see that the file name is enhanced with the private directory as 
> prefix and so the path specification fits. Therefore your problem with 
> the registry LDB files in the current folder lies elsewhere (maybe a 
> wrong configure?).
>
Well actually it's upgrade provision that is spawning ldb files 
everywhere ... I'll fix it upgradeprovision if provision is ok ... 
although a bit of uniformity would do no harm ...

Maybe we can do something clever like not prepending private_path if the 
path already start with a "/"
> Matthias
>
> Matthieu Patou wrote:
>> Hello,
>>
>> I found that the provision_paths_from_lp return paths for registry 
>> related ldb (hkcu.ldb ... ) without parent folder which leads to 
>> creation of ldb files in the current folder when they are used.
>>
>> The attached patch fix this.
>>
>> Matthieu
>
Matthieu.


More information about the samba-technical mailing list