From b91b15299e81cfeef78ebe11634d2cd7f4558553 Mon Sep 17 00:00:00 2001 From: midipix Date: Thu, 21 Jun 2018 14:56:15 -0400 Subject: link mode: slbt_archive_import(): properly detect placeholder symlinks. --- src/helper/slbt_archive_import.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/helper/slbt_archive_import.c b/src/helper/slbt_archive_import.c index c45efa4..12fd68c 100644 --- a/src/helper/slbt_archive_import.c +++ b/src/helper/slbt_archive_import.c @@ -14,6 +14,7 @@ #include #include "slibtool_spawn_impl.h" +#include "slibtool_symlink_impl.h" #include "slibtool_readlink_impl.h" #include "slibtool_errinfo_impl.h" @@ -89,9 +90,8 @@ int slbt_archive_import( char mrisrc [L_tmpnam]; char program[PATH_MAX]; - if (!slbt_readlink(srcarchive,program,sizeof(program))) - if (!(strcmp(program,"/dev/null"))) - return 0; + if (slbt_symlink_is_a_placeholder(srcarchive)) + return 0; if ((size_t)snprintf(program,sizeof(program),"%s", dctx->cctx->host.ar) >= sizeof(program)) -- cgit v1.2.3