From owner-freebsd-bugs@FreeBSD.ORG Mon Sep 17 15:40:11 2012 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D0ACC1065670 for ; Mon, 17 Sep 2012 15:40:11 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id BB6A68FC0A for ; Mon, 17 Sep 2012 15:40:11 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q8HFeBLh051621 for ; Mon, 17 Sep 2012 15:40:11 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q8HFeB1B051620; Mon, 17 Sep 2012 15:40:11 GMT (envelope-from gnats) Date: Mon, 17 Sep 2012 15:40:11 GMT Message-Id: <201209171540.q8HFeB1B051620@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Andrey Simonenko Cc: Subject: bin/171604: [patch] LD_PRELOAD set to not absolute path crashes rtld X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Andrey Simonenko List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2012 15:40:11 -0000 The following reply was made to PR bin/171604; it has been noted by GNATS. From: Andrey Simonenko To: bug-followup@FreeBSD.org Cc: Mark Johnston Subject: bin/171604: [patch] LD_PRELOAD set to not absolute path crashes rtld Date: Mon, 17 Sep 2012 18:30:53 +0300 > Ok, so that fixed the segfault at least. I think the LD_PRELOAD handling > is still incorrect. According to rtld(1), if LD_PRELOAD isn't an > absolute path, then LD_LIBRARY_PATH and the standard library path > (/lib:/usr/lib) should be searched. However, we're only searching > LD_LIBRARY_PATH in this case at the moment: That manual page references to "built-in standard directories", but does not define what they are. Previously LD_PRELOAD set to not absolute path worked even for /usr/local/lib (as I understand because of ldconfig called for that directory). I notice that net/proxychains that worked before on RELENG_9 did not work now (it calls any program with LD_PRELOAD=libproxychains.so, just install it and check shell script at bin/proxychains). > The attached patch addresses this problem as well. Yes, it works for /lib at least.