From: Siddhesh Poyarekar <siddhesh@sourceware.org>
To: Adhemerval Zanella <adhemerval.zanella@linaro.org>,
libc-alpha@sourceware.org
Subject: Re: [PATCH] ldconfig: Fix memory leaks
Date: Wed, 19 May 2021 19:33:52 +0530 [thread overview]
Message-ID: <b154be12-e134-0f92-2982-c485e31bd443@sourceware.org> (raw)
In-Reply-To: <7915a19a-ef20-f416-f849-83b23faae5c8@linaro.org>
On 5/19/21 7:24 PM, Adhemerval Zanella wrote:
> It would be straightforward change, but I think there is no much gain in
> either supporting a path larger than PATH_MAX (it might fail in later
> usages anyway if the full path is used) or trying to add the optimization
> of just resolving the PATH.
I don't think it can support paths larger than PATH_MAX because the
later lstat64 will fail with ENAMETOOLONG.
> What I really dislike is that chroot_canon is quite similar to the old
> realpath implementation we had, and analyzing its usage I think we can
> just resolve the full path ([chroot,path]) with realpath instead of
> call chroot_canon. It would require more changes in ldconfig code
> though.
I think your patch with the changes I suggested ought to be a sufficient
minimal change. Do you want to fix up and post?
Siddhesh
next prev parent reply other threads:[~2021-05-19 15:23 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-11 17:16 Siddhesh Poyarekar
2021-05-17 16:00 ` [PING][PATCH] " Siddhesh Poyarekar
2021-05-17 17:15 ` [PATCH] " Adhemerval Zanella
2021-05-18 3:43 ` Siddhesh Poyarekar
2021-05-18 4:49 ` Siddhesh Poyarekar
2021-05-18 4:52 ` Siddhesh Poyarekar
2021-05-18 13:08 ` Adhemerval Zanella
2021-05-19 4:24 ` Siddhesh Poyarekar
2021-05-19 13:54 ` Adhemerval Zanella
2021-05-19 14:03 ` Siddhesh Poyarekar [this message]
2021-05-19 14:22 ` Adhemerval Zanella
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b154be12-e134-0f92-2982-c485e31bd443@sourceware.org \
--to=siddhesh@sourceware.org \
--cc=adhemerval.zanella@linaro.org \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).