pkgtools

morpheus pkg tools
git clone git://git.2f30.org/pkgtools
Log | Files | Refs | README | LICENSE

commit 83de33262adf03d1c5057bd84f8d9d7b9fc47b09
parent 6f31da9325d09fac22a67a8a2b6b32ca04d1b996
Author: sin <sin@2f30.org>
Date:   Tue, 24 Jun 2014 15:01:18 +0100

Avoid using realpath() for pkg loading

Diffstat:
Mdb.c | 6++----
1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/db.c b/db.c @@ -248,8 +248,7 @@ pkg_load(struct db *db, const char *filename) estrlcpy(path, db->prefix, sizeof(path)); estrlcat(path, "/", sizeof(path)); estrlcat(path, buf, sizeof(path)); - if(!realpath(path, pe->path)) - estrlcpy(pe->path, path, sizeof(pe->path)); + estrlcpy(pe->path, path, sizeof(pe->path)); estrlcpy(pe->rpath, buf, sizeof(pe->rpath)); TAILQ_INSERT_TAIL(&pkg->pe_head, pe, entry); } @@ -316,8 +315,7 @@ pkg_load_file(struct db *db, const char *filename) estrlcat(path, "/", sizeof(path)); estrlcat(path, archive_entry_pathname(entry), sizeof(path)); - if(!realpath(path, pe->path)) - estrlcpy(pe->path, path, sizeof(pe->path)); + estrlcpy(pe->path, path, sizeof(pe->path)); estrlcpy(pe->rpath, archive_entry_pathname(entry), sizeof(pe->rpath)); TAILQ_INSERT_TAIL(&pkg->pe_head, pe, entry);