On Nov 2, 2007, at 8:07 AM, Jeff Johnson wrote:
>
> On Nov 2, 2007, at 6:10 AM, Arkadiusz Miskiewicz wrote:
>
>> On Friday 02 of November 2007, Jeff Johnson wrote:
>>
>>> ====================================================================
>>> =======
>>> = $ cvs diff -u -r1.195 -r1.196 rpmdb.c
>>> --- rpm/rpmdb/rpmdb.c 22 Oct 2007 02:48:42 -0000 1.195
>>> +++ rpm/rpmdb/rpmdb.c 2 Nov 2007 03:07:46 -0000 1.196
>>> @@ -3917,7 +3917,7 @@
>>> }
>>> dbpath = rootdbpath = rpmGetPath(prefix, tfn, NULL);
>>> if (!(prefix[0] == '/' && prefix[1] == '\0'))
>>> - dbpath += strlen(prefix) - 1;
>>> + dbpath += strlen(prefix);
>>> tfn = _free(tfn);
>>
>> It looks like this part is changed over and over, adding -1,
>> stripping -1
>> http://rpm5.org/cvs/filediff?f=rpm/rpmdb/rpmdb.c&v1=1.127&v2=1.128
>>
>> Backporting and testing...
>
> Likely.
>
> Again, this command has never been well implemented
> rpm --rebuilddb --root /q
>
> The --root command became all mode, not just install modes,
> rather than inventing alternative per-mode alternative option
> names.
>
> The flip-flops are likely with trailing '/' on path afaict (and
> recall).
>
Either -1 needs adding, or this needs doing:
prefix = rpmGetPath(prefix, NULL); /* strip trailing '/' */
The reversions likely happened when I occaisionally try for URL's in
dbpath.
E.g.
rpm --rebuilddb --dbpath file:///q/var/lib/rpm
or when trying for multiple colon separated database paths, including
URL's.
hth the testing
73 de Jeff
Received on Fri Nov 2 13:25:23 2007