public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Carlos O'Donell <carlos@redhat.com>
To: Renzo Davoli <renzo@cs.unibo.it>, Zack Weinberg <zackw@panix.com>
Cc: Florian Weimer <fweimer@redhat.com>,
	GNU C Library <libc-alpha@sourceware.org>
Subject: Re: [PATCH] resolv/resolv.h: allow alternative resolv.conf files
Date: Thu, 17 Aug 2017 15:21:00 -0000	[thread overview]
Message-ID: <272cb460-1ac0-91e3-0def-3c5ad3f08e25@redhat.com> (raw)
In-Reply-To: <20170817143231.6cafq26aqlhvcazi@cs.unibo.it>

On 08/17/2017 10:32 AM, Renzo Davoli wrote:
>> _PATH_RESCONF really has to be a string literal, and you can't use a GNU
>> C extension in such a way in an installed header file.
>>
>> The environment variable would have to be ignored in AT_SECURE mode, so
>> you have to use __libc_secure_getenv or put it into unsecvars.h.
> 
> Here is a different implementation:
> * it does not use any gcc extension
> * use __libc_secure_getenv instead of getenv
> * do not change installed header files.

You ask:

"Why to obtain a so simple feature should I have to overlay mount /etc?"

and the answer is:

* It complicates the glibc design when an overlay mount already exists.

* Environment variables are brittle and may be cleared in certain
  or unused in certain circumstances.

The most robust solution is an overlay mount in /etc.

Is there anything technically wrong with the overlay mount?

The overlay mount is semantically clearer than another env var that
changes existing behaviour.

-- 
Cheers,
Carlos.

  reply	other threads:[~2017-08-17 15:21 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-17 11:50 Renzo Davoli
2017-08-17 12:41 ` Florian Weimer
2017-08-17 13:14   ` Zack Weinberg
2017-08-17 13:59     ` Renzo Davoli
2017-08-17 14:32       ` Renzo Davoli
2017-08-17 15:21         ` Carlos O'Donell [this message]
2017-08-17 16:18           ` Renzo Davoli
2017-08-17 16:25             ` Florian Weimer
2017-08-17 16:49               ` Szabolcs Nagy
2017-08-17 16:55                 ` Florian Weimer
2017-08-17 16:13         ` Florian Weimer
2017-08-18 15:08           ` Renzo Davoli
2017-08-18 16:41             ` Carlos O'Donell
2017-08-22  9:37               ` Renzo Davoli
2017-08-23  4:07                 ` Carlos O'Donell
2017-09-18 15:12 ` Florian Weimer
2017-09-18 15:27   ` Carlos O'Donell

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=272cb460-1ac0-91e3-0def-3c5ad3f08e25@redhat.com \
    --to=carlos@redhat.com \
    --cc=fweimer@redhat.com \
    --cc=libc-alpha@sourceware.org \
    --cc=renzo@cs.unibo.it \
    --cc=zackw@panix.com \
    /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).