]> sourceware.org Git - libabigail.git/commit
Fix symlinks paths handling in abipkgdiff
authorDodji Seketeli <dodji@redhat.com>
Fri, 12 Jan 2018 12:38:01 +0000 (13:38 +0100)
committerDodji Seketeli <dodji@redhat.com>
Fri, 12 Jan 2018 12:38:01 +0000 (13:38 +0100)
commit3001e78a4f2d92d52800772a21e835bfa5803cfa
tree4d161d55320802eb8752835a3ac0e584f644f0dd
parentd2c759c4d7d31a75a8cc8edb74bc112c043b97b8
Fix symlinks paths handling in abipkgdiff

When elements of an RPMs are referred to using a path that contains
symlinks, we need to resolve the symlinks in order to be able to
compare those paths.  We are not doing this fully and so we are
hitting corner cases where things break down in subtle ways.

This patch fixes that.

* include/abg-tools-utils.h (real_path): Declare new function.
* src/abg-tools-utils.cc (real_path): Define it.
* tools/abipkgdiff.cc (package::convert_path_to_relative): Use the
new real_path function to consider real path (where symlinks are
resolved) of the extraction directory of the package.
(get_interesting_files_under_dir): Similarly, use the new
real_path function to consider the real path of the directory we
are exploring.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
include/abg-tools-utils.h
src/abg-tools-utils.cc
tools/abipkgdiff.cc
This page took 0.029841 seconds and 5 git commands to generate.