* [devel] IQ: glob(3) change in glibc-2.3.4+
@ 2005-05-09 17:08 Dmitry V. Levin
2005-05-09 23:33 ` [devel] " Alexey Tourbin
0 siblings, 1 reply; 6+ messages in thread
From: Dmitry V. Levin @ 2005-05-09 17:08 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 964 bytes --]
Hi,
Возможно, вы уже знаете, что в glibc-2.3.4 было несовместимым образом
изменено поведение glob(3):
http://sources.redhat.com/ml/glibc-cvs/2004-q3/msg01233.html
http://sources.redhat.com/ml/glibc-cvs/2004-q3/msg01251.html
http://sources.redhat.com/bugzilla/show_bug.cgi?id=866
Есть приложения, которые сломаются.
Например, наш rpmbuild использует системный glob и с этим изменением не
сможет создавать пакеты с "висячими" ссылками (см. напр. gcc-common) без
специальных действий со стороны мантейнеров. RH'овский rpm использует
свой glob, взятый из glibc-2.1.x, и потому не подвержен этому изменению.
Для справки:
В SuSE-9.3 (glibc-2.3.4-23) это изменение откатили полностью.
В Fedora это изменение оставили полностью.
В связи с предстоящим на этой неделе появлением glibc-2.3.5 в Сизифе у
меня есть вопрос к тем из вас, у кого сложилось своё мнение на эту тему:
Как бы вы предложили поступить с этим изменением в glob?
--
ldv
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [devel] Re: IQ: glob(3) change in glibc-2.3.4+
2005-05-09 17:08 [devel] IQ: glob(3) change in glibc-2.3.4+ Dmitry V. Levin
@ 2005-05-09 23:33 ` Alexey Tourbin
2005-05-09 23:42 ` Dmitry V. Levin
0 siblings, 1 reply; 6+ messages in thread
From: Alexey Tourbin @ 2005-05-09 23:33 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 579 bytes --]
On Mon, May 09, 2005 at 09:08:18PM +0400, Dmitry V. Levin wrote:
> Например, наш rpmbuild использует системный glob и с этим изменением не
> сможет создавать пакеты с "висячими" ссылками (см. напр. gcc-common) без
(glob_in_dir): Don't blindly trust readdir results; for symlinks or
files of unknown type check using stat whether the file exists.
Дреппер исходит из того, что висячие симлинки -- это плохо.
Меж тем висячие симлинки вплоне законны, с ними веселее жить.
Новая версия glob(3) ущемляет права висячих симлинков!
(А что говорит SUSv3?)
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [devel] Re: IQ: glob(3) change in glibc-2.3.4+
2005-05-09 23:33 ` [devel] " Alexey Tourbin
@ 2005-05-09 23:42 ` Dmitry V. Levin
2005-05-10 0:33 ` Alexey Tourbin
0 siblings, 1 reply; 6+ messages in thread
From: Dmitry V. Levin @ 2005-05-09 23:42 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 1034 bytes --]
On Tue, May 10, 2005 at 03:33:22AM +0400, Alexey Tourbin wrote:
> On Mon, May 09, 2005 at 09:08:18PM +0400, Dmitry V. Levin wrote:
> > Например, наш rpmbuild использует системный glob и с этим изменением не
> > сможет создавать пакеты с "висячими" ссылками (см. напр. gcc-common) без
>
> (glob_in_dir): Don't blindly trust readdir results; for symlinks or
> files of unknown type check using stat whether the file exists.
>
> Дреппер исходит из того, что висячие симлинки -- это плохо.
> Меж тем висячие симлинки вплоне законны, с ними веселее жить.
> Новая версия glob(3) ущемляет права висячих симлинков!
Ничего подобного, симлинки могут продолжать висеть столько, сколько им
будет угодно. Зато новая версия glob(3) ущемляет права пользователей
висячих симлинков.
> (А что говорит SUSv3?)
"The glob() function shall match all accessible pathnames against this
pattern and develop a list of all pathnames that match."
Термин accessible Drepper трактует достаточно вольно.
--
ldv
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [devel] Re: IQ: glob(3) change in glibc-2.3.4+
2005-05-09 23:42 ` Dmitry V. Levin
@ 2005-05-10 0:33 ` Alexey Tourbin
2005-05-10 0:50 ` Alexey Tourbin
2005-05-10 1:09 ` Alexey Tourbin
0 siblings, 2 replies; 6+ messages in thread
From: Alexey Tourbin @ 2005-05-10 0:33 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 846 bytes --]
On Tue, May 10, 2005 at 03:42:27AM +0400, Dmitry V. Levin wrote:
> > (А что говорит SUSv3?)
>
> "The glob() function shall match all accessible pathnames against this
> pattern and develop a list of all pathnames that match."
Accessible *pathnames*, а не сами объекты файловой системы, которые
скрываются за pathnames. По-моему, accessible здесь связано с pattern,
т.е. "доступные через данный шаблон", а не доступные или недоступные
вообще.
> Термин accessible Drepper трактует достаточно вольно.
Тогда нужно также проверять, что права доступа отличны от нуля и т.п.
Нужно записать термин accessible на псевдокоде.
for f in *; do
if [ -L "$f" -a ! -e "$f" ]; then
contitune
fi
if [ -f "$f" -a ! -r "$f" ]; then
continue
fi
if [ -d "$f" -a ! -x "$f" ]; then
continue
fi
echo "$f"
done
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [devel] Re: IQ: glob(3) change in glibc-2.3.4+
2005-05-10 0:33 ` Alexey Tourbin
@ 2005-05-10 0:50 ` Alexey Tourbin
2005-05-10 1:09 ` Alexey Tourbin
1 sibling, 0 replies; 6+ messages in thread
From: Alexey Tourbin @ 2005-05-10 0:50 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 1162 bytes --]
On Tue, May 10, 2005 at 04:33:49AM +0400, Alexey Tourbin wrote:
> On Tue, May 10, 2005 at 03:42:27AM +0400, Dmitry V. Levin wrote:
> > > (А что говорит SUSv3?)
> >
> > "The glob() function shall match all accessible pathnames against this
> > pattern and develop a list of all pathnames that match."
>
> Accessible *pathnames*, а не сами объекты файловой системы, которые
> скрываются за pathnames. По-моему, accessible здесь связано с pattern,
> т.е. "доступные через данный шаблон", а не доступные или недоступные
> вообще.
Между прочим, в симлинках можно хранить произвольную информацию:
$ ln -s "$(</etc/motd)" foo
$ readlink foo
_ _ _____ _ _ ____ _ _
/ \ | | |_ _| | | (_)_ __ _ ___ __ / ___|(_)___ _ _ _ __ | |__ _ _ ___
/ _ \ | | | | | | | | '_ \| | | \ \/ / \___ \| / __| | | | '_ \| '_ \| | | / __|
/ ___ \| |___| | | |___| | | | | |_| |> < ___) | \__ \ |_| | |_) | | | | |_| \__ \
/_/ \_\_____|_| |_____|_|_| |_|\__,_/_/\_\ |____/|_|___/\__, | .__/|_| |_|\__,_|___/
|___/|_|
$
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* [devel] Re: IQ: glob(3) change in glibc-2.3.4+
2005-05-10 0:33 ` Alexey Tourbin
2005-05-10 0:50 ` Alexey Tourbin
@ 2005-05-10 1:09 ` Alexey Tourbin
1 sibling, 0 replies; 6+ messages in thread
From: Alexey Tourbin @ 2005-05-10 1:09 UTC (permalink / raw)
To: ALT Devel discussion list
[-- Attachment #1: Type: text/plain, Size: 549 bytes --]
On Tue, May 10, 2005 at 04:33:49AM +0400, Alexey Tourbin wrote:
> On Tue, May 10, 2005 at 03:42:27AM +0400, Dmitry V. Levin wrote:
> > > (А что говорит SUSv3?)
> >
> > "The glob() function shall match all accessible pathnames against this
> > pattern and develop a list of all pathnames that match."
>
> Accessible *pathnames*, а не сами объекты файловой системы, которые
> скрываются за pathnames. По-моему, accessible здесь связано с pattern,
> т.е. "доступные через данный шаблон", а не доступные или недоступные
Нет, не связано.
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2005-05-10 1:09 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-09 17:08 [devel] IQ: glob(3) change in glibc-2.3.4+ Dmitry V. Levin
2005-05-09 23:33 ` [devel] " Alexey Tourbin
2005-05-09 23:42 ` Dmitry V. Levin
2005-05-10 0:33 ` Alexey Tourbin
2005-05-10 0:50 ` Alexey Tourbin
2005-05-10 1:09 ` Alexey Tourbin
ALT Linux Team development discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/devel/0 devel/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 devel devel/ http://lore.altlinux.org/devel \
devel@altlinux.org devel@altlinux.ru devel@lists.altlinux.org devel@lists.altlinux.ru devel@linux.iplabs.ru mandrake-russian@linuxteam.iplabs.ru sisyphus@linuxteam.iplabs.ru
public-inbox-index devel
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.devel
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git