ALT Linux Team development discussions
 help / color / mirror / Atom feed
From: "Dmitry V. Levin" <ldv@altlinux.org>
To: ALT Linux Team development discussions <devel@lists.altlinux.org>
Subject: Re: [devel] I: gcc 6.3.1 && binutils 2.27.0
Date: Wed, 25 Jan 2017 10:54:27 +0300
Message-ID: <20170125075427.GB23779@altlinux.org> (raw)
In-Reply-To: <CA+qzen=WmyKqCb4uBQc1thUznNTS3b9s2NqLt-Jc+=z8haLF2w@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1040 bytes --]

On Wed, Jan 25, 2017 at 09:40:14AM +0300, Alexey Tourbin wrote:
> 2017-01-16 14:48 GMT+03:00 Dmitry V. Levin <ldv@altlinux.org>:
> > Hi,
> >
> > On Mon, Jan 16, 2017 at 01:22:24AM +0300, Alexey Tourbin wrote:
> > [...]
> >> Ну например, из очень старого кода, который оказывается и не я
> >> написал, а он мне снится по ночам:
> >>
> >>                 /* XXX diff may overflow short int */
> >>                 char    buf[3] = { (char) 0x80, (char) (diff >> 8),
> >> (char) diff };
> >>
> >> http://git.altlinux.org/people/at/packages/slocate.git?p=slocate.git;a=commitdiff;h=82eb736e
> >>
> >> Насколько легальна здесь инициализация buf[0] = (char) 0x80? Это уже вышка?
> >
> > Что же это получается, may overflow, стало быть, вас не беспокоит,
> > а (char) 0x80 беспокоит?
> 
> На практике diff = lcp(path0,path1) - lcp(path1,path2), где lcp -
> общий префикс, ограничивается сверху и снизу значением PATH_MAX =
> 4096.  То есть это немного разные виды беспокойств.

Бывают пути длиннее PATH_MAX.


-- 
ldv

[-- Attachment #2: Type: application/pgp-signature, Size: 801 bytes --]

      reply	other threads:[~2017-01-25  7:54 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-13 15:13 Gleb Fotengauer-Malinovskiy
2017-01-14 14:28 ` Антон Мидюков
2017-01-15  9:50   ` Sergey Y. Afonin
2017-01-15 10:03     ` Антон Мидюков
2017-01-15 10:19       ` Hihin Ruslan
2017-01-15 11:30   ` Dmitry V. Levin
2017-01-15 11:49     ` Антон Мидюков
2017-01-15 11:53       ` Sergey Y. Afonin
2017-01-15 20:29       ` Michael Shigorin
2017-01-15 22:22 ` Alexey Tourbin
2017-01-16 11:48   ` Dmitry V. Levin
2017-01-25  6:40     ` Alexey Tourbin
2017-01-25  7:54       ` Dmitry V. Levin [this message]

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=20170125075427.GB23779@altlinux.org \
    --to=ldv@altlinux.org \
    --cc=devel@lists.altlinux.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

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