1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-08-13 17:03:46 -04:00
pacman/lib
Xavier Chantry 0966c33a72 Get rid of double / in database paths.
Errors like the following one happen regularly (for unknown reasons...) :
error: could not open file /var/lib/pacman/local//glibc-2.7-9/depends: No
such file or directory

Anyway, every time an user reported an error like that, it always seemed
like he thought the error was caused by the double /, which is obviously
wrong.

Since db->path always include a trailing /, there is no need to add one when
concatenating paths in be_files.c or add.c.
Additionally, some static strings were switched to dynamic.
And the computation of the "dbpath"/"pkgname"-"pkgversion" was refactored
in db_read, db_write and db_remove with a get_pkgpath static function.

Signed-off-by: Xavier Chantry <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-06-04 16:25:27 -05:00
..
libalpm Get rid of double / in database paths. 2008-06-04 16:25:27 -05:00