From MAILER-DAEMON Thu Jun 01 20:43:02 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGag9-0005Hi-Us
	for mharc-bug-bash@gnu.org; Thu, 01 Jun 2017 20:43:01 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44838)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGag8-0005Hc-2n
	for bug-bash@gnu.org; Thu, 01 Jun 2017 20:43:00 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGag4-00088m-3O
	for bug-bash@gnu.org; Thu, 01 Jun 2017 20:43:00 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:35998
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dGag3-00084Z-Or
	for bug-bash@gnu.org; Thu, 01 Jun 2017 20:42:56 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v520gmgG091445 for <bug-bash@gnu.org>; Thu, 1 Jun 2017 17:42:50 -0700
Message-ID: <5930B488.7020605@tlinx.org>
Date: Thu, 01 Jun 2017 17:42:48 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
Subject: RFE: Please allow unicode ID chars in identifiers 
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 00:43:01 -0000

It would be a useful upgrade besides being a "good world citizen" ;-).

For ID's, anyway, I think checking the 'ID Continue' binary property
would be the minimum.  Could get more precise and check that
'ID Start' is set for chars starting an ID (that disallows
numbers, as being the start of an ID), though the IDstart
property also disallows '_' (underscore) which would need to be
added back for many computer languages.

I'm guessing that if POSIX was set, then they'd be limited
to the ASCII (American Standard Code for Information Interchange)
set.  ;^)

Thanks much!
-Linda






From MAILER-DAEMON Thu Jun 01 23:57:12 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGdi4-0000hV-Qu
	for mharc-bug-bash@gnu.org; Thu, 01 Jun 2017 23:57:12 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43287)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGdi2-0000hG-I4
	for bug-bash@gnu.org; Thu, 01 Jun 2017 23:57:11 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGdi1-00019S-RN
	for bug-bash@gnu.org; Thu, 01 Jun 2017 23:57:10 -0400
Received: from mail-qk0-x232.google.com ([2607:f8b0:400d:c09::232]:33125)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dGdi1-00018g-Jt
	for bug-bash@gnu.org; Thu, 01 Jun 2017 23:57:09 -0400
Received: by mail-qk0-x232.google.com with SMTP id y201so51607452qka.0
	for <bug-bash@gnu.org>; Thu, 01 Jun 2017 20:57:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=BR2JCSgg7JmwZWXCQKEX7RkK2VfGMyItFbHn//cISUE=;
	b=tAgKa24lsYtl1gmCMEScJN5vjdmD2lu77MBo17LoZqC3pqlma7iRbTfifVoozYBG0u
	X8AL83H/4qqI4T90fsWNl4h63e0fT3clBaNRCHtbx4itH/u9Gilm9fzSF4tQBmtbRGuu
	AOgWRQiiKpzpt+/5wkYtrrEiRAL1Zg7PM31AKjTQ1PG9UoTbKD0x4518t3rjK53s6Mrl
	HctmyKhCxU7Dqktbzy7EVkT4AZS7M9+Cj0wH9n0MOE16B06NEoJr3V5hK4YiShQhys8P
	SsizLtuczs71l4TSY7aXhtIxTxi6r9kH9amFw9WhS0ChrhwpcxlxDDKiDDoIBhtPWHqS
	Ar3g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=BR2JCSgg7JmwZWXCQKEX7RkK2VfGMyItFbHn//cISUE=;
	b=dtSO+phDB7QqFKsJ8tKCTCJX89FFTXUnEVFfZIwRLq+KmxpGyYqK2szuOK+XYJmoS7
	zRsuiqPNTvJJBHkGORxhTIaNdmXZ3Zp0A/nLEFq2OzntFPBm1vJzCTmlDxu5dwD/r+89
	zxa84P8VR2oJHQ51gcLyfZ3hQ1j4xGesTuQXeWmtFB8d5J55JPC1h9y/izanri3xSq96
	cRmIbN1BAMtNOgus96y90/g2Er4MA0uOos52lbEBdrFxDtV0fvmf0ufXmeCllHG7zsXN
	eWixMwQWe+PQ0MPOIbZfQWuMP3unXTesN9m5Zzej9X5TYIEtFCmzK5yO1hOMUW6DVJU2
	152Q==
X-Gm-Message-State: AKS2vOzWpELSohKPslSeKryAbGbWItgWnHjk6iKktc0rkIujaphxhoXl
	oHE+iwob9ugC+pnhzdoRybK57v60Ew==
X-Received: by 10.55.38.2 with SMTP id y2mr5626795qkg.188.1496375827161; Thu,
	01 Jun 2017 20:57:07 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.178.25 with HTTP; Thu, 1 Jun 2017 20:56:46 -0700 (PDT)
In-Reply-To: <5930B488.7020605@tlinx.org>
References: <5930B488.7020605@tlinx.org>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Thu, 1 Jun 2017 22:56:46 -0500
Message-ID: <CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
Cc: bug-bash <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 03:57:11 -0000

On Thu, Jun 1, 2017 at 7:42 PM, L A Walsh <bash@tlinx.org> wrote:
> It would be a useful upgrade besides being a "good world citizen" ;-).
[...]

I honestly fail to see the usefulness of such upgrade. It'll just
increase the complexity of the parser, to get what, emojis?

Do you have an example of something that absolutely needs Unicode and
cannot be achieved by the current state of affairs? (an actual real
world use case)


From MAILER-DAEMON Fri Jun 02 00:31:37 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGeFN-0007LE-R5
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 00:31:37 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54304)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGeFL-0007L8-Qh
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:31:36 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGeFI-0002xV-Kk
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:31:35 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:44886
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dGeFI-0002wa-CP
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:31:32 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v524VO9l005814; Thu, 1 Jun 2017 21:31:26 -0700
Message-ID: <5930EA1C.5090100@tlinx.org>
Date: Thu, 01 Jun 2017 21:31:24 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
CC: Eduardo Bustamante <dualbus@gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
In-Reply-To: <CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v524VO9l005814
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 04:31:37 -0000



Eduardo Bustamante wrote:
> On Thu, Jun 1, 2017 at 7:42 PM, L A Walsh <bash@tlinx.org> wrote:
>  =20
>> It would be a useful upgrade besides being a "good world citizen" ;-).
>>    =20
> [...]
>
> I honestly fail to see the usefulness of such upgrade. It'll just
> increase the complexity of the parser, to get what, emojis?
>  =20
----
    emojis?   Those wouldn't work. They aren't ID-type
characters.  Large
> Do you have an example of something that absolutely needs Unicode and
> cannot be achieved by the current state of affairs? (an actual real
> world use case)
>  =20
Absolutely needs?   Do people absolutely need computers?  They are=20
supposed to
be there to serve us and make our life easier.  So you shouldn't be askin=
g
a lame question that eliminates the machines and media we are using to=20
communicate.  And don't try to use absolutes like  "cannot be achieved by
<no more progress ever>" since that's what you are saying.  Why do we nee=
d
ASCII or keyboards?  Why not go back to ones and zeros entered via flip=20
switches
on a panel?  Any point in time is "arbitrary" and gone by the time you=20
think of
it.  Limiting everything to how it is now =3D=3D not-living.


Variable names like:

L=C4=93v -- (3 letter word pronounced like Leave), (most recent try...)

or
string constants:
$=CE=A6=3D"0.618033988749894848"
$=C9=B8=3D"1.61803398874989485"
$=CF=80=3D"3.14159265358979324"
$=E2=90=89=3D$'\x09'
$=E2=85=AC=3D50   $=E2=85=AD=3D100   $=E2=85=AE=3D500   $=E2=85=AF=3D1000
$=E2=85=A0=3D1    $=E2=85=A4=3D5      $=E2=85=A9=3D10
$=E3=8E=8F=3D"kilogram"
$=E3=8E=86=3D1024*$=E3=8E=85,
etc...


Symbol names are **Symbolic** -- so why would you want to disallow=20
symbols (like
emoticons, even, though those weren't in my original proposal), but if=20
they mean something for you, maybe they can be added as well!







From MAILER-DAEMON Fri Jun 02 00:53:04 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGea8-0003Pu-BB
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 00:53:04 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60697)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGea6-0003Ok-Bp
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:53:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGea3-0001VW-9a
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:53:02 -0400
Received: from mail-oi0-x236.google.com ([2607:f8b0:4003:c06::236]:34993)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dGea3-0001Ty-3x
	for bug-bash@gnu.org; Fri, 02 Jun 2017 00:52:59 -0400
Received: by mail-oi0-x236.google.com with SMTP id l18so78645757oig.2
	for <bug-bash@gnu.org>; Thu, 01 Jun 2017 21:52:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:content-transfer-encoding:in-reply-to
	:user-agent; bh=yA5ceOVpojyNuk73khBDq38Gxcy2+v81yZUSOoHOYwc=;
	b=M+jXcXiKOF92dhDTVnD3YVW1RyCoF8j6iII6tiq1+8IMtCAGtImETahZTm4dkIuEaV
	Lx9XxS1RjXYSJ3HRLFNmsAc4YuVukpSmbmAr2JqRuMM7m/fTOoSFMityZ3MG/pUX2/qL
	Wx2dBTzE3voyeqPbRcw8lYHdKIJ5dNyt6xB87oyyu7HgbjRpyog0b8TjSotKx/Aqlgu4
	vXSgQVROWse4xXt9ACYdqfRBRf6tyvmOGZh8KpwUScceShOoutwn+twz0KA2VjVLR6fG
	NdY8O7CXeh9cGeYDEDPjHAhinvG1W0Z9QTFoQfE2oHTXe7ecY0lYjU+HvHJRvUasX2Nb
	ov0Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:content-transfer-encoding
	:in-reply-to:user-agent;
	bh=yA5ceOVpojyNuk73khBDq38Gxcy2+v81yZUSOoHOYwc=;
	b=ulchnITpC5YprXV0J4JGB1TR/cWYxTnslfrdFmyjIjK9LyEVzmTSi2Gctnf7QoUP3g
	kg8aTO6qQ2HM6xfomgFUqs/cpafFr9WvPpx3UMnbpq7vm5izzV2GDlBYjFXmA7GTJX3v
	wZKmzck1oFLJ9gL/1MxASkiNgBLcpDdC9G3tbIEDPD0qGfa4CN0ZQx6MkOHU5D5Yu35D
	4k5RYJ3JEPcVaKYiZZlGJxGo7fnj9EOtG29g/kKh7Qh46zZchweLA/QRFuzRSl8MDWLF
	kUEz1QEQXv41d/oegv1SY1m7me1WKeQqmRslwCIqC/r7bYRJ3y89LWsKCcQISWSWCo0O
	9ryw==
X-Gm-Message-State: AODbwcAk0fDNq5VvFn1QvcY+mAH2EYPIzjT4ElwCSQNSlMjhF8sc21Rw
	CJimrszUuJNAVDO8
X-Received: by 10.202.225.212 with SMTP id y203mr3546217oig.32.1496379178274; 
	Thu, 01 Jun 2017 21:52:58 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id 3sm472698ott.35.2017.06.01.21.52.57
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 01 Jun 2017 21:52:57 -0700 (PDT)
Date: Thu, 1 Jun 2017 23:52:55 -0500
From: dualbus <dualbus@gmail.com>
To: L A Walsh <bash@tlinx.org>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170602045255.4uqtbnsxryrfc432@debian>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <5930EA1C.5090100@tlinx.org>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 04:53:03 -0000

On Thu, Jun 01, 2017 at 09:31:24PM -0700, L A Walsh wrote:
[...]
> Absolutely needs?   Do people absolutely need computers?  They are supposed
> to
> be there to serve us and make our life easier.  So you shouldn't be asking
> a lame question that eliminates the machines and media we are using to
> communicate.  And don't try to use absolutes like  "cannot be achieved by
> <no more progress ever>" since that's what you are saying.  Why do we need
> ASCII or keyboards?  Why not go back to ones and zeros entered via flip
> switches
> on a panel?  Any point in time is "arbitrary" and gone by the time you think
> of
> it.  Limiting everything to how it is now == not-living.

I asked a simple question. No need to get rhetorical. No need to label
it as "lame" either, it's not. Please provide *actual* real world use
cases for Unicode identifiers.

Please remember that there's always a *cost* associated with
new features:

- Someone has to do the work of extending the current lexer / parser to
  be able to ingest multibyte character sequences. It helps a bunch if
  you do that work, and submit it for review.

- People then have to test the new implementation, to ensure that there
  are no regressions, and no new bugs introduced. I'm happy to volunteer
  once there's a working implementation.

- There are some questions that must be answered first:

  * How do you how to decode multibyte character sequences into Unicode? 
    Should UTF-8 be assumed?

  * Will the parsing of a script depend upon the user locale?

  * Should this special parsing code be disabled if POSIX mode is
    enabled?

  * Right now `name' or `identifier' is defined as:

      name: A word consisting only of alphanumeric characters and
      underscores, and beginning with an alphabetic character or an
      underscore. Also referred to as an identifier.

    How will the definition look like with Unicode identifiers?

> Variable names like:
> 
> Lēv -- (3 letter word pronounced like Leave), (most recent try...)

Use `Lev'.

> string constants:
> $Φ="0.618033988749894848"
> $ɸ="1.61803398874989485"
> $π="3.14159265358979324"
> $␉=$'\x09'
> $Ⅼ=50   $Ⅽ=100   $Ⅾ=500   $Ⅿ=1000
> $Ⅰ=1    $Ⅴ=5      $Ⅹ=10
> $㎏="kilogram"
> $㎆=1024*$㎅,
> etc...

I'm going to assume the leading `$' in the variable assignment is a
typo.

What prevents you from using?

phi='...'
pi='...'
ht='...'
kg='...'

I'm still not convinced there's an actual need here.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 02 01:07:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGeoN-00071k-1O
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 01:07:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37589)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGeoI-000705-L5
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:07:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGeoE-0003TH-6p
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:07:42 -0400
Received: from mail-oi0-x232.google.com ([2607:f8b0:4003:c06::232]:35658)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dGeoD-0003St-UR
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:07:38 -0400
Received: by mail-oi0-x232.google.com with SMTP id l18so78901557oig.2
	for <bug-bash@gnu.org>; Thu, 01 Jun 2017 22:07:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=BMBEktN31BSXRn2vvBsyZ2We7koTF4sbPMh49/97uAE=;
	b=HCAVCEjJF01e6TkLQeFNM5/AyasFOH3QyTbiHDsOLwe0HTomu9mbF8jxsZC/QyRQ1T
	/QXkY0IQc83XHn6O2r2Sp97VGAwt5OAQw9Rx+mUre6XjBvSfO6Lfulqp3dap3Ba9SaYq
	vOy6cA5VwCo+1XtS7QZJvyYFQ81+5ScvMohmZ3qoSmyA0r8sFfXv1z2NTBNY40uDPlYL
	ziPgXQnFyXNw+DjbuFnXEPBeBAPSvcED/fuOL6lGOCGlUIOCKmN5sjodW0K9G5sWWqga
	MQKDRLwgTUAwHEgmF5pYc3rljL7men+xzAgBxxvfnzc5S0eqHuo0zX1pgmjItnywByWZ
	RfUA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=BMBEktN31BSXRn2vvBsyZ2We7koTF4sbPMh49/97uAE=;
	b=WcFEhuG9b9ulvcAIU5XwgS4sKTnAZGYvbbUyZzKSjITfa6DzJrD4v6WfYZeveP5Iz4
	5yaD2V6w/VsWs8f+9Q8zs9IaZcXOfNK4SUvP78CPMCpXxb6F4mM6gu0q+AA+0jAb03+o
	7Nb2yXuvDv54ASiH3bmIj5merOWy6xqPqC+hve5RitpMW2FqBUL6XQkAirf+JwQzI6ZC
	Zr/N4hHtQNEEY2mib2MX1GiufvWmzJM3B6LU+K7wokLu7pMpxQiuhzOVnvLtRKKNkV6d
	Zcfj20bfSDI5yQqd7SLwe1gebJtiRpvuxMkERc1095uQo2bEz63yEKw43FpxEgmJfO/H
	qSQw==
X-Gm-Message-State: AODbwcBWFLoyusw/22AVnub+MP36vKq4RPpoiFApNyAz8ZBi0jUBjx1q
	fHbXJYQ9thr0KTYR
X-Received: by 10.157.32.36 with SMTP id n33mr3256843ota.81.1496380056498;
	Thu, 01 Jun 2017 22:07:36 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id b72sm512139oii.20.2017.06.01.22.07.35
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 01 Jun 2017 22:07:36 -0700 (PDT)
Date: Fri, 2 Jun 2017 00:07:34 -0500
From: dualbus <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Remaining memory corruption bugs in readline
Message-ID: <20170602050734.a2jjlilt32mbk5t2@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 05:07:45 -0000

I'm using the latest `devel' commit as a reference:

dualbus@debian:~/src/gnu/bash$ git show -q HEAD
commit 1110e30870a8782425067a060d89cc411b014418
Author: Chet Ramey <chet.ramey@case.edu>
Date:   Wed May 31 15:53:02 2017 -0400

    commit bash-snap-20170531 snapshot

Since there are still many memory corruption issues, and I'm not smart
enough to even try and see what's going on here, I'm just enumerate the
different cases I've seen so far (unique stack traces).


All of these were obtained by running:

    ./bash -c 'read -e' < $input

With isatty check disabled in the `read' builtin.


#1 _rl_get_char_len / update_line

  dualbus@debian:~/asan/3f3e$ tail -n +1 crash.5781 input.5781
  ==> crash.5781 <==
  =================================================================
  ==5781==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f400d00b063 bp 0x7ffcbce72250 sp 0x7ffcbce71a00
  READ of size 851 at 0x61900000cc80 thread T0
      #0 0x7f400d00b062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
      #1 0x559b50a04821 in _rl_get_char_len ../../../bash/lib/readline/mbutil.c:223
      #2 0x559b50a048e0 in _rl_compare_chars ../../../bash/lib/readline/mbutil.c:252
      #3 0x559b509db526 in update_line ../../../bash/lib/readline/display.c:1664
      #4 0x559b509d935b in rl_redisplay ../../../bash/lib/readline/display.c:1150
      #5 0x559b509a20be in _rl_internal_char_cleanup ../../../bash/lib/readline/readline.c:514
      #6 0x559b509a2494 in readline_internal_char ../../../bash/lib/readline/readline.c:638
      #7 0x559b509a24b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #8 0x559b509a24d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #9 0x559b509a1b8b in readline ../../../bash/lib/readline/readline.c:374
      #10 0x559b5095cf60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #11 0x559b5095a8d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #12 0x559b50870c19 in execute_builtin ../bash/execute_cmd.c:4609
      #13 0x559b5087282f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #14 0x559b508700af in execute_simple_command ../bash/execute_cmd.c:4395
      #15 0x559b5085ded2 in execute_command_internal ../bash/execute_cmd.c:811
      #16 0x559b508667be in execute_connection ../bash/execute_cmd.c:2639
      #17 0x559b5085eca7 in execute_command_internal ../bash/execute_cmd.c:980
      #18 0x559b50947f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #19 0x559b50829391 in run_one_command ../bash/shell.c:1405
      #20 0x559b5082786a in main ../bash/shell.c:718
      #21 0x7f400c8232b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
      #22 0x559b508266d9 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f6d9)
  
  0x61900000cc80 is located 0 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
  allocated by thread T0 here:
      #0 0x7f400d090d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
      #1 0x559b50936bf6 in xmalloc ../bash/xmalloc.c:112
      #2 0x559b509d40f9 in init_line_structures ../../../bash/lib/readline/display.c:608
      #3 0x559b509d492c in rl_redisplay ../../../bash/lib/readline/display.c:677
      #4 0x559b509a1d88 in readline_internal_setup ../../../bash/lib/readline/readline.c:444
      #5 0x559b509a24d0 in readline_internal ../../../bash/lib/readline/readline.c:669
      #6 0x559b509a1b8b in readline ../../../bash/lib/readline/readline.c:374
      #7 0x559b5095cf60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #8 0x559b5095a8d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #9 0x559b50870c19 in execute_builtin ../bash/execute_cmd.c:4609
      #10 0x559b5087282f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #11 0x559b508700af in execute_simple_command ../bash/execute_cmd.c:4395
      #12 0x559b5085ded2 in execute_command_internal ../bash/execute_cmd.c:811
      #13 0x559b508667be in execute_connection ../bash/execute_cmd.c:2639
      #14 0x559b5085eca7 in execute_command_internal ../bash/execute_cmd.c:980
      #15 0x559b50947f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #16 0x559b50829391 in run_one_command ../bash/shell.c:1405
      #17 0x559b5082786a in main ../bash/shell.c:718
      #18 0x7f400c8232b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
  
  SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
  Shadow bytes around the buggy address:
    0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  =>0x0c327fff9990:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  Shadow byte legend (one shadow byte represents 8 application bytes):
    Addressable:           00
    Partially addressable: 01 02 03 04 05 06 07 
    Heap left redzone:       fa
    Heap right redzone:      fb
    Freed heap region:       fd
    Stack left redzone:      f1
    Stack mid redzone:       f2
    Stack right redzone:     f3
    Stack partial redzone:   f4
    Stack after return:      f5
    Stack use after scope:   f8
    Global redzone:          f9
    Global init order:       f6
    Poisoned by user:        f7
    Container overflow:      fc
    Array cookie:            ac
    Intra object redzone:    bb
    ASan internal:           fe
    Left alloca redzone:     ca
    Right alloca redzone:    cb
  ==5781==ABORTING
  
  ==> input.5781 <==
  NzY37gEuGyq7FbsVGRkZGTc+Ju4BNz4m7gEuGyq7FbsVGRkZGREKGRkZGQCAATwRgAFgGRk4GQAB
  RIAABw4a/4gAEAU=


#2 Memory leak

  dualbus@debian:~/asan/d41d$ tail -n +1 crash.11263 input.11263
  ==> crash.11263 <==
  
  =================================================================
  ==11263==ERROR: LeakSanitizer: detected memory leaks
  
  Direct leak of 32 byte(s) in 1 object(s) allocated from:
      #0 0x7f0bf9186d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
      #1 0x5599adcd4bf6 in xmalloc ../bash/xmalloc.c:112
      #2 0x5599adbf0253 in make_bare_simple_command ../bash/make_cmd.c:504
      #3 0x5599adbf0497 in make_simple_command ../bash/make_cmd.c:531
      #4 0x5599adbcded9 in yyparse ../bash/parse.y:734
      #5 0x5599adbcaea2 in parse_command ../bash/eval.c:294
      #6 0x5599adce5363 in parse_and_execute ../../bash/builtins/evalstring.c:346
      #7 0x5599adc6345f in command_substitute ../bash/subst.c:6107
      #8 0x5599adc78439 in expand_word_internal ../bash/subst.c:9720
      #9 0x5599adc5825b in call_expand_word_internal ../bash/subst.c:3650
      #10 0x5599adc591c0 in expand_word ../bash/subst.c:3928
      #11 0x5599adcbad34 in shell_expand_line ../bash/bashline.c:2735
      #12 0x5599add41005 in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
      #13 0x5599add417e7 in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:985
      #14 0x5599add40be0 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
      #15 0x5599add4041f in readline_internal_char ../../../bash/lib/readline/readline.c:629
      #16 0x5599add404b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #17 0x5599add404d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #18 0x5599add3fb8b in readline ../../../bash/lib/readline/readline.c:374
      #19 0x5599adcfaf60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #20 0x5599adcf88d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #21 0x5599adc0ec19 in execute_builtin ../bash/execute_cmd.c:4609
      #22 0x5599adc1082f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #23 0x5599adc0e0af in execute_simple_command ../bash/execute_cmd.c:4395
      #24 0x5599adbfbed2 in execute_command_internal ../bash/execute_cmd.c:811
      #25 0x5599adc047be in execute_connection ../bash/execute_cmd.c:2639
      #26 0x5599adbfcca7 in execute_command_internal ../bash/execute_cmd.c:980
      #27 0x5599adce5f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #28 0x5599adbc7391 in run_one_command ../bash/shell.c:1405
      #29 0x5599adbc586a in main ../bash/shell.c:718
  
  Indirect leak of 24 byte(s) in 1 object(s) allocated from:
      #0 0x7f0bf9186d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
      #1 0x5599adcd4bf6 in xmalloc ../bash/xmalloc.c:112
      #2 0x5599adbf0261 in make_bare_simple_command ../bash/make_cmd.c:505
      #3 0x5599adbf0497 in make_simple_command ../bash/make_cmd.c:531
      #4 0x5599adbcded9 in yyparse ../bash/parse.y:734
      #5 0x5599adbcaea2 in parse_command ../bash/eval.c:294
      #6 0x5599adce5363 in parse_and_execute ../../bash/builtins/evalstring.c:346
      #7 0x5599adc6345f in command_substitute ../bash/subst.c:6107
      #8 0x5599adc78439 in expand_word_internal ../bash/subst.c:9720
      #9 0x5599adc5825b in call_expand_word_internal ../bash/subst.c:3650
      #10 0x5599adc591c0 in expand_word ../bash/subst.c:3928
      #11 0x5599adcbad34 in shell_expand_line ../bash/bashline.c:2735
      #12 0x5599add41005 in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
      #13 0x5599add417e7 in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:985
      #14 0x5599add40be0 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
      #15 0x5599add4041f in readline_internal_char ../../../bash/lib/readline/readline.c:629
      #16 0x5599add404b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #17 0x5599add404d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #18 0x5599add3fb8b in readline ../../../bash/lib/readline/readline.c:374
      #19 0x5599adcfaf60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #20 0x5599adcf88d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #21 0x5599adc0ec19 in execute_builtin ../bash/execute_cmd.c:4609
      #22 0x5599adc1082f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #23 0x5599adc0e0af in execute_simple_command ../bash/execute_cmd.c:4395
      #24 0x5599adbfbed2 in execute_command_internal ../bash/execute_cmd.c:811
      #25 0x5599adc047be in execute_connection ../bash/execute_cmd.c:2639
      #26 0x5599adbfcca7 in execute_command_internal ../bash/execute_cmd.c:980
      #27 0x5599adce5f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #28 0x5599adbc7391 in run_one_command ../bash/shell.c:1405
      #29 0x5599adbc586a in main ../bash/shell.c:718
  
  SUMMARY: AddressSanitizer: 56 byte(s) leaked in 2 allocation(s).
  
  ==> input.11263 <==
  AAIbLbUAAlsQGDIYFRwYGBkTGJgZGBgYGAAXGBkYGvgXFBg2


#3 _rl_find_prev_mbchar_internal / update_line

  dualbus@debian:~/asan/a9fd$ tail -n +1 crash.21027 input.21027
  ==> crash.21027 <==
  =================================================================
  ==21027==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7fb18d925063 bp 0x7fffd7a0e960 sp 0x7fffd7a0e110
  READ of size 942 at 0x61900000cc80 thread T0
      #0 0x7fb18d925062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
      #1 0x55f2feff057f in _rl_find_prev_mbchar_internal ../../../bash/lib/readline/mbutil.c:162
      #2 0x55f2feff1057 in _rl_find_prev_mbchar ../../../bash/lib/readline/mbutil.c:369
      #3 0x55f2fefc792d in update_line ../../../bash/lib/readline/display.c:1720
      #4 0x55f2fefc535b in rl_redisplay ../../../bash/lib/readline/display.c:1150
      #5 0x55f2fef8e0be in _rl_internal_char_cleanup ../../../bash/lib/readline/readline.c:514
      #6 0x55f2fef8e494 in readline_internal_char ../../../bash/lib/readline/readline.c:638
      #7 0x55f2fef8e4b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #8 0x55f2fef8e4d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #9 0x55f2fef8db8b in readline ../../../bash/lib/readline/readline.c:374
      #10 0x55f2fef48f60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #11 0x55f2fef468d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #12 0x55f2fee5cc19 in execute_builtin ../bash/execute_cmd.c:4609
      #13 0x55f2fee5e82f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #14 0x55f2fee5c0af in execute_simple_command ../bash/execute_cmd.c:4395
      #15 0x55f2fee49ed2 in execute_command_internal ../bash/execute_cmd.c:811
      #16 0x55f2fee527be in execute_connection ../bash/execute_cmd.c:2639
      #17 0x55f2fee4aca7 in execute_command_internal ../bash/execute_cmd.c:980
      #18 0x55f2fef33f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #19 0x55f2fee15391 in run_one_command ../bash/shell.c:1405
      #20 0x55f2fee1386a in main ../bash/shell.c:718
      #21 0x7fb18d13d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
      #22 0x55f2fee126d9 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f6d9)
  
  0x61900000cc80 is located 0 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
  allocated by thread T0 here:
      #0 0x7fb18d9aad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
      #1 0x55f2fef22bf6 in xmalloc ../bash/xmalloc.c:112
      #2 0x55f2fefc00f9 in init_line_structures ../../../bash/lib/readline/display.c:608
      #3 0x55f2fefc092c in rl_redisplay ../../../bash/lib/readline/display.c:677
      #4 0x55f2fef8dd88 in readline_internal_setup ../../../bash/lib/readline/readline.c:444
      #5 0x55f2fef8e4d0 in readline_internal ../../../bash/lib/readline/readline.c:669
      #6 0x55f2fef8db8b in readline ../../../bash/lib/readline/readline.c:374
      #7 0x55f2fef48f60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #8 0x55f2fef468d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #9 0x55f2fee5cc19 in execute_builtin ../bash/execute_cmd.c:4609
      #10 0x55f2fee5e82f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #11 0x55f2fee5c0af in execute_simple_command ../bash/execute_cmd.c:4395
      #12 0x55f2fee49ed2 in execute_command_internal ../bash/execute_cmd.c:811
      #13 0x55f2fee527be in execute_connection ../bash/execute_cmd.c:2639
      #14 0x55f2fee4aca7 in execute_command_internal ../bash/execute_cmd.c:980
      #15 0x55f2fef33f55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #16 0x55f2fee15391 in run_one_command ../bash/shell.c:1405
      #17 0x55f2fee1386a in main ../bash/shell.c:718
      #18 0x7fb18d13d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
  
  SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
  Shadow bytes around the buggy address:
    0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  =>0x0c327fff9990:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  Shadow byte legend (one shadow byte represents 8 application bytes):
    Addressable:           00
    Partially addressable: 01 02 03 04 05 06 07 
    Heap left redzone:       fa
    Heap right redzone:      fb
    Freed heap region:       fd
    Stack left redzone:      f1
    Stack mid redzone:       f2
    Stack right redzone:     f3
    Stack partial redzone:   f4
    Stack after return:      f5
    Stack use after scope:   f8
    Global redzone:          f9
    Global init order:       f6
    Poisoned by user:        f7
    Container overflow:      fc
    Array cookie:            ac
    Intra object redzone:    bb
    ASan internal:           fe
    Left alloca redzone:     ca
    Right alloca redzone:    cb
  ==21027==ABORTING
  
  ==> input.21027 <==
  AAIbLbUAAlsQGDIYFRwYGBkYGJgYGBf5MQAYGBgwGAEAAEAYGBgYAAAEAJIY+xcYGRgYGDkXGDY=

#4 _rl_get_char_len / update_line

  dualbus@debian:~/asan/51ea$ tail -n +1 crash.8188 input.8188
  ==> crash.8188 <==
  =================================================================
  ==8188==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d00001d480 at pc 0x7f51dd3ca063 bp 0x7ffd8c2b8100 sp 0x7ffd8c2b78b0
  READ of size 1434 at 0x61d00001d480 thread T0
      #0 0x7f51dd3ca062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
      #1 0x564c2a549821 in _rl_get_char_len ../../../bash/lib/readline/mbutil.c:223
      #2 0x564c2a5498e0 in _rl_compare_chars ../../../bash/lib/readline/mbutil.c:252
      #3 0x564c2a520526 in update_line ../../../bash/lib/readline/display.c:1664
      #4 0x564c2a51e35b in rl_redisplay ../../../bash/lib/readline/display.c:1150
      #5 0x564c2a523ec7 in rl_message ../../../bash/lib/readline/display.c:2643
      #6 0x564c2a51267e in rl_display_search ../../../bash/lib/readline/isearch.c:196
      #7 0x564c2a517901 in rl_search_history ../../../bash/lib/readline/isearch.c:750
      #8 0x564c2a5124c3 in rl_forward_search_history ../../../bash/lib/readline/isearch.c:144
      #9 0x564c2a4e8005 in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
      #10 0x564c2a4e7be0 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
      #11 0x564c2a4e741f in readline_internal_char ../../../bash/lib/readline/readline.c:629
      #12 0x564c2a4e74b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #13 0x564c2a4e74d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #14 0x564c2a4e6b8b in readline ../../../bash/lib/readline/readline.c:374
      #15 0x564c2a4a1f60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #16 0x564c2a49f8d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #17 0x564c2a3b5c19 in execute_builtin ../bash/execute_cmd.c:4609
      #18 0x564c2a3b782f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #19 0x564c2a3b50af in execute_simple_command ../bash/execute_cmd.c:4395
      #20 0x564c2a3a2ed2 in execute_command_internal ../bash/execute_cmd.c:811
      #21 0x564c2a3ab7be in execute_connection ../bash/execute_cmd.c:2639
      #22 0x564c2a3a3ca7 in execute_command_internal ../bash/execute_cmd.c:980
      #23 0x564c2a48cf55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #24 0x564c2a36e391 in run_one_command ../bash/shell.c:1405
      #25 0x564c2a36c86a in main ../bash/shell.c:718
      #26 0x7f51dcbe22b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
      #27 0x564c2a36b6d9 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f6d9)
  
  0x61d00001d480 is located 0 bytes to the right of 2048-byte region [0x61d00001cc80,0x61d00001d480)
  allocated by thread T0 here:
      #0 0x7f51dd450090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
      #1 0x564c2a47bc61 in xrealloc ../bash/xmalloc.c:133
      #2 0x564c2a51a850 in rl_redisplay ../../../bash/lib/readline/display.c:929
      #3 0x564c2a4e70be in _rl_internal_char_cleanup ../../../bash/lib/readline/readline.c:514
      #4 0x564c2a4e7494 in readline_internal_char ../../../bash/lib/readline/readline.c:638
      #5 0x564c2a4e74b1 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #6 0x564c2a4e74d5 in readline_internal ../../../bash/lib/readline/readline.c:670
      #7 0x564c2a4e6b8b in readline ../../../bash/lib/readline/readline.c:374
      #8 0x564c2a4a1f60 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1090
      #9 0x564c2a49f8d1 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:554
      #10 0x564c2a3b5c19 in execute_builtin ../bash/execute_cmd.c:4609
      #11 0x564c2a3b782f in execute_builtin_or_function ../bash/execute_cmd.c:5107
      #12 0x564c2a3b50af in execute_simple_command ../bash/execute_cmd.c:4395
      #13 0x564c2a3a2ed2 in execute_command_internal ../bash/execute_cmd.c:811
      #14 0x564c2a3ab7be in execute_connection ../bash/execute_cmd.c:2639
      #15 0x564c2a3a3ca7 in execute_command_internal ../bash/execute_cmd.c:980
      #16 0x564c2a48cf55 in parse_and_execute ../../bash/builtins/evalstring.c:430
      #17 0x564c2a36e391 in run_one_command ../bash/shell.c:1405
      #18 0x564c2a36c86a in main ../bash/shell.c:718
      #19 0x7f51dcbe22b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
  
  SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
  Shadow bytes around the buggy address:
    0x0c3a7fffba40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c3a7fffba50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c3a7fffba60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c3a7fffba70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c3a7fffba80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  =>0x0c3a7fffba90:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c3a7fffbaa0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c3a7fffbab0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c3a7fffbac0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
    0x0c3a7fffbad0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x0c3a7fffbae0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  Shadow byte legend (one shadow byte represents 8 application bytes):
    Addressable:           00
    Partially addressable: 01 02 03 04 05 06 07 
    Heap left redzone:       fa
    Heap right redzone:      fb
    Freed heap region:       fd
    Stack left redzone:      f1
    Stack mid redzone:       f2
    Stack right redzone:     f3
    Stack partial redzone:   f4
    Stack after return:      f5
    Stack use after scope:   f8
    Global redzone:          f9
    Global init order:       f6
    Poisoned by user:        f7
    Container overflow:      fc
    Array cookie:            ac
    Intra object redzone:    bb
    ASan internal:           fe
    Left alloca redzone:     ca
    Right alloca redzone:    cb
  ==8188==ABORTING
  
  ==> input.8188 <==
  G////3/MhxWAbN28ICAg+vr6zGwhGQCA/xkZGSsZGToZA+j/GRkZGRkYvAAAEACAKR0ZPj4ZGf86
  UBcZBf//BRAAgCkeGT4+GRn/OlAXGRkZGP4ZIRkAgP/4GBkZGRmUlJSUlJSUlEtLHBMZWmBKP0sZ
  GRkZH7S8GRn/ICE=


The rest of the traces I'm seeing seem to be variations of the above.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 02 01:16:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGex2-00015X-Lt
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 01:16:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40333)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGewz-00015O-Gl
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:16:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGewu-0002M8-IF
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:16:41 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:46498
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dGewu-0002Lg-AE
	for bug-bash@gnu.org; Fri, 02 Jun 2017 01:16:36 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v525GUTF008283; Thu, 1 Jun 2017 22:16:32 -0700
Message-ID: <5930F4AE.1050308@tlinx.org>
Date: Thu, 01 Jun 2017 22:16:30 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: dualbus <dualbus@gmail.com>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>
In-Reply-To: <20170602045255.4uqtbnsxryrfc432@debian>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v525GUTF008283
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 05:16:42 -0000



dualbus wrote:
>
> - People then have to test the new implementation, to ensure that there
>   are no regressions, and no new bugs introduced. I'm happy to voluntee=
r
>   once there's a working implementation.
>
> - There are some questions that must be answered first:
>
>   * How do you how to decode multibyte character sequences into Unicode=
?=20
>     Should UTF-8 be assumed?
>  =20
You realize bash already allows UTF-8 input?


>   * Will the parsing of a script depend upon the user locale?
>
>   * Should this special parsing code be disabled if POSIX mode is
>     enabled?
>  =20
----
    I think I answered that.


>   * Right now `name' or `identifier' is defined as:
>
>       name: A word consisting only of alphanumeric characters and
>       underscores, and beginning with an alphabetic character or an
>       underscore. Also referred to as an identifier.
>
>     How will the definition look like with Unicode identifiers?
>  =20
----
    The characters I mention are alphanumeric.  Just not limited to
the US.

>  =20
>> Variable names like:
>>
>> L=C4=93v -- (3 letter word pronounced like Leave), (most recent try...=
)
>>    =20
>
> Use `Lev'.
>  =20
Sorry, if you are going to change the question, then there is no use=20
answering.
Lev is pronounced as in "lev"itation. There is a difference.
>  =20
>> string constants:
>> $=CE=A6=3D"0.618033988749894848"
>> $=C9=B8=3D"1.61803398874989485"
>> $=CF=80=3D"3.14159265358979324"
>> $=E2=90=89=3D$'\x09'
>> $=E2=85=AC=3D50   $=E2=85=AD=3D100   $=E2=85=AE=3D500   $=E2=85=AF=3D1=
000
>> $=E2=85=A0=3D1    $=E2=85=A4=3D5      $=E2=85=A9=3D10
>> $=E3=8E=8F=3D"kilogram"
>> $=E3=8E=86=3D1024*$=E3=8E=85,
>> etc...
>>    =20
>
> I'm going to assume the leading `$' in the variable assignment is a
> typo.
>  =20
Sure.
> What prevents you from using?
>  =20
> phi=3D'...'
>  =20
---
Again, you are changing the requirement.  Besides...
all of those are "alphanumeric"... just not US alphabet
(try greek).
> ht=3D'...'
>  =20
> kg=3D'...'
>  =20
Those aren't 1 character or symbol.

> I'm still not convinced there's an actual need here.
>  =20
What actual need is there for bash?  Or computers or ASCII.
Why are we not still using binary bits?

I don't suppose we wanted something more expressive or symbolic?

Couldn't we have gotten by with the original Bourne shell?  Why develop
bash?  What was the actual need?

You can't convince me there was a need for that and not for this just
because it is what _you_ use or don't use.

How do you emphasize a var, say in italic or bold?
=F0=9D=90=BF=F0=9D=91=96=F0=9D=91=98=F0=9D=91=92 =F0=9D=91=87=F0=9D=98=A9=
=F0=9D=98=AA=F0=9D=98=B4?
or =F0=9D=92=AF=F0=9D=92=BD=F0=9D=92=BE=F0=9D=93=88?
or =F0=9D=97=A7=F0=9D=97=B5=F0=9D=97=B6=F0=9D=98=80?

They'd all scan differently.

Anyway, bash already has some unicode parsing in it because
it accepts UTF-8.  So it wouldn't have to be the complete
rewrite you make it.











From MAILER-DAEMON Fri Jun 02 08:15:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGlUa-0000Lk-Bx
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 08:15:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49955)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dGlUY-0000KT-GX
	for bug-bash@gnu.org; Fri, 02 Jun 2017 08:15:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dGlUV-0005Ej-Bf
	for bug-bash@gnu.org; Fri, 02 Jun 2017 08:15:46 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:57696 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dGlUV-0005EX-3c
	for bug-bash@gnu.org; Fri, 02 Jun 2017 08:15:43 -0400
Received: (qmail 16413 invoked from network); 2 Jun 2017 12:15:41 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 02 Jun 2017 08:15:41 -0400
Received: (qmail 28008 invoked by uid 563); 2 Jun 2017 12:15:41 -0000
Date: Fri, 2 Jun 2017 08:15:41 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170602121541.GP7764@eeg.ccf.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5930EA1C.5090100@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 12:15:47 -0000

On Thu, Jun 01, 2017 at 09:31:24PM -0700, L A Walsh wrote:
> Variable names like:
> 
> L??v -- (3 letter word pronounced like Leave), (most recent try...)

Here is a demonstration of the cost of what you are proposing.  In my
mail user agent, your variable shows up as L??v.

Source code with your UTF-8 identifiers would no longer even be READABLE
on systems that do not use UTF-8.  Like the system I am using RIGHT NOW,
which uses Latin-1.  But also like Windows systems using WIN1252, Asian
systems using Big5, etc.

Maybe you can try again after 2038, which will probably take out most
of these old systems.  Perhaps then the world will actually be capable
of moving beyond ASCII as a UNIVERSAL encoding.  Today, we're not.


From MAILER-DAEMON Fri Jun 02 09:18:56 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGmTg-0006is-Lz
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 09:18:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37451)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGmTd-0006iW-Us
	for bug-bash@gnu.org; Fri, 02 Jun 2017 09:18:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dGmTZ-0002eu-WC
	for bug-bash@gnu.org; Fri, 02 Jun 2017 09:18:53 -0400
Received: from mail-oi0-x235.google.com ([2607:f8b0:4003:c06::235]:36025)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dGmTZ-0002eL-RE
	for bug-bash@gnu.org; Fri, 02 Jun 2017 09:18:49 -0400
Received: by mail-oi0-x235.google.com with SMTP id h4so91538547oib.3
	for <bug-bash@gnu.org>; Fri, 02 Jun 2017 06:18:49 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=tv1y74E+Hx5Nu6nO64wexMcmL2/c7sF6a+FpFL/50EY=;
	b=cV4Nx9dh6LhvYZHjaFaMXUKnGD5JC8md1I8ioTQtfSdqZHa5fX5LYIk6964EM1udzN
	p43gAZPXBY71BMVMJ1ZY/7JEfd2Td+w2sfJPv4bi/+zgtaKrohvsVwpYCkTJZ59lJkUS
	KhaeJGY0ooaQBqBkLz6Xne6qi9Tq+0hReDKmYytdAUpOdLJuRC7tVyDcV0FDgKnnCYOf
	ZkXjwfO2KA9NjV7LDtZsoRvyJUFuInAvggUjsrLaulcZ9hzmuRTpMizFDDTtq7S0zABH
	1Qu0/b5oqSSIr7ifOnVZjwqdocPrbCPYM4EOlt/tgcExukIiw/dLg6As0HSAFtz2ftoF
	/Tkw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=tv1y74E+Hx5Nu6nO64wexMcmL2/c7sF6a+FpFL/50EY=;
	b=pGA4lXdkI9NI0erYQ2MOh3MiQThajbPfaIDgglBtGE/FGOh9N/lGImof/71t8l241l
	R5wcPN22mddFv/qajUqIBk2VYVmrG+uNinTLK09vTqcVgxnce7fn13AcmTByAjQje63S
	nig7qkMYI5hJ391kEFxegvNbNAfobGLD515VCpwfeuSiUDF0e4wtu9ore4LajCOXzSCg
	J7Ie13X3PRfdipSOeLx1M8kQN4zyJ8ALg3LTRjUXpbSz5Xo3PL9p2qa7p1ohP/1hW368
	90r+//+CcEEzjnba9J3xZ5xqpQ7yNR8MELHL3ouqxljXrWfL4srt7Fl5vQB+OkT6FpV4
	6h9Q==
X-Gm-Message-State: AODbwcB7Jeq/VrH6RIgju6BmmrE5ErpUNNXRJmp3hFkNwwYWQWvstJ3s
	+KyzfuYYfVsVmtJK
X-Received: by 10.157.49.87 with SMTP id v23mr4164244otd.16.1496409529160;
	Fri, 02 Jun 2017 06:18:49 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id d44sm936516otc.6.2017.06.02.06.18.48
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Fri, 02 Jun 2017 06:18:48 -0700 (PDT)
Date: Fri, 2 Jun 2017 08:18:46 -0500
From: dualbus <dualbus@gmail.com>
To: L A Walsh <bash@tlinx.org>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170602131846.rclunctr5ri2s4jr@debian>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <5930F4AE.1050308@tlinx.org>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 13:18:55 -0000

On Thu, Jun 01, 2017 at 10:16:30PM -0700, L A Walsh wrote:
> > Should UTF-8 be assumed?
> You realize bash already allows UTF-8 input?

Of course. Both Bash and Readline are able to process multibyte
character input. That's not the same as parsing multibyte sequences in
*code*. See Python's Enhancement Proposal on the matter to get a glimpse
of some of the challenges of implementing Unicode identifiers:
https://www.python.org/dev/peps/pep-3131/

[...]

> I don't suppose we wanted something more expressive or symbolic?
> 
> Couldn't we have gotten by with the original Bourne shell?  Why develop
> bash?  What was the actual need?

Because the Bourne shell was not free software. And this has nothing to
do at all with your RFE.

> How do you emphasize a var, say in italic or bold?

I don't. It's source code. I don't write source code in Spanish, nor do
I don't underline, emphasize, strike, bold, italic, ...

> Anyway, bash already has some unicode parsing in it because
> it accepts UTF-8.  So it wouldn't have to be the complete
> rewrite you make it.

Then it shouldn't be hard for you to craft a small patch and send it to
the list so that we can review it. Don't put words on my mouth. I said
that it will increase the complexity of the parser, and will most likely
introduce a whole new class of parsing bugs. If you want to give it a
try, be my guest. But don't ask for stuff without considering the cost
of what you're requesting, or if you're not willing to make part of the
contribution yourself.


Anyways. Unless I see an actual patch, this will be my last response to
this thread.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 02 12:54:46 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGpqX-0000qb-So
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 12:54:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40665)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dGpqU-0000oa-4S
	for bug-bash@gnu.org; Fri, 02 Jun 2017 12:54:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dGpqQ-0003NP-MV
	for bug-bash@gnu.org; Fri, 02 Jun 2017 12:54:42 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:39614
	helo=homiemail-a124.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dGpqQ-0003LA-6k
	for bug-bash@gnu.org; Fri, 02 Jun 2017 12:54:38 -0400
Received: from homiemail-a124.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a124.g.dreamhost.com (Postfix) with ESMTP id 0400D60000D00;
	Fri,  2 Jun 2017 09:54:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=RjGDJ4+KVk0mCwsEPP34gVWhy+M=; b=
	hb4594f5PzximV8/MlQuhWiFbaIUQVYbTx7oAfBlEtLrvC8t1fMDZuA/reYiV9MN
	leJ2s+fh6Ke1HCJmUaM3M4018/xtx6vYPC5H/HBCwdH+gMSxICqr1qZC5BtIFdly
	Py9+07sDH6gwbLPbcyxtTP4sa/iuKVX3B3w13I57xPw=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a124.g.dreamhost.com (Postfix) with ESMTPSA id
	EAD1B60001B0A; Fri,  2 Jun 2017 09:54:33 -0700 (PDT)
Message-Id: <f55d69ca52bedb84388602da18dbac4ef7d0b269@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "dualbus" <dualbus@gmail.com>,
 "L A Walsh" <bash@tlinx.org>
Cc: "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <20170602045255.4uqtbnsxryrfc432@debian>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Date: Fri, 02 Jun 2017 12:54:33 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 16:54:45 -0000

=0AIt's all but impossible to establish an "absolute need" for a new=0Af=
eature. In the extreme case there is always the argument that one=0Adoes=
 not "absolutely need" a feature added to bash, because one could=0Asimp=
ly use Bash to launch another tool that provides that feature -=0Acode i=
n Python rather than shell scripts, etc. Very, very few "needs"=0Aqualif=
y as "absolutes". But there are decisions that can make Bash a=0Abetter=
 programming language that are worth considering, even if they=0Aare not=
 "absolutely" needed - just as associative arrays or regular=0Aexpressio=
ns were not "absolutely" needed, but are quite useful.=0A=0AI agree that=
 allowing Unicode in parameter names is problematic:=0A- there are chara=
cters that should be equivalent in principle, but=0Aaren't (For instance=
, the Greek letter pi (=CF=80) and the mathematical=0Asymbol pi (=F0=9D=
=9B=91) - in some fonts they may render the same, but they=0Aare distinc=
t code points) Some of these characters will look like Bash=0Asyntax, bu=
t be encoded differently.=0A- there are characters that are equivalent,=
 but can be encoded=0Amultiple ways (For instance, '=C3=A9' may be encod=
ed as $'u00E9' or as=0A$'eu0309') - broadly speaking this falls under th=
e scope of "Unicode=0ANormalization" - it's a well-explored problem but=
 not a trivial one.=0A(And it gets much worse with Asian languages, for=
 instance)=0A- Unicode introduces more whitespace characters - to allow=
 Unicode=0Aglyphs in parameter names, one must also decide whether to in=
terpret=0AUnicode whitespace as whitespace (complicating parsing rules,=
 word=0Asplitting rules, etc.) - or to treat only ASCII whitespace as=0A=
whitespace (in which case Unicode whitespace can form part of a "word"=
=0Awithout quoting - which could make such code visually confusing)=0A-=
 As you pointed out, this requires the shell to somehow establish a=0Aco=
nvention governing the character set used to interpret shell scripts=0A-=
 a point on which the shell has so far been able to remain=0Anoncommitta=
l (as long as the character set is ASCII-compatible)=0A=0AI think the va=
lue is that it allows the programmer to express=0Athemselves in their na=
tive language. The history of computing up to=0Athis point has produced=
 this situation where most programming=0Alangauges are oriented toward n=
ative English speakers and use of the=0ALatin alphabet. And it would be=
 very difficult to make a programming=0Alanguage truly multi-lingual. Bu=
t I think it's a worthwhile goal,=0Aparticularly in the shell (which can=
 be used for scripting, but also=0Afor general, interactive operation of=
 the computer) to accommodate=0Aforeign vocabulary in those contexts in=
 which the user chooses to use=0Ait.=0A=0AFrom an English-speaker's pers=
pective, allowing Unicode could allow=0Avariable names to distinguish be=
tween "resume=CC=81" and "resume". (We=0Adon't use accented characters m=
uch)=0AFor various European languages, the use of accented characters (a=
nd=0Aother characters that lie outside of ASCII) can be necessary to mak=
e=0Acertain words clear. If you drop an accent mark from a word that wou=
ld=0Anormally use it, the word looks like something else.=0AAnd for Asia=
n languages like Japanese, the use of ideogram characters=0Acan help to=
 distinguish between homophones.=0A=0APersonally I also feel it's worthw=
hile to support symbols as in=0AWalsh's examples as well: For instance,=
 the symbol "pi" has a very=0Aclear meaning. You can see it and know it=
 doesn't mean "previous value=0Aof an iteration variable that was casual=
ly/sloppily named $i" or=0Asomething else. Where that symbol appears it=
 almost always refers to=0Athe circle ratio. Some of Walsh's other examp=
les I think would just be=0Aneedlessly confusing: for instance using '=
=E2=85=AD' (U+216D, the ROMAN=0ANUMERAL C) as a variable name just resul=
ts in a variable name that's=0Ahard to type, and distinct from but almos=
t visually indistinguishable=0Afrom 'C'. I see cases like that as "enoug=
h rope to hang oneself with".=0AYou can use Unicode to do silly or confu=
sing things, and it's not the=0Aresponsibility of the shell to prevent s=
omeone from doing such things.=0A=0AGreg raises a fair point: Some platf=
orms will simply be unable to view=0Ascripts written with Unicode symbol=
s...=0A...Likewise, some platforms will be unable to view scripts writte=
n=0Awith other features that are already present, such as Unicode string=
=0Aliterals, or Unicode command names.=0A=0ABut, on the other hand:=0A-=
 Even if your editor or terminal can't display the UTF-8 code, that=0Ado=
esn't mean the shell process can't RUN it.=0A- If your terminal can't di=
splay UTF-8...=C2=A0 Well, you can edit the=0Acode from a terminal that=
 CAN.=0ASo I don't think it's that big of a problem.=0A=0AFrankly, makin=
g shell scripts broadly compatible (let alone=0A"universally" compatible=
) is very, very difficult. Can you believe=0Asomeone wrote a shell scrip=
t that used the colon character as part of=0Aa "tar" archive name? They=
 clearly didn't have GNU tar in mind when=0Athey wrote that...=C2=A0 Thi=
s would be just another case of something=0Auseful-but-not-universally-c=
ompatible. (In other words, if the feature=0Ais added, it becomes one of=
 those things you don't use if you want=0Ayour script to be portable. Fr=
ankly if it were added to Bash now, most=0Aof us would have to wait 5-10=
 years for today's version of Bash to=0Abecome "the oldest version our p=
roject must still support" before we=0Acould use the feature...=C2=A0 Th=
is is part of why I tend to be rather=0Aforward-looking when it comes to=
 the question of what should be in the=0Ashell.)=0A=0ATo address your qu=
estions on related design decisions that would have=0Ato be made for thi=
s to work, here's how I'd approach it for a=0Apre-existing language like=
 Bash with a long legacy:=0A=0A1: For an interactive session, the charac=
ter encoding of commands is=0Ataken from the locale.=0A2: For a script,=
 the character encoding of commands must be explicitly=0Aspecified, prob=
ably via a shell option. (Ideally I think it should be=0Aspecified per-f=
ile, but I don't know if Bash supports any kind of=0Aper-file shell opti=
ons. This is so, for instance, a non-Unicode=0Asession that sources a Un=
icode shell script does not become a Unicode=0Asession, or a Unicode scr=
ipt that sources a non-Unicode script does=0Anot interpret that script a=
s Unicode.)=0A3: If a script does not specify its character encoding, th=
en the=0Abehavior is like current versions of Bash: multi-byte character=
s are=0Asupported in some contexts (quoted strings, command names, words=
) but=0Anot others (parameter names)=0A4: Sub-shell invocation, command/=
process substitution, etc. inherit=0Athe character encoding of the paren=
t shell.=0A5: Enabling Unicode parsing of the script doesn't add Unicode=
=0Awhitespace characters to IFS - it affects how the script is=0Ainterpr=
eted, not how the parsed code operates.=0A6: If POSIX mode is active, I=
 think all of this gets disabled and=0AUnicode characters are disallowed=
 as parameter names.=0A=0AI'm not certain about normalization. I think t=
he easy answer is to=0Ajust say the shell doesn't normalize the Unicode=
 it gets - which means=0Ascripts could contain instances of Unicode code=
 points that should be=0Aequivalent (character composition, etc.) but ar=
en't considered equal=0Aby the shell.=0A=0AI think another angle worth c=
onsidering is that most of what I=0Aoutlined above is only important if=
 you want to take advantage of it=0Afor other features. For instance:=0A=
- In order to support transcoding, to allow (for instance) a Latin-1=0As=
cript to source a Unicode script and for equivalently-named entities=0Ai=
n the two to connect.=0A- In order to support Unicode whitespace as part=
 of the language=0Asyntax=0A=0AWithout those additional requirements, th=
e current status quo (which=0Aallows for UTF-8 characters to appear in f=
unction names, command=0Anames, coprocess names, alias names, as part of=
 file paths, quoted or=0Aunquoted command arguments, associative array s=
ubscripts, almost=0Aeverything but variable names for assignment or expa=
nsion) could=0Asimply be expanded to allow UTF-8 in parameter names as w=
ell. I think=0Ait would be BETTER to have an implementation that explici=
tly=0Aestablishes source file encoding and provides transcoding in some=
=0Acases, provide validation of the character encoding, and to support=
=0AUnicode whitespace, at least, as part of the language syntax...=C2=A0=
 But=0Awe could also just keep things as they are, except allow bytes ou=
tside=0Athe ASCII range to be part of variable names in assignment and=
=0Aparameter expansion.=0A=0A----- Original Message -----=0AFrom: "dualb=
us" <dualbus@gmail.com>=0ATo:"L A Walsh" <bash@tlinx.org>=0ACc:"bug-bash=
" <bug-bash@gnu.org>=0ASent:Thu, 1 Jun 2017 23:52:55 -0500=0ASubject:Re:=
 RFE: Please allow unicode ID chars in identifiers=0A=0A Please remember=
 that there's always a *cost* associated with=0A new features:=0A=0A - S=
omeone has to do the work of extending the current lexer / parser=0Ato=
=0A be able to ingest multibyte character sequences. It helps a bunch if=
=0A you do that work, and submit it for review.=0A=0A - People then have=
 to test the new implementation, to ensure that=0Athere=0A are no regres=
sions, and no new bugs introduced. I'm happy to=0Avolunteer=0A once ther=
e's a working implementation.=0A=0A - There are some questions that must=
 be answered first:=0A=0A * How do you how to decode multibyte character=
 sequences into=0AUnicode? =0A Should UTF-8 be assumed?=0A=0A * Will the=
 parsing of a script depend upon the user locale?=0A=0A * Should this sp=
ecial parsing code be disabled if POSIX mode is=0A enabled?=0A=0A * Righ=
t now `name' or `identifier' is defined as:=0A=0A name: A word consistin=
g only of alphanumeric characters and=0A underscores, and beginning with=
 an alphabetic character or an=0A underscore. Also referred to as an ide=
ntifier.=0A=0A How will the definition look like with Unicode identifier=
s?=0A=0A > Variable names like:=0A > =0A > L=C4=93v -- (3 letter word pr=
onounced like Leave), (most recent try...)=0A=0A Use `Lev'.=0A=0A > stri=
ng constants:=0A > $=CE=A6=3D"0.618033988749894848"=0A > $=C9=B8=3D"1.61=
803398874989485"=0A > $=CF=80=3D"3.14159265358979324"=0A > $=E2=90=89=3D=
$'x09'=0A > $=E2=85=AC=3D50 $=E2=85=AD=3D100 $=E2=85=AE=3D500 $=E2=85=AF=
=3D1000=0A > $=E2=85=A0=3D1 $=E2=85=A4=3D5 $=E2=85=A9=3D10=0A > $=E3=8E=
=8F=3D"kilogram"=0A > $=E3=8E=86=3D1024*$=E3=8E=85,=0A > etc...=0A=0A Wh=
at prevents you from using?=0A=0A phi=3D'...'=0A pi=3D'...'=0A ht=3D'...=
'=0A kg=3D'...'=0A=0A I'm still not convinced there's an actual need her=
e.=0A=0A -- =0A Eduardo Bustamante=0A https://dualbus.me/=0A=0A

From MAILER-DAEMON Fri Jun 02 18:24:13 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGuzN-0006j5-J9
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 18:24:13 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52392)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGuzL-0006io-AW
	for bug-bash@gnu.org; Fri, 02 Jun 2017 18:24:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dGuzH-0004tf-DA
	for bug-bash@gnu.org; Fri, 02 Jun 2017 18:24:11 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:57822
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dGuzG-0004rZ-Uz
	for bug-bash@gnu.org; Fri, 02 Jun 2017 18:24:07 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v52MNwF4046054; Fri, 2 Jun 2017 15:24:00 -0700
Message-ID: <5931E57E.8090801@tlinx.org>
Date: Fri, 02 Jun 2017 15:23:58 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>
	<20170602121541.GP7764@eeg.ccf.org>
In-Reply-To: <20170602121541.GP7764@eeg.ccf.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 02 Jun 2017 22:24:12 -0000

Greg Wooledge wrote:
> On Thu, Jun 01, 2017 at 09:31:24PM -0700, L A Walsh wrote:
>   
>> Variable names like:
>>
>> L??v -- (3 letter word pronounced like Leave), (most recent try...)
>>     
>
> Here is a demonstration of the cost of what you are proposing.  In my
> mail user agent, your variable shows up as L??v.
>
> Source code with your UTF-8 identifiers would no longer even be READABLE
> on systems that do not use UTF-8.  Like the system I am using RIGHT NOW,
> which uses Latin-1.  But also like Windows systems using WIN1252, Asian
> systems using Big5, etc.
>
> Maybe you can try again after 2038, which will probably take out most
> of these old systems.  Perhaps then the world will actually be capable
> of moving beyond ASCII as a UNIVERSAL encoding.  Today, we're not.
>
>   
That's ok... I want to "encrypt" and/or obfuscate my code... ;-)

Seriously, if it was representable in your latin-1, you could
run iconv over it.

That particular example should translate to latin-1 w/no problem.

As for unsupported systems, there is a reason they are no longer
supported.  The world is already using UTF-8.  It's only a few
luddites clinging to ascii as a last refuge. ;-)

What display/OS do you have that you can't run UTF-8 on?

linux systems and windows systems have had UTF-8 for at least the
last 7 years or more.






From MAILER-DAEMON Fri Jun 02 20:30:30 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dGwxa-0005TO-Nz
	for mharc-bug-bash@gnu.org; Fri, 02 Jun 2017 20:30:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48846)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <svashish@redhat.com>) id 1dGwxY-0005Sw-AY
	for bug-bash@gnu.org; Fri, 02 Jun 2017 20:30:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <svashish@redhat.com>) id 1dGwxT-0006R7-De
	for bug-bash@gnu.org; Fri, 02 Jun 2017 20:30:28 -0400
Received: from mx1.redhat.com ([209.132.183.28]:56456)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <svashish@redhat.com>) id 1dGwxT-0006P3-4r
	for bug-bash@gnu.org; Fri, 02 Jun 2017 20:30:23 -0400
Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com
	[10.5.11.16])
	(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.redhat.com (Postfix) with ESMTPS id F0D5BC04B939
	for <bug-bash@gnu.org>; Sat,  3 Jun 2017 00:30:20 +0000 (UTC)
DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com F0D5BC04B939
Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com;
	dmarc=none (p=none dis=none) header.from=redhat.com
Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com;
	spf=pass smtp.mailfrom=svashish@redhat.com
DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com F0D5BC04B939
Received: from colo-mx.corp.redhat.com
	(colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21])
	by smtp.corp.redhat.com (Postfix) with ESMTPS id E63D61822B
	for <bug-bash@gnu.org>; Sat,  3 Jun 2017 00:30:20 +0000 (UTC)
Received: from zmail23.collab.prod.int.phx2.redhat.com
	(zmail23.collab.prod.int.phx2.redhat.com [10.5.83.28])
	by colo-mx.corp.redhat.com (Postfix) with ESMTP id C67D34BB74
	for <bug-bash@gnu.org>; Sat,  3 Jun 2017 00:30:20 +0000 (UTC)
Date: Fri, 2 Jun 2017 20:30:20 -0400 (EDT)
From: Siteshwar Vashisht <svashisht@redhat.com>
To: bug-bash@gnu.org
Message-ID: <1340395993.15391170.1496449820570.JavaMail.zimbra@redhat.com>
In-Reply-To: <976825442.15391057.1496449453997.JavaMail.zimbra@redhat.com>
Subject: test builtin does not check for nanoseconds while comparing timestamps
MIME-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_15391168_630645617.1496449820565"
X-Originating-IP: [10.40.204.18, 10.4.195.2]
Thread-Topic: test builtin does not check for nanoseconds while comparing
	timestamps
Thread-Index: W6DRiL+OM+J4cYlhDq52PZXvD7HQ/g==
X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16
	(mx1.redhat.com [10.5.110.31]);
	Sat, 03 Jun 2017 00:30:21 +0000 (UTC)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 209.132.183.28
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 00:30:29 -0000

------=_Part_15391168_630645617.1496449820565
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-redhat-linux-gnu' -DCONF_VENDOR='redhat' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H   -I.  -I. -I./include -I./lib  -D_GNU_SOURCE -DRECYCLES_PIDS -DDEFAULT_PATH_VALUE='/usr/local/bin:/usr/bin'  -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic
uname output: Linux localhost.localdomain 4.10.17-200.fc25.x86_64 #1 SMP Mon May 22 18:12:57 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-redhat-linux-gnu

Bash Version: 4.3
Patch Level: 43
Release Status: release

Description:
        If the modified timestamp of 2 files differ by less than 1 second, test builtin sometimes returns incorrect result. It happens because HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC is not defined in config.h.

Repeat-By:
        while true; do touch a; sleep 0.1; touch b; stat a b|grep Modify; [ b -nt a ] && echo test_cmd_ok || echo test_cmd_failed; echo; done
        

Fix:
        Attached patch fixes this issue.

-- 
--
Siteshwar Vashisht

------=_Part_15391168_630645617.1496449820565
Content-Type: text/x-patch;
 name=0001-Fix-macro-check-for-struct-stat.st_atim.tv_nsec.patch
Content-Disposition: attachment;
 filename=0001-Fix-macro-check-for-struct-stat.st_atim.tv_nsec.patch
Content-Transfer-Encoding: base64

RnJvbSAyNjQ4YWZlYjRlMmJhZTRlMjUwNzAwYzhmYjM3ZTJhYTY0YzgyYjExIE1vbiBTZXAgMTcg
MDA6MDA6MDAgMjAwMQpGcm9tOiBTaXRlc2h3YXIgVmFzaGlzaHQgPHN2YXNoaXNodEByZWRoYXQu
Y29tPgpEYXRlOiBTYXQsIDMgSnVuIDIwMTcgMDE6Mzc6MDggKzAyMDAKU3ViamVjdDogW1BBVENI
XSBGaXggbWFjcm8gY2hlY2sgZm9yIHN0cnVjdCBzdGF0LnN0X2F0aW0udHZfbnNlYwoKLS0tCiBj
b25maWcuaC5pbiB8IDEgKwogMSBmaWxlIGNoYW5nZWQsIDEgaW5zZXJ0aW9uKCspCgpkaWZmIC0t
Z2l0IGEvY29uZmlnLmguaW4gYi9jb25maWcuaC5pbgppbmRleCBiNWMzNWMzLi4xZTRiNzFkIDEw
MDY0NAotLS0gYS9jb25maWcuaC5pbgorKysgYi9jb25maWcuaC5pbgpAQCAtNDUyLDYgKzQ1Miw3
IEBACiAjdW5kZWYgU1lTX1RJTUVfSF9ERUZJTkVTX1NUUlVDVF9USU1FU1BFQwogI3VuZGVmIFBU
SFJFQURfSF9ERUZJTkVTX1NUUlVDVF9USU1FU1BFQwogCisjdW5kZWYgSEFWRV9TVFJVQ1RfU1RB
VF9TVF9BVElNX1RWX05TRUMKICN1bmRlZiBUWVBFT0ZfU1RSVUNUX1NUQVRfU1RfQVRJTV9JU19T
VFJVQ1RfVElNRVNQRUMKICN1bmRlZiBIQVZFX1NUUlVDVF9TVEFUX1NUX0FUSU1FU1BFQ19UVl9O
U0VDCiAjdW5kZWYgSEFWRV9TVFJVQ1RfU1RBVF9TVF9BVElNRU5TRUMKLS0gCjIuOS40Cgo=
------=_Part_15391168_630645617.1496449820565--


From MAILER-DAEMON Sat Jun 03 04:20:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dH4Ia-0004SX-Nr
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 04:20:40 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51502)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dH4IY-0004SO-MF
	for bug-bash@gnu.org; Sat, 03 Jun 2017 04:20:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dH4IV-0002Bc-F1
	for bug-bash@gnu.org; Sat, 03 Jun 2017 04:20:38 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:52314
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dH4IV-0002AE-7S
	for bug-bash@gnu.org; Sat, 03 Jun 2017 04:20:35 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v538KPWe088953; Sat, 3 Jun 2017 01:20:27 -0700
Message-ID: <59327149.6000007@tlinx.org>
Date: Sat, 03 Jun 2017 01:20:25 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
CC: dualbus <dualbus@gmail.com>, tetsujin@scope-eye.net
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>	<20170602045255.4uqtbnsxryrfc432@debian>	<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>
In-Reply-To: <20170602131846.rclunctr5ri2s4jr@debian>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v538KPWe088953
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 08:20:39 -0000


 "Every technical field -- and most nontechnical fields -- has developed
  conventional shorthand notation to make convenient the presentation and
  discussion involving frequently used concepts.  For example, because=20
of long
  acquaintance,

      x+y*z

  is clearer to us than

      multiply y by z and add the result to x

  It is hard to overestimate the importance of concise notation for commo=
n
  operations."
-----

The symbols of specific fields and common to speakers in other languages=20
express their meaning more concisely than spelling out words that may or=20
may not have the meaning associated with the symbol.  Indeed, it is said=20
that a picture is worth a thousand words.  In this case the exact symbol=20
is worth more than associated words that are spelled out.

It's thought that having to translate eidetic concepts to abstract=20
letters interferes with comprehension and communication.

If those aren't valid -- and essential reasons to support those extended=20
symbols, I don't know what would be.

The passage above I stumbled upon by accident while reviewing concept
in the author's book.  The author: Bjarne Stroustrup in the C++11, fourth
edition of "The C++ Programming Language".=20

You may not believe me, but Stroustrup is saying the same thing.  The=20
symbols native to a discipline provide for faster and more accurate=20
communication --
as in getting across concepts.

Also to respond to tetsujin: shorter normalization forms are preferred ov=
er
longer forms. There are formulaic ways of determining the proper form tha=
t
are well suited to a computer that can apply the rules very quickly.

Some conventions regarding character set usage have already been "solved"
and encoded in binary properties of the characters.  For example, the
start and continue "ID" properties are best associated with names used
for variables.  And while the symbol for pi (=F0=9D=9B=91) may look simil=
ar, it would
most likely be used where numbers (and numeric constants) are used, while
the greek letter would be used in identifiers.

I'm glad some people are willing to discuss things rather than run around
asserting that the sky will *cost* something ... Whether or not it cost
something shouldn't prevent people from forming ideas that that they migh=
t
find desirable in the future.  It certainly doesn't mean such features ar=
e
expected next month, or even "anytime" by a specific person (if they have
no interest in the work) I'd support them not doing it as long as they
allow someone more interested to do the work.  Being open to doing it
yourself isn't required to be open to seeing something grow in specific
directions...

-l









From MAILER-DAEMON Sat Jun 03 14:00:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHDLh-0003Ma-Jm
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 14:00:29 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40701)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dHDLf-0003MO-4T
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:00:28 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dHDLb-0005sd-3k
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:00:27 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:41464
	helo=homiemail-a92.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dHDLa-0005q5-NO
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:00:23 -0400
Received: from homiemail-a92.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTP id B13F2801B031; 
	Sat,  3 Jun 2017 11:00:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=UTTA5cYNhRKrpcU5
	Wnk8UAXku4Q=; b=qaV7+6syibj5zoIaGiLeq9dZZh8m/uLT9Adnrs/exwXtbDfV
	bnAyHKcl73FtcJD83ue3vkDIAHDyMcjN9EJbS2fwdBQMabsswiElGDjwqCdN4QEO
	xLDQL5PcaEgA2PIByMWTyJlHJBIeJQb/KtJGErndL1XwOEc4bbA26YcUuPg=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTPSA id 48461801B038;
	Sat,  3 Jun 2017 11:00:18 -0700 (PDT)
Message-ID: <1496512817.17253.69.camel@scope-eye.net>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
From: George <tetsujin@scope-eye.net>
To: L A Walsh <bash@tlinx.org>, bug-bash <bug-bash@gnu.org>
Cc: dualbus <dualbus@gmail.com>
Date: Sat, 03 Jun 2017 14:00:17 -0400
In-Reply-To: <59327149.6000007@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 18:00:28 -0000

On Sat, 2017-06-03 at 01:20 -0700, L A Walsh wrote:
> Some conventions regarding character set usage have already been "solve=
d"
> and encoded in binary properties of the characters.=C2=A0=C2=A0For exam=
ple, the
> start and continue "ID" properties are best associated with names used
> for variables.=C2=A0
Referring to "Unicode Identifier and Pattern Syntax", I guess:
http://unicode.org/reports/tr31
>  And while the symbol for pi (=F0=9D=9B=91) may look similar, it would
> most likely be used where numbers (and numeric constants) are used, whi=
le
> the greek letter would be used in identifiers.
>=20
>=20

On some fonts, the two may look not only similar, but identical. I brough=
t it up mainly to acknowledge that there are some issues in Unicode handl=
ing
that make this issue potentially more complicated than "don't disallow it=
". In my opinion, to do it right the syntax should recognize Unicode
whitespace at least, which in turn requires an explicit decision that the=
 source text is Unicode (and not generically-processed byte sequences out=
side
the ASCII range)
(The question of whether to support Unicode mathematical operators or Uni=
code quotation marks introduces a lot of interesting possibilities - but
that's a whole other ball of wax)
Problems like Unicode normalization, and questions of what constitutes eq=
uivalency in the scope of the programming language can complicate things.
There's a series of trade-offs between keeping the implementation relativ=
ely simple vs. supporting equivalency where the user may reasonably expec=
t
it. There's potential for something like this to get complicated, dependi=
ng on how far the design goes in supporting equivalency for semi-redundan=
t
Unicode characters. I don't think a programming language necessarily need=
s to go too far down that rabbit hole, really, but I wanted to acknowledg=
e
the issue.
> I'm glad some people are willing to discuss things rather than run arou=
nd
> asserting that the sky will *cost* something ... Whether or not it cost
> something shouldn't prevent people from forming ideas that that they mi=
ght
> find desirable in the future.  It certainly doesn't mean such features =
are
> expected next month, or even "anytime" by a specific person (if they ha=
ve
> no interest in the work) I'd support them not doing it as long as they
> allow someone more interested to do the work.  Being open to doing it
> yourself isn't required to be open to seeing something grow in specific
> directions...
>=20
>=20

To be fair, that reaction is understandable. When someone like me shows u=
p and starts trying to influence the direction of a project, even when I
contribute code to produce the changes I want to see in the project, will=
 I be the one maintaining that code in 5 years? To be quite honest in my =
case
the answer is almost certainly "no". When I advocate for a feature to be =
added to Bash, I am probably not going to be paying the bulk of the price=
 for
it. Willingness to contribute code is a very low bar.
But speaking vaguely about "the future" and open-ended expectations with =
respect to time is probably counterproductive. As it is, Bash bug reports=
 and
feature requests are neglected for years on end, new features make their =
way to Bash years after they're pioneered in ksh. A vague "in the future"
could easily find us back here, ten years from now, still wondering when =
Bash will support Unicode in parameter names. Best we can do is make a go=
od
case for the features we want to see integrated, and do as much as we can=
 to at least reduce the _initial_ cost of the feature.

From MAILER-DAEMON Sat Jun 03 14:46:37 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHE4L-0003Wd-NP
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 14:46:37 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47413)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHE4J-0003WH-6y
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:46:35 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHE4G-0005On-5Y
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:46:35 -0400
Received: from mail-pf0-x229.google.com ([2607:f8b0:400e:c00::229]:36207)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dHE4F-0005Nc-Vi
	for bug-bash@gnu.org; Sat, 03 Jun 2017 14:46:32 -0400
Received: by mail-pf0-x229.google.com with SMTP id m17so65495939pfg.3
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 11:46:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=6n6oc8EE2Qyqa+GJzj5T173snGRhzzykM0uSCsfOcKU=;
	b=ML3Mw4UwYImJviI3ZlTKn9mLs+buDnNrQ1pRxcbI80qf4H5VYjVia3mEhzkfxeitW0
	0F1QuVHTRmeDZcgK+5Evo6xk1ZUAT1/nEcSQAT9WOi8zqkmUoniuv3sebwL2yeMG0SnW
	mTMm4eDBgldftqxMgyIj6KJm3SU5e6UcMEiycupCy+5pOxLBt1nJGARdYRcFaNR4Icyc
	oxLCOUZPW2qeCOKn/B8nQ6ORSwt6bSE+0aMYhFtqnCMM1TcHX47EAzV1NTf4/xj6PJiN
	0/hMkdLpb+j40X46r8AJQkLWrHCVA3o6yU9TcGe2+bKqnB7w4C+o+oOTgU4Gb56SpZEg
	miGg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=6n6oc8EE2Qyqa+GJzj5T173snGRhzzykM0uSCsfOcKU=;
	b=SOsLF4BZT17VMmIm6yoopNSc7nwLbT0ifgbzzSt6W6qMviHimFsyrRxIhSz/efCdVC
	/5ket07cwS6lq/FiRrt/DlDtLsz32oc6vds8wJ2thPSmZHfP8DFG08RhMhhe4e0rvyfJ
	h+VETA1ys0VcLkbQqpnFRj7/NHKNshg4S3/PSZ2p7ZoKSd7vLeBnx/oz60PVZB9dgb/8
	2B0xmWsUiBZpgoXxbCS06MiCS5Hnv8oteXAIRUhwQ/RjyP0xzyTzZWw81qbFeueAkfnI
	RmJkUjNsIv17S5qhJYhG7MFbALYHlDRAkJR6U7rOTpRyHP9sAZ9k4vc58kojdnG4++55
	PL0A==
X-Gm-Message-State: AODbwcDGrIDPKPZLsOEfsrxiv5He0xzZTMUJUii+k31gVH36yH9ECsi1
	Pug2QFO33QDoJcYd
X-Received: by 10.98.217.7 with SMTP id s7mr12566090pfg.39.1496515589284;
	Sat, 03 Jun 2017 11:46:29 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.59.122])
	by smtp.gmail.com with ESMTPSA id
	r68sm46758623pfd.91.2017.06.03.11.46.25 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Sat, 03 Jun 2017 11:46:27 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
Message-ID: <b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
Date: Sun, 4 Jun 2017 01:46:23 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496512817.17253.69.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 18:46:36 -0000

On 04/06/2560 01:00, George wrote:
> There's a series of trade-offs between keeping the implementation relatively simple vs. supporting equivalency where the user may reasonably expect
> it.
I will personally never use non-ascii in a bash script, even though I
use unicode extensively, also in the shell.

But the fact that unicode functions are already supported does seem to
pave the way for allowing variable names in unicode. For consistency, it
should really be the same handling as function names -- I am expecting
no equivalency support in the current function name implementation, and
I am also guessing that many types of non-ascii space are also allowed
in function names already. Which does makes sense: if people want to
shoot themselves in the foot by using similar/same looking but actually
different glyphs and spaces, it would be too tiresome to try to prevent
that.

Peter


From MAILER-DAEMON Sat Jun 03 16:15:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHFSe-0004jD-Bh
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 16:15:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59434)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <deshpande.v.pranav@gmail.com>) id 1dHFSc-0004j5-FW
	for bug-bash@gnu.org; Sat, 03 Jun 2017 16:15:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <deshpande.v.pranav@gmail.com>) id 1dHFSb-0000X5-NP
	for bug-bash@gnu.org; Sat, 03 Jun 2017 16:15:46 -0400
Received: from mail-ua0-x22f.google.com ([2607:f8b0:400c:c08::22f]:33017)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <deshpande.v.pranav@gmail.com>)
	id 1dHFSb-0000Wa-He
	for bug-bash@gnu.org; Sat, 03 Jun 2017 16:15:45 -0400
Received: by mail-ua0-x22f.google.com with SMTP id x47so59959346uab.0
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 13:15:43 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=nSBnMJFDrvl09pikGSa/KfZ/VtymBhLrEsSHWe0cnLQ=;
	b=sdwlGxwAgzHzcLJ8+SxbBaWrZfGYej/CekkP6CS/eVGOL/z2+A7uo9vGgdi2HeFn6v
	uB3iFel8T1sjQCxQBtfeHERalcF4Yy9u1r/oLVWqIHAsUPY7fPa+ykMGZctKkLbhIhYw
	CDZqxm2q0zHm8QCeSoxlQt9pnkYSb9VCOztneE2nMWxKjVvywjmrVAsBlQeP5A7Khvaz
	DJbgvxYa3YJZtsi6xvVLScYExkiLuJ/psn0ViOi+na4fSDltsXlLRhT1BmDf3+6/ol8d
	8oLiEIckhS7aym3YcnlJkKLGEk+eIvdI4eIjUoox9RzEwSbn3jwfzO5nbEUU26R8B5a7
	eTIQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=nSBnMJFDrvl09pikGSa/KfZ/VtymBhLrEsSHWe0cnLQ=;
	b=i14+dYOtwIlJiUDJQMYWEoXm+VtTzlY76sGpoFJV7azgzsLrSjx0aNNfoL2xOsuirG
	HWTruyKyVTE95i+McAQd4Mpfa7AyXHko/VvNiwJWq1869ibu+AT0dzSLq4VRqM7Slv8h
	iphQHjD9k+M7a7qwAyv7xZBCNLmdz5g1BGlt3IHXrAiYPdsmBqdofgommKUH17M1s2ie
	+5FJUsVKlhqOJNhAd1A7TiHTlA56XBAFydi25QkFD69mQ10eXF0BrSMl9N/+H5vYmUo1
	z3Ae07Tzeck+zAuzC2atupKwudOcWSIegacqQvWv/Gox0VmTE75MQYUvHIhJfwcC6dLv
	6CXA==
X-Gm-Message-State: AODbwcA53KfIyipEz9Zy+WMSh00VakAia+TJBylfrsZ3nagnLtidfxu5
	TFP6QMyOJJ4C4nO7ALTE1ZcW0WjUwg==
X-Received: by 10.176.17.216 with SMTP id q24mr3059708uac.96.1496520943108;
	Sat, 03 Jun 2017 13:15:43 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.176.90.197 with HTTP; Sat, 3 Jun 2017 13:15:42 -0700 (PDT)
In-Reply-To: <CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
References: <CAOSMAut1aPYc6XzMBBUjmvUVj8MNcuVCcVZBV=2zay6q-V0Z6Q@mail.gmail.com>
	<2d102524-0a27-ef61-1cb0-48a538e5db6c@case.edu>
	<CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
From: Pranav Deshpande <deshpande.v.pranav@gmail.com>
Date: Sun, 4 Jun 2017 01:45:42 +0530
Message-ID: <CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
Subject: Re: Builtin read with -n0 or -N0 (nchars == 0) behaves as a read with
	no -n/-N argument
To: Chester Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org, Eduardo Bustamante <dualbus@gmail.com>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400c:c08::22f
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 20:15:47 -0000

Hello,
Sorry for the late reply.

My solution is to change *line 294* of builtins/read.def.

Change
if (code == 0 || *intval < 0* || intval != (int)intval)

to

if (code == 0 || i*ntval <= 0* || intval != (int)intval)

Command:

./bash -c 'read -n0 <<< "abc";declare -p REPLY'

Output:
./bash: line 0: read: 0: invalid number
./bash: line 0: declare: REPLY: not found

i.e. behaviour #1.

Is this solution ok?

Regards,
Pranav

From MAILER-DAEMON Sat Jun 03 17:48:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHGuX-0001Pk-FU
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 17:48:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44594)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHGuV-0001Pd-If
	for bug-bash@gnu.org; Sat, 03 Jun 2017 17:48:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHGuQ-000601-HJ
	for bug-bash@gnu.org; Sat, 03 Jun 2017 17:48:39 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:55170
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dHGuP-0005vs-Vq
	for bug-bash@gnu.org; Sat, 03 Jun 2017 17:48:34 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v53LmNRr050864; Sat, 3 Jun 2017 14:48:25 -0700
Message-ID: <59332EA7.2060008@tlinx.org>
Date: Sat, 03 Jun 2017 14:48:23 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>	<20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
In-Reply-To: <5931E57E.8090801@tlinx.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 03 Jun 2017 21:48:40 -0000


> Greg Wooledge wrote:
>> Here is a demonstration of the cost of what you are proposing.  In my
>> mail user agent, your variable shows up as L??v.
>>
>> Source code with your UTF-8 identifiers would no longer even be 
>> READABLE  
>
> What display/OS do you have that you can't run UTF-8 on?

    Still curious - - -> me.  :-)



From MAILER-DAEMON Sat Jun 03 21:34:04 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHKQe-0004XV-Nz
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 21:34:04 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39707)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dHKQd-0004XP-7J
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:34:04 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dHKQc-0005uR-CY
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:34:03 -0400
Received: from mail-pg0-x230.google.com ([2607:f8b0:400e:c05::230]:36429)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <john.archie.mckown@gmail.com>)
	id 1dHKQc-0005rl-5O
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:34:02 -0400
Received: by mail-pg0-x230.google.com with SMTP id x64so21241858pgd.3
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 18:34:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=9Xr+mUg9a4taeUeYeoPN2dCKmLRbx6Ii119vJhjDXNU=;
	b=OcLV21uISN1sv6Ss7HOIt7rX0d+V31mMqdWA2fc06AMti/MFvA0So0tLqspRpD9LdM
	gesV4NDiaKkcBvwtwk7+9v/t6WPSOUoTpQRDxqFICVuuffZpp73eDryFwR9tI5BKIFCH
	sS/CeoPlhLS153N08IuDuJDMTt/08+KoV0HCKIRnx4L+KDkGlJLqVZGdiNZvYTlU35c7
	6hMTgDek2O1RJyRxHz+hJN4E33zzvDF7bREwi3OsCqnAb3q/EuncKAamfMV/fYYY2UV6
	2ACOosNP0qIxTsMZ8qjCodthEJtmFhe4rm7FvTnQAu/10mWhdJw8gA0FylR0aNm8qgbk
	WWRw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=9Xr+mUg9a4taeUeYeoPN2dCKmLRbx6Ii119vJhjDXNU=;
	b=fe7NapBiSdrxrJNmJIfGv+KPWp73wvwcF5V/mxi/yRXJIgos+Vv12HMJ7MbdZx6kKm
	D1sGbQiJ+9NF8ZOR0gnwdK8QkK+RF2L7OWa+3nrG6HBgV0yfp2WQbcx6kfV43G5w46w7
	a8LBV34Sbnf8LCopZpzJG8KuAdipXn+yQSPY13EVTbCfu3TL7rFkgP+Ea2TtNkziZXkU
	/lggNaaeAKgivO90jzJF2IM5PhWAR2oMEs60DmHQrQhE26b5a4zcVu7uBnlaKGBIy8OI
	kf0lE1xzxse/tQVdfsdFdc2IXdafaKUksDXKjvntv4Ea1VHAZm8eVZlPv0OmpgyjxTWy
	e0fg==
X-Gm-Message-State: AODbwcBIYNyXnQkU9QNipLAcPeK5/Sb+YqiFRceI2AJSMCARoTnKmRXH
	1GyVPPF3WginbQyU0AdsGFR9YKFGVw==
X-Received: by 10.84.171.193 with SMTP id l59mr7767507plb.139.1496540039665;
	Sat, 03 Jun 2017 18:33:59 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.167.48 with HTTP; Sat, 3 Jun 2017 18:33:59 -0700 (PDT)
In-Reply-To: <59332EA7.2060008@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org> <59332EA7.2060008@tlinx.org>
From: John McKown <john.archie.mckown@gmail.com>
Date: Sat, 3 Jun 2017 20:33:59 -0500
Message-ID: <CAAJSdjiy3ith+mQy11GXGVzhdmYh8u-0Hb0KH5mbuQs+Y9Lh+Q@mail.gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
Cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::230
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 01:34:04 -0000

On Sat, Jun 3, 2017 at 4:48 PM, L A Walsh <bash@tlinx.org> wrote:

>
> Greg Wooledge wrote:
>>
>>> Here is a demonstration of the cost of what you are proposing.  In my
>>> mail user agent, your variable shows up as L??v.
>>>
>>> Source code with your UTF-8 identifiers would no longer even be
>>> READABLE
>>>
>>
>> What display/OS do you have that you can't run UTF-8 on?
>>
>
>    Still curious - - -> me.  :-)
>
>
=E2=80=8BOK, I did a port of BASH to an IBM "mainframe" system (IBM z) whic=
h uses
EBCDIC as it's character set, rather than ASCII or UNICODE. Granted, this
system is a very minor player to most people. OTOH, most "Fortune 500"
companies will have one or more "hidden away" doing some "legacy" work and,
now, perhaps even some mobile (smartphone, tablet) back end work. There is
another mid-range IBM system which also uses EBCDIC, but I don't know if it
has a BASH port or not.=E2=80=8B



--=20
Windows. A funny name for a operating system that doesn't let you see
anything.

Maranatha! <><
John McKown

From MAILER-DAEMON Sat Jun 03 21:52:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHKi8-0007QL-3G
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 21:52:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41854)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHKi5-0007QE-MX
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:52:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHKi2-0003OP-MP
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:52:05 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:36470
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dHKi2-0003Lf-Fc
	for bug-bash@gnu.org; Sat, 03 Jun 2017 21:52:02 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v541pqth063880; Sat, 3 Jun 2017 18:51:54 -0700
Message-ID: <593367B8.1050108@tlinx.org>
Date: Sat, 03 Jun 2017 18:51:52 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: John McKown <john.archie.mckown@gmail.com>
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org> <59332EA7.2060008@tlinx.org>
	<CAAJSdjiy3ith+mQy11GXGVzhdmYh8u-0Hb0KH5mbuQs+Y9Lh+Q@mail.gmail.com>
In-Reply-To: <CAAJSdjiy3ith+mQy11GXGVzhdmYh8u-0Hb0KH5mbuQs+Y9Lh+Q@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v541pqth063880
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 01:52:07 -0000



John McKown wrote:
> On Sat, Jun 3, 2017 at 4:48 PM, L A Walsh <bash@tlinx.org=20
> <mailto:bash@tlinx.org>> wrote:
>
>
>         Greg Wooledge wrote:
>
>             Here is a demonstration of the cost of what you are
>             proposing.  In my
>             mail user agent, your variable shows up as L??v.
>
>             Source code with your UTF-8 identifiers would no longer
>             even be READABLE=20
>
>
>         What display/OS do you have that you can't run UTF-8 on?
>
>
>        Still curious - - -> me.  :-)
>
>
> =E2=80=8BOK, I did a port of BASH to an IBM "mainframe" system (IBM z) =
which=20
> uses EBCDIC as it's character set, rather than ASCII or UNICODE.=20
> Granted, this system is a very minor player to most people. OTOH, most=20
> "Fortune 500" companies will have one or more "hidden away" doing some=20
> "legacy" work and, now, perhaps even some mobile (smartphone, tablet)=20
> back end work. There is another mid-range IBM system which also uses=20
> EBCDIC, but I don't know if it has a BASH port or not.=E2=80=8B
I know that perl which supports an ebcdic flavored machines, has full
UTF-8 support now -- they were one of the first -- about 10 years ago,
but no one uses ebcdic outside of ibm machines -- and those are not
consumer or home level machines.

I'm surprised you got bash ported to work with that charset though,
and certainly I can't imagine you using an ebcdic machine as a home
machine....are you?


From MAILER-DAEMON Sat Jun 03 22:20:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHLA2-0004mN-UL
	for mharc-bug-bash@gnu.org; Sat, 03 Jun 2017 22:20:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43993)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHLA0-0004m2-KT
	for bug-bash@gnu.org; Sat, 03 Jun 2017 22:20:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHL9w-0001on-Lj
	for bug-bash@gnu.org; Sat, 03 Jun 2017 22:20:56 -0400
Received: from mail-pg0-x230.google.com ([2607:f8b0:400e:c05::230]:35848)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dHL9w-0001oC-EM
	for bug-bash@gnu.org; Sat, 03 Jun 2017 22:20:52 -0400
Received: by mail-pg0-x230.google.com with SMTP id x64so21416651pgd.3
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 19:20:52 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:to:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=pDs+Gw9fYFOAkG975s6l9rsGIHncbQedDtRh68ml2xc=;
	b=hIvllgbCohPb9b3khkR5pq+rY6Ts26tT3fU23tAhnrlxpMxfLP3zsb21/l6Wk3iRVP
	J0HzHvLHVrV6jIzcl85AOtPFSLefQSMnUgilOqyCo/QM0P9HccxvlQ0FcYs6h1UJE2Br
	GQgb3hsIG/jI5L+AhPGJRVkoP22kIM632xeWIWoDDyjp4n/QDO7uR3uJwxCodmHmpkeO
	2m0mQi9t7EKjMA0AP8Djwmhtj8u+X/ZtQXm3/2BM8DxxWyJ/PFutJKmfx0yRYiSVUtpt
	S/DSv8H2AxRT4fRjkv7TxzvIrzRaDwCqvStttPVdDPopfqgMogU25BPevqWsArdpOQKH
	CLog==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:to:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=pDs+Gw9fYFOAkG975s6l9rsGIHncbQedDtRh68ml2xc=;
	b=Gx/s4bdq2rxW2iOhZTJr3/4BjMmDQ6YoJxTtUEu+lZFvN6WcT30yTnNlq0w1JnY2Xw
	TmzexDWMqWB54hEAH7vwn7PkwCy+ut5ODToDL+77GpbFUAfvJM2BKPFQ9lLtDTBSz1WY
	4Vl7ZMoXm0HkhV1/bW67C2uCN154693Cx+B0yvW5ZBU81UubKEO3QRCuZzaz2EOK/f+u
	SgAw+KScMgzUQUFC8hjFyE7dx6X2QyhIk2biwk9ykWhXVBhO9p6LMBZpqn2406YMPVZw
	SCK+yvIs1FnEHO4S5kQXton114uUjIb2nsd+K6BGgVPn97zupuMCJofdyfTB2HRIf9AW
	kA6w==
X-Gm-Message-State: AODbwcBXP5NvZxTk6OyVFCqr/QOJJXAR9TB07j1N+UEqnCs1ltmr5PRP
	orMp8wFW7o3ZzfNo
X-Received: by 10.101.72.207 with SMTP id o15mr14455826pgs.212.1496542851151; 
	Sat, 03 Jun 2017 19:20:51 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.59.122])
	by smtp.gmail.com with ESMTPSA id
	p76sm49458338pfa.53.2017.06.03.19.20.48
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Sat, 03 Jun 2017 19:20:49 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
Cc: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org> <59332EA7.2060008@tlinx.org>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <12215b64-16c4-dc48-3ab1-945b80eb9b13@passchier.net>
Date: Sun, 4 Jun 2017 09:20:45 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <59332EA7.2060008@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 02:20:57 -0000

On 04/06/2560 04:48, L A Walsh wrote:
>> Greg Wooledge wrote:
>>> Here is a demonstration of the cost of what you are proposing.  In my
>>> mail user agent, your variable shows up as L??v.
>>>
>>> Source code with your UTF-8 identifiers would no longer even be
>>> READABLE  
>>
>> What display/OS do you have that you can't run UTF-8 on?

So it's his mail client: reading unicode source in their old mail client
is going to be problematic for some people...

Peter



From MAILER-DAEMON Sun Jun 04 01:16:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHNtk-0000Wc-VS
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 01:16:20 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59023)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHNtj-0000VH-4O
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:16:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHNte-0002ZA-FB
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:16:19 -0400
Received: from mail-oi0-x22f.google.com ([2607:f8b0:4003:c06::22f]:36623)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dHNte-0002YP-9P
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:16:14 -0400
Received: by mail-oi0-x22f.google.com with SMTP id h4so129426887oib.3
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 22:16:12 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=ArpRHuRzPEZDYAOsiXEh3o6QQDPcutrM8CpM2Seert4=;
	b=c9jWAUvxqi5o+QQUb+gKFwBzpeVTbXF902gqijiW+QX7PjOJS7PXDyBsb6y/EH1gp9
	s4VtR9I4fQrkg+MgqVQjzP7BC4EsoxI3cZXl4Gsn61+/eF9foaUK2sBs8bGu0h51Lc0p
	AHGgqTXtV4PDn+H1SzYfjv7rppIce7b/Z0/m1/0auE5jKABqZP6B4u2QtOF9V4G65F2g
	lqOC2e/iJPQQo1wIki1W6GKPGXuiGhOGmKMHOdggvrA6ZTnK02bk3btfqTeiH1fs83Re
	eNnEG/1bz8HuF6gjP0LZ1DzchmZE+ANewTr6Xkvl3qbFzZq06Lv3uv8AFXs/GUOpvwKP
	7Y5g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=ArpRHuRzPEZDYAOsiXEh3o6QQDPcutrM8CpM2Seert4=;
	b=DLNGn7fqoF+6wIAqvBjsYGXYbqt8El+LtQXvrtT7bO9vl+bFJ2EEFuYKopC+Y4LNaX
	nN8GtFjbHt39aia1E7YyCZrDHeqF81e1As9gGm3uN5U1BIs8+WkvpUQIOs5FdmI13te6
	LsNlzJVhQ19F1w9vkeDlVLBvNs8QnZw4sFlT4QZsFa7HzBp15uBJfZHf2r0yB1ORO6hD
	UDLTMkTq2k+ktmQeloBXNugAfDILlZv1iHIPBqiaVeDjoqGCUS8S4Rp+IxM02zYSdx/8
	6zawnYXNyKcIKimyKKWa3fdxk59HKeWcX+mT+MnHLG+XPmFAmnU7ghBUvXHtzk0n0PY9
	kUtA==
X-Gm-Message-State: AODbwcAsAnWnhveKv0WqNaX51ZLxD5eavh7DoGmEiSNeerCsxIztHIIO
	CtQkFMK2Ko+ATw==
X-Received: by 10.157.24.123 with SMTP id t56mr8676014ott.101.1496553372067;
	Sat, 03 Jun 2017 22:16:12 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	j50sm3639422otb.25.2017.06.03.22.16.11
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 03 Jun 2017 22:16:11 -0700 (PDT)
Date: Sun, 4 Jun 2017 00:16:09 -0500
From: dualbus <dualbus@gmail.com>
To: Pranav Deshpande <deshpande.v.pranav@gmail.com>
Cc: Chester Ramey <chet.ramey@case.edu>, bug-bash@gnu.org
Subject: Re: Builtin read with -n0 or -N0 (nchars == 0) behaves as a read
	with no -n/-N argument
Message-ID: <20170604051609.sd7h5z4wqkyk73r2@debian>
References: <CAOSMAut1aPYc6XzMBBUjmvUVj8MNcuVCcVZBV=2zay6q-V0Z6Q@mail.gmail.com>
	<2d102524-0a27-ef61-1cb0-48a538e5db6c@case.edu>
	<CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
	<CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 05:16:20 -0000

On Sun, Jun 04, 2017 at 01:45:42AM +0530, Pranav Deshpande wrote:
[...]
> My solution is to change *line 294* of builtins/read.def.
> 
> Change
> if (code == 0 || *intval < 0* || intval != (int)intval)
> 
> to
> 
> if (code == 0 || i*ntval <= 0* || intval != (int)intval)
[...]

> Is this solution ok?

Yes. That works.


Chet went with the other option though:

  dualbus@debian:~/src/gnu/bash-build$ ./bash -c 'read -n0; echo $?; declare -p REPLY'
  0
  declare -- REPLY=""

You can see the change by navigating the `devel' branch of the git repository
in Savannah (commit 1110e30870a8782425067a060d89cc411b014418):

  http://git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=1110e30870a8782425067a060d89cc411b014418

Although there's a problem with the solution:

  dualbus@debian:~$ for sh in bash ~/src/gnu/bash-build/bash ksh93 mksh; do $sh -c ': | read -n 0; echo $?'; done
  1
  0
  1
  1

Since the read(2) system call doesn't take place, `read -n 0' doesn't detect
the broken pipe. IMO, it should.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sun Jun 04 01:20:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHNxd-0001Y1-9c
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 01:20:21 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59500)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <deshpande.v.pranav@gmail.com>) id 1dHNxb-0001WU-1N
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:20:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <deshpande.v.pranav@gmail.com>) id 1dHNxZ-0005CL-SJ
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:20:19 -0400
Received: from mail-vk0-x235.google.com ([2607:f8b0:400c:c05::235]:32777)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <deshpande.v.pranav@gmail.com>)
	id 1dHNxZ-0005CG-Ns
	for bug-bash@gnu.org; Sun, 04 Jun 2017 01:20:17 -0400
Received: by mail-vk0-x235.google.com with SMTP id p62so19765894vkp.0
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 22:20:17 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=HLdF74JieAB8ruwC36WLt7dVZ2NDhQDkyfshpy609iI=;
	b=u3r6nR/1K13gpLRyd/J0ZBwl2C9n+RMnr+T7E1vCzrKoQ8lBlN214ZJlwJokT3IIq2
	62Zp4yjT3bn5kz8LFCsyf1mMZxQ2y26yGJTzas7wkxdLeomTj6qWt9pzftpLmLDduos9
	gvvaAh5yr+tm79bA3gw7gakI/HR2wqW2VZnNqmABstxYehQGXTjfnlEakGmd4ymO5XIW
	+YWqG+G4YYKQe3K2mDSeBg2LOz6E3TmxAz8MdoSro2wI6xvMgqCWMiMMtcraePo+f8Vw
	j2dl9FJdh6srQmCy8/orb0tYg5oaYbpSaQsovF1UChOtrDo6VA15RSXRJ9zhD9+W7Z18
	CJBg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=HLdF74JieAB8ruwC36WLt7dVZ2NDhQDkyfshpy609iI=;
	b=uQB7LPvYI4OCeg6YPChoaftSoYwjGgHV2Dhe3Nk/Zt+zVCpSIzlHPWQ3J73I4/Oa3C
	SsdQUkb2WUI2+fjObdM3ULI3i6xfoUGUpViIFOKXTjT2V0RkVsT7Bzgict+VUtwUUEo1
	vWXzNrBgfS6ptvb76gWykM+gT2hB9s47DRlUPKctWyL9+lhNsA+/4dGi83VTNROhLDPo
	RAnYhQ1dukMJuusXfB4dhl3Dmrm0nCTMrJBCZMcDforVH7TivTKt6vaB6OTTnP4sTUmY
	EmSFMGcqTuAOXIPe+li2o0ry2Fm/W9Xbyf2m32LJAoZBSbmIJn6Apk5pLUVe4BlmVDst
	YUAQ==
X-Gm-Message-State: AODbwcCN6HL7fCX6wrkpnQQ54myuMIPoQcKduOEy3zf27D7P8lYNm/HW
	YutzKh95dsNxKRlZCLRpIvOEIJhB2A==
X-Received: by 10.31.221.135 with SMTP id u129mr5856387vkg.67.1496553617119;
	Sat, 03 Jun 2017 22:20:17 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.176.90.197 with HTTP; Sat, 3 Jun 2017 22:20:16 -0700 (PDT)
In-Reply-To: <20170604051609.sd7h5z4wqkyk73r2@debian>
References: <CAOSMAut1aPYc6XzMBBUjmvUVj8MNcuVCcVZBV=2zay6q-V0Z6Q@mail.gmail.com>
	<2d102524-0a27-ef61-1cb0-48a538e5db6c@case.edu>
	<CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
	<CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
	<20170604051609.sd7h5z4wqkyk73r2@debian>
From: Pranav Deshpande <deshpande.v.pranav@gmail.com>
Date: Sun, 4 Jun 2017 10:50:16 +0530
Message-ID: <CANFkxP+4LRuGhDFO4RKNC-QyLXK5-RyUeTCm-OR=mSEP4EDHpw@mail.gmail.com>
Subject: Re: Builtin read with -n0 or -N0 (nchars == 0) behaves as a read with
	no -n/-N argument
To: dualbus <dualbus@gmail.com>
Cc: Chester Ramey <chet.ramey@case.edu>, bug-bash@gnu.org
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400c:c05::235
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 05:20:20 -0000

Is that more advantageous?

On Sun, Jun 4, 2017 at 10:46 AM, dualbus <dualbus@gmail.com> wrote:

> On Sun, Jun 04, 2017 at 01:45:42AM +0530, Pranav Deshpande wrote:
> [...]
> > My solution is to change *line 294* of builtins/read.def.
> >
> > Change
> > if (code == 0 || *intval < 0* || intval != (int)intval)
> >
> > to
> >
> > if (code == 0 || i*ntval <= 0* || intval != (int)intval)
> [...]
>
> > Is this solution ok?
>
> Yes. That works.
>
>
> Chet went with the other option though:
>
>   dualbus@debian:~/src/gnu/bash-build$ ./bash -c 'read -n0; echo $?;
> declare -p REPLY'
>   0
>   declare -- REPLY=""
>
> You can see the change by navigating the `devel' branch of the git
> repository
> in Savannah (commit 1110e30870a8782425067a060d89cc411b014418):
>
>   http://git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=
> 1110e30870a8782425067a060d89cc411b014418
>
> Although there's a problem with the solution:
>
>   dualbus@debian:~$ for sh in bash ~/src/gnu/bash-build/bash ksh93 mksh;
> do $sh -c ': | read -n 0; echo $?'; done
>   1
>   0
>   1
>   1
>
> Since the read(2) system call doesn't take place, `read -n 0' doesn't
> detect
> the broken pipe. IMO, it should.
>
> --
> Eduardo Bustamante
> https://dualbus.me/
>

From MAILER-DAEMON Sun Jun 04 02:33:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHP6r-0005NJ-Dc
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 02:33:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37148)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHP6p-0005ND-9q
	for bug-bash@gnu.org; Sun, 04 Jun 2017 02:33:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHP6o-0002fa-GA
	for bug-bash@gnu.org; Sun, 04 Jun 2017 02:33:55 -0400
Received: from mail-qt0-x243.google.com ([2607:f8b0:400d:c0d::243]:35860)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dHP6o-0002eS-A5
	for bug-bash@gnu.org; Sun, 04 Jun 2017 02:33:54 -0400
Received: by mail-qt0-x243.google.com with SMTP id s33so2499989qtg.3
	for <bug-bash@gnu.org>; Sat, 03 Jun 2017 23:33:54 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=+xNz/J8vew+MrlMV43PbMWTAQ3V2KN9aTGs1q83e5xE=;
	b=Hyvnf4WrR8W7Y/fe5+AcC4RKVtkF05IBchbijLfwWigej/sJVTBr+kk0BspvhQMoMY
	MkmhSaP/kYnLNMeKWV7FotlThAd4TDEFKE6hOW/juVSl5mPfFdQdkA5PnUVvKiYrGEJN
	/+h0hLmpzKEHf40gmWaY5xPI2T7T+C+mQzuHNWBhjwIIYkbj9OwnSWc+KSuPdeje78gO
	BedsUOm8xprW8hXgwYL3OIceygjPAnoUId7XgWtZGm6P2yxuUbMax2ChetTAkXSKuWl/
	8VxWUj2sYcurMX7DArGuvTvEBNLeKIkq0daNgbIVUqNaT5uvRO3Qa4jxza/aMnFet6Dm
	vk9Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=+xNz/J8vew+MrlMV43PbMWTAQ3V2KN9aTGs1q83e5xE=;
	b=lMvgrQjyPZOoH82GryBUX/Q9yHyR7eAr7Rnxmi0y6qzvKJcxD2UedcpBBOMXnopXnF
	kxE7l6aPJ3Qb8mboMdAethJ21NeDSV1fhNUyDU9xwtr470ifx6uqyHGEybY8hKdxfLk+
	2UawWqRgLKU4ALexSchTGB1bRvJjrpnyZJDTc+4RUJJ1ydQTdiLZdMVimZn442/KXdTL
	TdY6mbSoclkvuqHMg0vs007vBgHkRpRyKxSMZrS/yu0qMYe6RcyhQHL2RibpRHwO8aUG
	r/NO1H2IjDRuDWLUXFEdwkjjaPLKY3CCW0zTIlMadk9o+nDrHhXZxEeHzykceTM6dCP1
	xFJg==
X-Gm-Message-State: AODbwcDO04GcNUq99eQ3/jEi5oqsr84SOFVDjP5ECKyaSm80NOleWAt3
	fC7nED9/dM7qOiP0h/rB7wGj8b70Xg==
X-Received: by 10.200.39.51 with SMTP id g48mr16619794qtg.163.1496558033507;
	Sat, 03 Jun 2017 23:33:53 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.178.25 with HTTP; Sat, 3 Jun 2017 23:33:33 -0700 (PDT)
In-Reply-To: <20170604051609.sd7h5z4wqkyk73r2@debian>
References: <CAOSMAut1aPYc6XzMBBUjmvUVj8MNcuVCcVZBV=2zay6q-V0Z6Q@mail.gmail.com>
	<2d102524-0a27-ef61-1cb0-48a538e5db6c@case.edu>
	<CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
	<CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
	<20170604051609.sd7h5z4wqkyk73r2@debian>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Sun, 4 Jun 2017 01:33:33 -0500
Message-ID: <CAOSMAuvUUd-8LfTbR5oKtO9g0YJ0tinA4vHtQVSb=tCGv8j3Lw@mail.gmail.com>
Subject: Re: Builtin read with -n0 or -N0 (nchars == 0) behaves as a read with
	no -n/-N argument
To: Pranav Deshpande <deshpande.v.pranav@gmail.com>
Cc: Chester Ramey <chet.ramey@case.edu>, "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::243
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 06:33:56 -0000

On Sun, Jun 4, 2017 at 12:16 AM, dualbus <dualbus@gmail.com> wrote:
[...]
> Although there's a problem with the solution:
>
>   dualbus@debian:~$ for sh in bash ~/src/gnu/bash-build/bash ksh93 mksh; do $sh -c ': | read -n 0; echo $?'; done
>   1
>   0
>   1
>   1
>
> Since the read(2) system call doesn't take place, `read -n 0' doesn't detect
> the broken pipe. IMO, it should.

Err, I'm clearly wrong. SIGPIPE is sent to the writer, not to the
reader. My bad.

That doesn't mean the problem is not there though. I think this is a
better test:

  dualbus@debian:~$ for sh in bash ksh93 mksh
~/src/gnu/bash-build/bash; do echo $sh $($sh -c 'exec < /; read -n 0;
echo $?' 2>&1); done
  bash bash: line 0: read: read error: 0: Is a directory 1
  ksh93 1
  mksh mksh: read: Is a directory 2
  /home/dualbus/src/gnu/bash-build/bash 0

Since bash "fakes" the read, it's not able to detect errors.

I currently have this:

dualbus@debian:~/src/gnu/bash$ git diff
diff --git a/builtins/read.def b/builtins/read.def
index 520a2b34..4e4c1b8a 100644
--- a/builtins/read.def
+++ b/builtins/read.def
@@ -362,10 +362,6 @@ read_builtin (list)
   input_string = (char *)xmalloc (size = 112); /* XXX was 128 */
   input_string[0] = '\0';

-  /* More input and options validation */
-  if (nflag == 1 && nchars == 0)
-    goto assign_vars;          /* bail early if asked to read 0 chars */
-
   /* $TMOUT, if set, is the default timeout for read. */
   if (have_timeout == 0 && (e = get_string_value ("TMOUT")))
     {
@@ -381,6 +377,10 @@ read_builtin (list)

   begin_unwind_frame ("read_builtin");

+  /* We were asked to read 0 chars. Do error detection and bail out */
+  if (nflag == 1 && nchars == 0 && (retval=read(fd, NULL, 0)) < 0)
+    goto handle_error;
+
 #if defined (BUFFERED_INPUT)
   if (interactive == 0 && default_buffered_input >= 0 && fd_is_bash_input (fd))
     sync_buffered_stream (default_buffered_input);
@@ -714,6 +714,7 @@ add_char:
     free (rlbuf);
 #endif

+handle_error:
   if (retval < 0)
     {
       t_errno = errno;


But it completely ignores the signal handling code down below.


From MAILER-DAEMON Sun Jun 04 03:45:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHQEO-0002jW-Fa
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 03:45:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41817)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHQEL-0002jO-GE
	for bug-bash@gnu.org; Sun, 04 Jun 2017 03:45:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHQEI-0001u6-Dg
	for bug-bash@gnu.org; Sun, 04 Jun 2017 03:45:45 -0400
Received: from mail-oi0-x22a.google.com ([2607:f8b0:4003:c06::22a]:34752)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dHQEI-0001tb-6j
	for bug-bash@gnu.org; Sun, 04 Jun 2017 03:45:42 -0400
Received: by mail-oi0-x22a.google.com with SMTP id o65so106222946oif.1
	for <bug-bash@gnu.org>; Sun, 04 Jun 2017 00:45:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:content-transfer-encoding:in-reply-to
	:user-agent; bh=RZq3oVR3LnVs0uE+I4KRcNxdKSUBWqJuUFvNzEWL1W4=;
	b=K8phI1SN5SbXZIk+b+hhtVYsqkmWLH8ZKUZUBaAZuCnIOpz6e3vIGqxRkOyOc2WtAS
	SufEXRw18hfFsk/q1nxOsUFWMreVOyF/Nc8UakamVFvjy8AvtQOKEER+FixSZo3yDhfl
	fBzAzAsZ3B6sIbOzSNhHhV2G50TKfEoq14D3uRSCgSqW0eWVf1wNKDTxis8d4jiWyMjT
	jW78YHfa95voaIdDTmhMmOz8Kns2+5/l2S6/PnAH2go7pk29F+w3H8VHZlCxSAihnYQH
	Q4QGP8UI4FKzuFmRXDjirI14TtHP6rtAqlEtNeNxYR5frCVnRgvWLyvH3QnehBlb1n8P
	//Sg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:content-transfer-encoding
	:in-reply-to:user-agent;
	bh=RZq3oVR3LnVs0uE+I4KRcNxdKSUBWqJuUFvNzEWL1W4=;
	b=bdAdot6Mss8caNA45FAGl28yfMfKaC/gtait8wes8a9a6Ix8w+rhWDR+JiH212rF37
	SvlsKIPkk7UCc6GmZ+sZoykaLe8skK+qKUzqqj1LB4y3U7AiPQDi20HlWTN0NggH5YVv
	qgwXK1h6Hr4yE8c7hBR5mKf1aBH4jsQH6InpTSxUNpMG6evgB8xruzLfv6LTh5JdXTob
	u2GKWfn21RfkCjqiuH94FE9Z53+M2+WjoxOxedWu3h4WLt+s/qAgNemw2H++vOGImAgl
	1PJ6B2yhYFFx6RqvEfcJhzJ4QYVPaWVUpWuZXJpGP+VU8YLCJgijhyk4GKzCYT4kvAID
	eRkg==
X-Gm-Message-State: AODbwcDbl3dY3fs8dRNmpkUTeh7INU+YUpvZpuDLJ0RzONbmNXd/gSTm
	Kq0WvrIgm6FjAULR
X-Received: by 10.202.94.138 with SMTP id s132mr9060804oib.5.1496562341257;
	Sun, 04 Jun 2017 00:45:41 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	q35sm3698477ota.20.2017.06.04.00.45.39
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 04 Jun 2017 00:45:40 -0700 (PDT)
Date: Sun, 4 Jun 2017 02:45:38 -0500
From: dualbus <dualbus@gmail.com>
To: PePa <peterkelly@passchier.net>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170604074538.36cmislgervrqiqw@debian>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org>
	<1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22a
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 07:45:46 -0000

On Sun, Jun 04, 2017 at 01:46:23AM +0700, PePa wrote:
[...]
> But the fact that unicode functions are already supported does seem to
> pave the way for allowing variable names in unicode. For consistency, it
[...]

I know I said I wasn't going to reply, but this changed my mind :-)

I hadn't realized that bash already supports Unicode in function names!

FWIW:

  bash-4.4$ 
  Lēv=?
  Φ=0.618033988749894848
  ɸ=1.61803398874989485
  π=3.14159265358979324
  declare -p Lēv Φ ɸ π
  declare -- Lēv="?"
  declare -- Φ="0.618033988749894848"
  declare -- ɸ="1.61803398874989485"
  declare -- π="3.14159265358979324"

With this terrible patch:

dualbus@debian:~/src/gnu/bash$ PAGER= git diff
diff --git a/general.c b/general.c
index 584e7859..40db7b1d 100644
--- a/general.c
+++ b/general.c
@@ -61,6 +61,9 @@ extern int errno;
 #  include <sys/cygwin.h>
 #endif
 
+#define wlegal_variable_starter(c) (iswalpha(c) || (L'_' == c))
+#define wlegal_variable_char(c) (iswalnum(c) || (L'_' == c))
+
 static char *bash_special_tilde_expansions __P((char *));
 static int unquoted_tilde_word __P((const char *));
 static void initialize_group_array __P((void));
@@ -214,15 +217,25 @@ int
 legal_identifier (name)
      const char *name;
 {
-  register const char *s;
-  unsigned char c;
+  wchar_t *s, *wstring;
+  wchar_t c;
+  size_t n;
+
+  if (!name || *name == '\0')
+    return (0);
+
+  n = mbstowcs(NULL, name, 0);
+  if((size_t) -1 == n) return 0;
+  wstring = xmalloc(sizeof(wchar_t) * (n+1));
+  n = mbstowcs(wstring, name, n);
+  if((size_t) -1 == n) return 0;
 
-  if (!name || !(c = *name) || (legal_variable_starter (c) == 0))
+  if (wlegal_variable_starter (*wstring) == 0)
     return (0);
 
-  for (s = name + 1; (c = *s) != 0; s++)
+  for (s = wstring + 1; (c = *s) != 0; s++)
     {
-      if (legal_variable_char (c) == 0)
+      if (wlegal_variable_char (c) == 0)
        return (0);
     }
   return (1);
@@ -357,27 +370,31 @@ assignment (string, flags)
      const char *string;
      int flags;
 {
-  register unsigned char c;
+  wchar_t c;
   register int newi, indx;
+  wchar_t *wstring;
+  int n;
+  size_t len;
 
-  c = string[indx = 0];
-
+  len = strlen(string);
+  if ((n=mbtowc(&c, &string[indx = 0], len)) < 1) return (0);
+  indx += n; len -= n;
 #if defined (ARRAY_VARS)
-  if ((legal_variable_starter (c) == 0) && ((flags&1) == 0 || c != '[')) /* ] */
+  if ((wlegal_variable_starter (c) == 0) && ((flags&1) == 0 || c != L'[')) /* ] */
 #else
-  if (legal_variable_starter (c) == 0)
+  if (wlegal_variable_starter (c) == 0)
 #endif
     return (0);
 
-  while (c = string[indx])
+  while ((n=mbtowc(&c, &string[indx], len)) > 0)
     {
       /* The following is safe.  Note that '=' at the start of a word
         is not an assignment statement. */
-      if (c == '=')
+      if (c == L'=')
        return (indx);
 
 #if defined (ARRAY_VARS)
-      if (c == '[')
+      if (c == L'[')
        {
          newi = skipsubscript (string, indx, (flags & 2) ? 1 : 0);
          if (string[newi++] != ']')
@@ -389,15 +406,15 @@ assignment (string, flags)
 #endif /* ARRAY_VARS */
 
       /* Check for `+=' */
-      if (c == '+' && string[indx+1] == '=')
+      if (c == L'+' && string[indx+1] == '=')
        return (indx + 1);
 
       /* Variable names in assignment statements may contain only letters,
         digits, and `_'. */
-      if (legal_variable_char (c) == 0)
+      if (wlegal_variable_char (c) == 0)
        return (0);
 
-      indx++;
+      indx += n; len -= n;
     }
   return (0);
 }


It seems to have issues with compound assignments though. 

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sun Jun 04 10:05:55 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHWAE-000833-Vk
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 10:05:54 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45624)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dev@joernhees.de>) id 1dHVhX-000256-Un
	for bug-bash@gnu.org; Sun, 04 Jun 2017 09:36:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dev@joernhees.de>) id 1dHVhU-0006Z0-Sc
	for bug-bash@gnu.org; Sun, 04 Jun 2017 09:36:15 -0400
Received: from smtprelay04.ispgateway.de ([80.67.31.32]:33707)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <dev@joernhees.de>) id 1dHVhU-0006Wo-Lw
	for bug-bash@gnu.org; Sun, 04 Jun 2017 09:36:12 -0400
Received: from [91.67.31.207] (helo=[192.168.1.2])
	by smtprelay04.ispgateway.de with esmtpsa
	(TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.84)
	(envelope-from <dev@joernhees.de>) id 1dHVhP-0002Vq-3Q
	for bug-bash@gnu.org; Sun, 04 Jun 2017 15:36:07 +0200
From: =?utf-8?Q?J=C3=B6rn_Hees?= <dev@joernhees.de>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Subject: minor: man-page: history file time comments for following not
	preceding history line
Message-Id: <F4A5F9FA-2484-4AFE-8193-F16337EACB1C@joernhees.de>
Date: Sun, 4 Jun 2017 15:36:06 +0200
To: bug-bash@gnu.org
Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\))
X-Mailer: Apple Mail (2.3124)
X-Df-Sender: bWFpbEBqb2VybmhlZXMuZGU=
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy]
X-Received-From: 80.67.31.32
X-Mailman-Approved-At: Sun, 04 Jun 2017 10:05:53 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 13:36:16 -0000

Hi,

in the HISTORY section of the man-page it says:

> ... When the history  file
> is  read, lines beginning with the history comment character followed =
immediately by a digit are interpreted
> as timestamps for the preceding history line.

s/preceding/following/

Best,
J=C3=B6rn



From MAILER-DAEMON Sun Jun 04 14:08:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHZwv-0005R2-Je
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 14:08:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42976)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <nicola.spanti@ecole.ensicaen.fr>) id 1dHYZU-0002HZ-M8
	for bug-bash@gnu.org; Sun, 04 Jun 2017 12:40:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <nicola.spanti@ecole.ensicaen.fr>) id 1dHYZR-0001DA-G3
	for bug-bash@gnu.org; Sun, 04 Jun 2017 12:40:08 -0400
Received: from smtprelay1.ensicaen.fr ([192.93.212.27]:51614)
	by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <nicola.spanti@ecole.ensicaen.fr>) id 1dHYZR-0001BT-8N
	for bug-bash@gnu.org; Sun, 04 Jun 2017 12:40:05 -0400
Received: from zimbra.ensicaen.fr (zimbra.ensicaen.fr [192.93.212.26])
	by smtprelay1.ensicaen.fr (Postfix) with ESMTPS id 5C1A23D0037E
	for <bug-bash@gnu.org>; Sun,  4 Jun 2017 18:40:03 +0200 (CEST)
Received: from localhost (localhost [127.0.0.1])
	by zimbra.ensicaen.fr (Postfix) with ESMTP id E53AF1E2065
	for <bug-bash@gnu.org>; Sun,  4 Jun 2017 18:38:36 +0200 (CEST)
Received: from zimbra.ensicaen.fr ([127.0.0.1])
	by localhost (zimbra.ensicaen.fr [127.0.0.1]) (amavisd-new, port 10032)
	with ESMTP id 5H-AWlcuGf0Z for <bug-bash@gnu.org>;
	Sun,  4 Jun 2017 18:38:36 +0200 (CEST)
Received: from localhost (localhost [127.0.0.1])
	by zimbra.ensicaen.fr (Postfix) with ESMTP id 7B4081E2A98
	for <bug-bash@gnu.org>; Sun,  4 Jun 2017 18:38:36 +0200 (CEST)
X-Virus-Scanned: amavisd-new at ensicaen.fr
Received: from zimbra.ensicaen.fr ([127.0.0.1])
	by localhost (zimbra.ensicaen.fr [127.0.0.1]) (amavisd-new, port 10026)
	with ESMTP id TNXi5xr3NkAu for <bug-bash@gnu.org>;
	Sun,  4 Jun 2017 18:38:36 +0200 (CEST)
Received: from [192.168.1.174] (unknown [193.33.56.165])
	by zimbra.ensicaen.fr (Postfix) with ESMTPSA id 52A6C1E2065
	for <bug-bash@gnu.org>; Sun,  4 Jun 2017 18:38:36 +0200 (CEST)
To: bug-bash@gnu.org
From: Nicola Spanti <nicola.spanti@ecole.ensicaen.fr>
Subject: Very minor fixes thanks to cppcheck
Message-ID: <593437DA.2030304@ecole.ensicaen.fr>
Date: Sun, 4 Jun 2017 18:39:54 +0200
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101
	Icedove/38.8.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 192.93.212.27
X-Mailman-Approved-At: Sun, 04 Jun 2017 14:08:24 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 16:40:09 -0000

Hi.

I used that:
cppcheck --verbose --quiet --enable=all --force --language=c --std=c89 .

I fixed some errors that were reported by cppcheck. I published that on 
GitLab.com.
https://gitlab.com/RyDroid/bash

The git remote is: https://RyDroid@gitlab.com/RyDroid/bash.git
The branch is cppcheck-fix

Feel to merge it upstream. I don't ask credit for this tiny thing. Of 
course, I give the copyright to the FSF.

Regards.


From MAILER-DAEMON Sun Jun 04 14:29:00 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHaGq-0007iB-01
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 14:29:00 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34161)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dHaGn-0007gq-4D
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:28:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dHaGl-00023G-Np
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:28:57 -0400
Received: from mail-pf0-x231.google.com ([2607:f8b0:400e:c00::231]:33597)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <john.archie.mckown@gmail.com>)
	id 1dHaGl-00022G-FC
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:28:55 -0400
Received: by mail-pf0-x231.google.com with SMTP id 83so15272491pfr.0
	for <bug-bash@gnu.org>; Sun, 04 Jun 2017 11:28:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=JEkFJyliZ7f7zMGZA6Iu0e2xDsQRkFilvb2eyw5WVa0=;
	b=nyNXWGm8hbRsQASsK/edm8vv+7L4BPv2jAxTCjV2G0mzCGDLenpwMOZIu/BqAq+rsh
	xsE2tLlgfDMB6aDceNcCB1dN7zBgNOZ/3fZXNgsIQjQEcA0OMcC0xVilApo8M4NMr1QO
	T+yGVhTH8y0AA5NdVrqBAUP4OgM+709qvSOkn+h8a2kGmc2DHP8UQ2Y/dtmVWMobdJOj
	bbU3auq78Yic6M5alwATYXU8w5JJ+nRyb7hFsrMViaNXWa6OZn29bV2eN8DjlBZNpZ9W
	gmURVENsHIt7kmZKUVOZmTYoEzVkJqfwEI+xwOLHpKdU36h1YG/zpbPaVnXvJ/3X/c8R
	qG+Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=JEkFJyliZ7f7zMGZA6Iu0e2xDsQRkFilvb2eyw5WVa0=;
	b=g/V/R5HFvLXMrLhNGcyLPmZeQepFYsA3yFVOReq2NX4yL4nZ5h8gjgpizhGDoCHhk9
	EeoVlMIDPZGqrFV29PaVWaYn03q6NQZqk2V5azvJe3LAN44CHqQ9zOqKoQa35DdsZCS3
	ZufSRoZmtYPk9O5jZ7xGekzJCfEXDBvxWXU/4k+7erMlOR60SJmAdsORHTJ1lOaDQFAv
	nFCdr12lRsiWSakJGne7Jzjjur8KvgFBD9FiQbs6gOAvx3RqHOWNUPrrUQ4An10W7Ug4
	tPyHOcfgBF0WRREqL1sgqvVDIJFaJcPFxtl4P2fyEljf4Dr9eQEncWYyO1ah1qpGHQ7e
	gS5g==
X-Gm-Message-State: AODbwcAoFkKJkwwlHVnYEMKuBxFpUskDZX1EO6APx3uhLKdugn0n7sEI
	oo6m2p1R5I4S5oAEEwBbx7eP4klFE9pnRZA=
X-Received: by 10.84.171.193 with SMTP id l59mr11275926plb.139.1496600934167; 
	Sun, 04 Jun 2017 11:28:54 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.167.48 with HTTP; Sun, 4 Jun 2017 11:28:53 -0700 (PDT)
In-Reply-To: <593367B8.1050108@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org> <59332EA7.2060008@tlinx.org>
	<CAAJSdjiy3ith+mQy11GXGVzhdmYh8u-0Hb0KH5mbuQs+Y9Lh+Q@mail.gmail.com>
	<593367B8.1050108@tlinx.org>
From: John McKown <john.archie.mckown@gmail.com>
Date: Sun, 4 Jun 2017 13:28:53 -0500
Message-ID: <CAAJSdjiLHb4p=RvfyjJbQXyBhk=8tNTWANdOScjHvSQMj+Oqxg@mail.gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
Cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::231
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 18:28:58 -0000

On Sat, Jun 3, 2017 at 8:51 PM, L A Walsh <bash@tlinx.org> wrote:

>
>
> John McKown wrote:
>
>> On Sat, Jun 3, 2017 at 4:48 PM, L A Walsh <bash@tlinx.org <mailto:
>> bash@tlinx.org>> wrote:
>> =E2=80=8B<snip>
>>
>

> =E2=80=8BOK, I did a port of BASH to an IBM "mainframe" system (IBM z) wh=
ich uses
>> EBCDIC as it's character set, rather than ASCII or UNICODE. Granted, thi=
s
>> system is a very minor player to most people. OTOH, most "Fortune 500"
>> companies will have one or more "hidden away" doing some "legacy" work a=
nd,
>> now, perhaps even some mobile (smartphone, tablet) back end work. There =
is
>> another mid-range IBM system which also uses EBCDIC, but I don't know if=
 it
>> has a BASH port or not.=E2=80=8B
>>
> I know that perl which supports an ebcdic flavored machines, has full
> UTF-8 support now -- they were one of the first -- about 10 years ago,
> but no one uses ebcdic outside of ibm machines -- and those are not
> consumer or home level machines.
>
> I'm surprised you got bash ported to work with that charset though,
> and certainly I can't imagine you using an ebcdic machine as a home
> machine....are you?
>

=E2=80=8BNo. I did this for work. I actually use BASH at work on an IBM z/O=
S
system. Bugs my boss a little, but he allows it. I only "jumped in" when it
seemed that the OP wanted to know if _anybody at all_ could not use UTF-8.
I can use UTF-8 on the system, but it is difficult to interface between
EBCDIC (which is the majority of the data) and UTF-8 in a really easy way
and "transparent" way. It can be done, but it causes me nausea.

I know of three people who have resurrected some old IBM z hardware at
home. But they are running Linux with ASCII. The IBM z is not exactly
"married"=E2=80=8B to EBCDIC. But a few of the "zoned" decimal instructions=
 are
EBCDIC oriented.
=E2=80=8Bhttps://www.youtube.com/watch?v=3D45X4VP8CGtk=E2=80=8B

--=20
Windows. A funny name for a operating system that doesn't let you see
anything.

Maranatha! <><
John McKown

From MAILER-DAEMON Sun Jun 04 14:47:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHaZD-0005u6-9W
	for mharc-bug-bash@gnu.org; Sun, 04 Jun 2017 14:47:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37894)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHaZB-0005te-9x
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:47:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dHaZ7-0008L4-V8
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:47:57 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:45214
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dHaZ7-0008FC-J8
	for bug-bash@gnu.org; Sun, 04 Jun 2017 14:47:53 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v54IljEe025359; Sun, 4 Jun 2017 11:47:47 -0700
Message-ID: <593455D1.9050706@tlinx.org>
Date: Sun, 04 Jun 2017 11:47:45 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: dualbus <dualbus@gmail.com>
CC: PePa <peterkelly@passchier.net>, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>	<20170602045255.4uqtbnsxryrfc432@debian>	<5930F4AE.1050308@tlinx.org>	<20170602131846.rclunctr5ri2s4jr@debian>	<59327149.6000007@tlinx.org>	<1496512817.17253.69.camel@scope-eye.net>	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
In-Reply-To: <20170604074538.36cmislgervrqiqw@debian>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v54IljEe025359
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 04 Jun 2017 18:47:58 -0000

dualbus wrote:
> I hadn't realized that bash already supports Unicode in function names!
> FWIW:
>
>   bash-4.4$=20
>   L=C4=93v=3D?
>   =CE=A6=3D0.618033988749894848
>  =20
>
> With this terrible patch:
>
> dualbus@debian:~/src/gnu/bash$ PAGER=3D git diff
>  =20
----
    Clarification, please, but it looks like with your
patch below, Unicode in variable names might be fairly close
to being achieved?  Seeing how it was done for functions,
gave you insight into how variables could be done, yes?

    Why do you call it "terrible"?=20

    Does this mean it might not be unreasonable to
add unicode support in varnames (dependent on
further testing and solving of found problems, like
compound assignments)?

    Good catch on seeing and "getting" the comment
that it was supported in funcnames (and thanks to
PePa for mentioning it!).  This could be very cool! :-)

-linda


From MAILER-DAEMON Mon Jun 05 04:52:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHnkf-00080b-LI
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 04:52:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51017)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dHnkc-0007z6-SF
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:52:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dHnkX-0002am-Uc
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:52:38 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:59855
	helo=homiemail-a92.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dHnkX-0002YF-II
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:52:33 -0400
Received: from homiemail-a92.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTP id 3652D801B03A; 
	Mon,  5 Jun 2017 01:52:21 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=pCKDWU/es5YlP1yc
	NSH2VCwfsaI=; b=01uI+Dn5nbEneYZdukbF5f97VUSz6JwF79OIsQ58Tm3R5dfY
	Nh6BPW0S6zS7dl+EiVhi5Qtta0lrjFsIr5ad//1pLTNiDNvnB4O/NOuLfy30vo3n
	amXhXFULPK48UXbPHKCJ+/7q7QfrMk+efd3eVZjt1ulu/eS5nOlAJITUSZQ=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTPSA id AF301801B032;
	Mon,  5 Jun 2017 01:52:20 -0700 (PDT)
Message-ID: <1496652739.17253.82.camel@scope-eye.net>
Subject: Re: Patch for unicode in varnames...
From: George <tetsujin@scope-eye.net>
To: L A Walsh <bash@tlinx.org>, dualbus <dualbus@gmail.com>
Cc: bug-bash <bug-bash@gnu.org>, PePa <peterkelly@passchier.net>
Date: Mon, 05 Jun 2017 04:52:19 -0400
In-Reply-To: <593455D1.9050706@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>	<20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org>	<1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 08:52:40 -0000

On Sun, 2017-06-04 at 11:47 -0700, L A Walsh wrote:
> dualbus wrote:
> >=20
> > I hadn't realized that bash already supports Unicode in function name=
s!
> > FWIW:
> >=20
> > =C2=A0 bash-4.4$=C2=A0
> > =C2=A0 L=C4=93v=3D?
> > =C2=A0 =CE=A6=3D0.618033988749894848
> > =C2=A0=C2=A0
> >=20
> > With this terrible patch:
> >=20
> > dualbus@debian:~/src/gnu/bash$ PAGER=3D git diff
> > =C2=A0=C2=A0
> ----
> =C2=A0=C2=A0=C2=A0=C2=A0Clarification, please, but it looks like with y=
our
> patch below, Unicode in variable names might be fairly close
> to being achieved?=C2=A0=C2=A0Seeing how it was done for functions,
> gave you insight into how variables could be done, yes?
>=20
> =C2=A0=C2=A0=C2=A0=C2=A0Why do you call it "terrible"?=C2=A0
To hazard a guess: Each call to legal_identifier() and assignment() in th=
e patched code requires copying the parameter and translating it to a wid=
e-
character string (with no provision for skipping the added work as a buil=
d option). It appears the memory allocated for these copies leaks (I didn=
't
see any added calls to xfree() to go with those new xmallocs()), and the =
character type for the character conversion is derived from the user's lo=
cale
(which means there's not a reliable mechanism in place to run a script in=
 a locale whose character encoding doesn't match that of the script.) And=
 he
did mention "issues with compound assignments" as well. Those issues woul=
d need to be resolved.

From MAILER-DAEMON Mon Jun 05 04:59:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHnr4-0001Qd-GS
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 04:59:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52290)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHnr3-0001QX-0i
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:59:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dHnqz-0007tW-5v
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:59:17 -0400
Received: from mail-pf0-x22f.google.com ([2607:f8b0:400e:c00::22f]:33846)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dHnqy-0007r7-VA
	for bug-bash@gnu.org; Mon, 05 Jun 2017 04:59:13 -0400
Received: by mail-pf0-x22f.google.com with SMTP id 9so80033309pfj.1
	for <bug-bash@gnu.org>; Mon, 05 Jun 2017 01:59:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=n+tZqPN/IuptkkARa7g8YSGbLuEXmDzB69Uz++jH8lU=;
	b=o5n4TZxkZ2IL9MBOs94RlGa0KtaBtGgMdY6gM8IAVHykpBK6jsXtlZiH3zZZJ2VkCi
	K1RX2YiVQoytI0AqYCXnwGld47H4pyLVIEXZH4kpZHyMSwR27V43qRd1cezGvFA/Nb2o
	h7z3y9VgUjLWh4MfFcofAx1JdiefN/JAxQEQogU/dx+DLd/sR0s29figMgMGFiZZFVU5
	PKCuqN16Bd5mk0EjjYYve4uOjb3vqeNGcg6qIoYYbZughZj2JzWgwcxcwY6L4PNda/l0
	zNjJkU+HhXOn6JeaZe8Plb71uNvMX3CKcXBK3AQlVZPPQqDIxMe4gDWMdoZoVau8Gqgz
	lIiw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=n+tZqPN/IuptkkARa7g8YSGbLuEXmDzB69Uz++jH8lU=;
	b=k9u6w21BoHiuOyomQR1GVYOc7bf0ISk1fD1bzZufVis/MqRIqQ6OjZeyAtgBZemK1G
	DcI/SGSp994cNZzEsu2WS+MeC4qzAw7VKVJYhrApO3yYKEtgrQjwvFfgd91DW3WGLNBx
	Zhh4bNYBNBdSUvjUr3p/QzUkoEnIo+Uimw87an1IHDYps/XDqwDf9y3wj8eNyiZ6vmLx
	K0KreB/pbm6xgglKNj56xZ9LY4Kck9Z0kphMyxsi4Q1MMGgmp82iD+062scgHVk0xbti
	VKSnQH2SeR0jkGFp1kAITB5BauIA1O4xFp3fL4rkPu7lzCxKibcB8e/nFew+ibMPDqpv
	DBLA==
X-Gm-Message-State: AODbwcD0Vs+Fn+9xuZ+q2UaRJg0VZbWu/Vn0YeXJ9oc6MCbRWsezLjvs
	dbDqNQ6zgcFFccOR
X-Received: by 10.99.102.7 with SMTP id a7mr19565404pgc.216.1496653150371;
	Mon, 05 Jun 2017 01:59:10 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.59.122])
	by smtp.gmail.com with ESMTPSA id
	a72sm56461033pfe.133.2017.06.05.01.59.07 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Mon, 05 Jun 2017 01:59:08 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Patch for unicode in varnames...
Cc: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
Date: Mon, 5 Jun 2017 15:59:05 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496652739.17253.82.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 08:59:17 -0000

On 05/06/2560 15:52, George wrote:
> there's not a reliable mechanism in place to run a script in a locale
> whose character encoding doesn't match that of the script

>From my experience running such scripts is no problem, but correct
rendering it might depend on the client/editor.


From MAILER-DAEMON Mon Jun 05 08:06:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHqmG-0007LU-Bj
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 08:06:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34960)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <eblake@redhat.com>) id 1dHqmD-0007KU-Mq
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:06:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <eblake@redhat.com>) id 1dHqmA-0007dM-Hm
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:06:29 -0400
Received: from mx1.redhat.com ([209.132.183.28]:54910)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <eblake@redhat.com>) id 1dHqmA-0007bh-8Q
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:06:26 -0400
Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com
	[10.5.11.11])
	(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by mx1.redhat.com (Postfix) with ESMTPS id 5CC304E4D1;
	Mon,  5 Jun 2017 12:06:24 +0000 (UTC)
DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 5CC304E4D1
Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com;
	dmarc=none (p=none dis=none) header.from=redhat.com
Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com;
	spf=pass smtp.mailfrom=eblake@redhat.com
DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 5CC304E4D1
Received: from [10.10.120.12] (ovpn-120-12.rdu2.redhat.com [10.10.120.12])
	by smtp.corp.redhat.com (Postfix) with ESMTP id CEE6A80A27;
	Mon,  5 Jun 2017 12:06:23 +0000 (UTC)
Subject: Re: Very minor fixes thanks to cppcheck
To: Nicola Spanti <nicola.spanti@ecole.ensicaen.fr>, bug-bash@gnu.org
References: <593437DA.2030304@ecole.ensicaen.fr>
From: Eric Blake <eblake@redhat.com>
Openpgp: url=http://people.redhat.com/eblake/eblake.gpg
Organization: Red Hat, Inc.
Message-ID: <34a4b5bb-16a4-0ab2-4565-0b847a88614b@redhat.com>
Date: Mon, 5 Jun 2017 07:06:22 -0500
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.0
MIME-Version: 1.0
In-Reply-To: <593437DA.2030304@ecole.ensicaen.fr>
Content-Type: multipart/signed; micalg=pgp-sha256;
	protocol="application/pgp-signature";
	boundary="ofmSEI2M8WCIpigS1XakraiTMnduH4kBH"
X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16
	(mx1.redhat.com [10.5.110.38]);
	Mon, 05 Jun 2017 12:06:24 +0000 (UTC)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 209.132.183.28
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 12:06:31 -0000

This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--ofmSEI2M8WCIpigS1XakraiTMnduH4kBH
From: Eric Blake <eblake@redhat.com>
To: Nicola Spanti <nicola.spanti@ecole.ensicaen.fr>, bug-bash@gnu.org
Message-ID: <34a4b5bb-16a4-0ab2-4565-0b847a88614b@redhat.com>
Subject: Re: Very minor fixes thanks to cppcheck
References: <593437DA.2030304@ecole.ensicaen.fr>
In-Reply-To: <593437DA.2030304@ecole.ensicaen.fr>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

On 06/04/2017 11:39 AM, Nicola Spanti wrote:
> Hi.
>=20
> I used that:
> cppcheck --verbose --quiet --enable=3Dall --force --language=3Dc --std=3D=
c89 .
>=20
> I fixed some errors that were reported by cppcheck. I published that on=

> GitLab.com.
> https://gitlab.com/RyDroid/bash
>=20
> The git remote is: https://RyDroid@gitlab.com/RyDroid/bash.git
> The branch is cppcheck-fix

Can you also post the patches directly to this list, rather than making
us chase a URL to see what the patch includes?

>=20
> Feel to merge it upstream. I don't ask credit for this tiny thing. Of
> course, I give the copyright to the FSF.

Copyright assignment is more formal than that, if your patch is deemed
significant (small patches can be taken without assignment, but large
patches require actual paperwork and signatures, although these days
there are various countries where the paperwork is all electronic).

--=20
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org


--ofmSEI2M8WCIpigS1XakraiTMnduH4kBH
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
Comment: Public key at http://people.redhat.com/eblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBCAAGBQJZNUk+AAoJEKeha0olJ0NqCIgIAKSYE0rPpI02agEzqTRoxHFK
NM5Ee/gSsr9wzG5jxOwHwwpt2Xha9sz9brvwBImr73i2X07z/vHHZzevDGOrqtY9
z/wODJs/FIH6QpMPbvOD+FKnvfUBNkkegMVC4T2m0JYDGPzd9sKzKEeruixu/OWS
7L25zUPJdvKcUn9gChAQJsIN1rjxEl0X+KoLGUBQqGUs9P5BthByaCLUBtD/jF5/
5ewSN76KyJanOMHgOsdJ6w6VYyapD1jWaEmeM9h7ClxVtcsbYDBxD9ktQGNWYl01
FSkptQvNQuHlDix6uUMvW3EDUmYzxYu/2pEWqZZwm21JaT4jRjymBTpYo2kpvhY=
=w5c8
-----END PGP SIGNATURE-----

--ofmSEI2M8WCIpigS1XakraiTMnduH4kBH--


From MAILER-DAEMON Mon Jun 05 08:14:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHquF-00016W-A6
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 08:14:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36511)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dHquC-00016A-EV
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:14:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dHqu7-0004KZ-Gq
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:14:44 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:59199 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dHqu7-0003yS-Ah
	for bug-bash@gnu.org; Mon, 05 Jun 2017 08:14:39 -0400
Received: (qmail 41719 invoked from network); 5 Jun 2017 12:14:08 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Mon, 05 Jun 2017 08:14:08 -0400
Received: (qmail 3585 invoked by uid 563); 5 Jun 2017 12:14:08 -0000
Date: Mon, 5 Jun 2017 08:14:08 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170605121408.GT7764@eeg.ccf.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org> <59332EA7.2060008@tlinx.org>
	<12215b64-16c4-dc48-3ab1-945b80eb9b13@passchier.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <12215b64-16c4-dc48-3ab1-945b80eb9b13@passchier.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 12:14:45 -0000

On Sun, Jun 04, 2017 at 09:20:45AM +0700, Peter & Kelly Passchier wrote:
> On 04/06/2560 04:48, L A Walsh wrote:
> >> Greg Wooledge wrote:
> >>> Here is a demonstration of the cost of what you are proposing.  In my
> >>> mail user agent, your variable shows up as L??v.
> >>>
> >>> Source code with your UTF-8 identifiers would no longer even be
> >>> READABLE  
> >>
> >> What display/OS do you have that you can't run UTF-8 on?
> 
> So it's his mail client: reading unicode source in their old mail client
> is going to be problematic for some people...

imadev:~$ uname -a
HP-UX imadev B.10.20 A 9000/785 2008897791 two-user license

imadev:~$ ls -lt /usr/bin | tail -1
-r-xr-xr-x   1 bin        bin          12288 May 30  1996 from

It's the system on which I run my email MUA (mutt) and my IRC client.
It's also the NIS slave server for this floor (subnet).  It's also
where I put the squid proxy that all the Debian systems use for
apt-get.

Up until a few months ago, when our legacy Perforce server died, it
was also where I did all the development for an in-house Tcl (mostly)
application.  Having absolutely no intention of attempting to replace
Perforce with another Perforce, I simply took the existing checkout
(Perforce calls it a "client") that I already had, copied it over to
the Debian half of my dual-boot Debian/Windows system, and made a git
repository out of it.  (Compiling git for HP-UX 10.20 did not sound like
a fun thing to do, with all that https and stuff that it seems to want.)

This is the pace at which changes happen out here in the real world.


From MAILER-DAEMON Mon Jun 05 10:04:30 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dHscQ-00012c-2J
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 10:04:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37031)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHscN-0000va-M3
	for bug-bash@gnu.org; Mon, 05 Jun 2017 10:04:28 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dHscK-0004cb-IF
	for bug-bash@gnu.org; Mon, 05 Jun 2017 10:04:27 -0400
Received: from mail-oi0-x230.google.com ([2607:f8b0:4003:c06::230]:36694)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dHscK-0004aI-DI
	for bug-bash@gnu.org; Mon, 05 Jun 2017 10:04:24 -0400
Received: by mail-oi0-x230.google.com with SMTP id h4so158589518oib.3
	for <bug-bash@gnu.org>; Mon, 05 Jun 2017 07:04:22 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:content-transfer-encoding:in-reply-to
	:user-agent; bh=kk80DxnvMPt0cLYLjTXaCNyDtqlfhxJvhhWr8kbNeUs=;
	b=Tnff7iRemI3LQaskz7kBgCcxcQ1SDinCNLgbShaxNz0BOuAFJ9wa2RfSz9PVvCQcnm
	9BWVMhbZYbH367f4rRxonKgrKg2bJC7MND4AmuE0A70QGYTZ+rxW65LI071eZnA+9Pmd
	5iolZxvMWCpdQrvQioZ2+rYn/ImRcqxS9eCTIMLs/lJNJ/AL8Hn27fdGgsRPviHwdVb9
	vdH05/d/bZJAgpxImUPnFsuZ+mvs8w26Zd1mUteTjB6E+OYhJGCyy0Y6V0ltLCNOaWSK
	dLk2gFErjAj1ksJ/Qe8rO2Wy+Dtfz0ZDJfOUGGPTy29Iw30Q28p2R5ZaH//sYffz713w
	GRAQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:content-transfer-encoding
	:in-reply-to:user-agent;
	bh=kk80DxnvMPt0cLYLjTXaCNyDtqlfhxJvhhWr8kbNeUs=;
	b=b3cBzFD2DQi8bi06/J+1Y07QaF5Hx0QMF2J4FCY5lWTLKEvK25bV+0HPrPzZR6RDDz
	OKLbGH3+RcCmn73/XleWLP+wJlBXEUnhgUPng+HKRXRWRuHhzsVmklKYNsco35IdpkTP
	awF5bK0sG4T9kPysgP5i2bwmyzWQ1st4lgeX1qW7z1/RRlGWnGloqZ8oaBga/ES/3WEt
	Kmw+KGU6dPIoWFL8/3iGnWxcnYVqMZPMV1Mld1iDSEkWvQAcabmcGzQ8m0iYDtA5d2fu
	p9Bl3iQJ2/g0IP/bcSUgv2HlnsKiNq1kJb47QuVY/R6JYuFW3jJWcdBAKuyVwED93OGN
	/bdA==
X-Gm-Message-State: AODbwcCyHuQtAeod1Lj7vfU3Pzup1d19TnLrGvObcpn65kxu2u9ZJbOn
	j67MyBgUsUjsXw==
X-Received: by 10.202.193.6 with SMTP id r6mr11886589oif.129.1496671461845;
	Mon, 05 Jun 2017 07:04:21 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id h53sm266025otc.48.2017.06.05.07.04.20
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 05 Jun 2017 07:04:20 -0700 (PDT)
Date: Mon, 5 Jun 2017 09:04:13 -0500
From: dualbus <dualbus@gmail.com>
To: George <tetsujin@scope-eye.net>
Cc: L A Walsh <bash@tlinx.org>, bug-bash <bug-bash@gnu.org>,
	PePa <peterkelly@passchier.net>
Subject: Re: Patch for unicode in varnames...
Message-ID: <20170605140413.dahctuno6beg23ms@debian>
References: <5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org>
	<1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <1496652739.17253.82.camel@scope-eye.net>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 14:04:28 -0000

On Mon, Jun 05, 2017 at 04:52:19AM -0400, George wrote:
[...]
> To hazard a guess: Each call to legal_identifier() and assignment() in
> the patched code requires copying the parameter and translating it to
> a wide-character string (with no provision for skipping the added work
> as a build option). It appears the memory allocated for these copies
> leaks (I didn't see any added calls to xfree() to go with those new
> xmallocs()), and the character type for the character conversion is
> derived from the user's locale (which means there's not a reliable
> mechanism in place to run a script in a locale whose character
> encoding doesn't match that of the script.) And he did mention "issues
> with compound assignments" as well. Those issues would need to be
> resolved.

Correct. There's also mixed use of wide-character strings and normal
strings, because that was easier to hack quickly.

By the way, ksh93 and zsh already support Unicode identifiers:

  dualbus@debian:~$ for sh in bash mksh ksh93 zsh; do LC_CTYPE=en_US.utf8 $sh -c 'φ=phi; echo $φ'; done
  bash: φ=phi: command not found
  $φ
  mksh: φ=phi: not found
  $φ
  phi
  phi

And all of these four support Unicode function names:

  dualbus@debian:~$ for sh in bash mksh ksh93 zsh; do LC_CTYPE=en_US.utf8
  $sh -c 'φ() { echo hi; }; φ'; done
  hi
  hi
  hi
  hi

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 05 18:39:46 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI0f4-0005AY-Rt
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 18:39:46 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36394)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dI0f1-0005A5-KU
	for bug-bash@gnu.org; Mon, 05 Jun 2017 18:39:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dI0ey-0005vS-GE
	for bug-bash@gnu.org; Mon, 05 Jun 2017 18:39:43 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:48824
	helo=homiemail-a92.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dI0ey-0005vK-39
	for bug-bash@gnu.org; Mon, 05 Jun 2017 18:39:40 -0400
Received: from homiemail-a92.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTP id 63421801D608; 
	Mon,  5 Jun 2017 15:39:35 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=/H9dQvH64r9cAnKB
	W7gO/VItbV4=; b=JX1But5kDRCRXxa6evub2r08Q2uaGOivvNiEOrMOHaiOIqaI
	ju8LymPOllgwF3pfLPNyBULsGSraUZ8r76Rj9p6CZB0ZEVJbA0aNhCw3FRwIrkby
	q0kJ9Dfort2iXW6NHIiIevFhwAAAX0EwegmfmLU7OlREq+NpdzpmLSOpHY8=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTPSA id 02AB2801D606;
	Mon,  5 Jun 2017 15:39:34 -0700 (PDT)
Message-ID: <1496702373.17253.179.camel@scope-eye.net>
Subject: Re: Patch for unicode in varnames...
From: George <tetsujin@scope-eye.net>
To: Peter & Kelly Passchier <peterkelly@passchier.net>
Cc: bug-bash <bug-bash@gnu.org>
Date: Mon, 05 Jun 2017 18:39:33 -0400
In-Reply-To: <5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 22:39:45 -0000

On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
> On 05/06/2560 15:52, George wrote:
> >=20
> > there's not a reliable mechanism in place to run a script in a locale
> > whose character encoding doesn't match that of the script
> From my experience running such scripts is no problem, but correct
> rendering it might depend on the client/editor.
>=20
It depends on the source and target encodings. For most pairs of source a=
nd target encoding there is some case where reinterpreting a string from =
the
source encoding as a string in the target encoding (without proper conver=
sion) will result in an invalid string in the target encoding.
For instance, if a script were written in ISO-8859-1, many possible seque=
nces involving accented characters would actually be invalid in UTF-8. (F=
or
UTF-8, a multi-byte character must start with a byte from the 0xC0-0xFF r=
ange, and be followed by the expected number of bytes in the 0x80-0xBF ra=
nge.
So if you had "Pok=C3=A9mon" as an identifier in a Latin-1-encoded script=
 (byte value 0xE9 between the "k" and "m") and then tried running that sc=
ript in a
UTF-8 locale, that byte sequence (0xE9 0x6D) would actually be invalid in=
 UTF-8, so Eduardo's patch would indicate that the identifier is invalid =
and
fail to run the script.
UTF-8 is a bit exceptional as variable-width encodings go, in that it is =
self-synchronizing, and there are many possible byte sequences that are n=
ot
valid UTF-8 byte sequences. So converting _from_ UTF-8 tends to be less p=
roblematic than converting _to_ UTF-8. But there are still corner cases w=
here
reinterpreting a UTF-8 byte sequence as another variable-width encoding c=
ould result in failure (rather than just a strange character sequence). F=
or
instance:
- If reinterpreting UTF-8 as GB-18030 (the current Chinese national stand=
ard) or EUC-JP (a Japanese encoding common on Unix systems), the end-byte=
 of
a UTF-8 multi-byte character could be misinterpreted as the first byte of=
 a GB-18030 or EUC multi-byte character. If that UTF-8 character is follo=
wed
by a byte that's not a valid continuation byte (for instance, any of the =
single-byte punctuation or numeral characters in 0x20-0x30), the string w=
ould
be invalid in the target encoding, and converting to a wide-character str=
ing would fail.
...So basically while there are many cases where a valid UTF-8 string cou=
ld be reinterpreted without conversion to produce a valid string in anoth=
er
encoding, there are cases where the conversion would fail as well.
It seems like Korn Shell's behavior is similar to Eduardo's patch: the se=
ssion's locale settings determine the behavior of functions like isalpha(=
)
and mbstowcs, and thus what is considered a "valid" identifier in various=
 contexts. (Interestingly enough, "=E3=83=95=E3=83=95" is a valid paramet=
er name in a UTF8
script, but in an EUC-JP script it needs a leading underscore to work.)
Bash's present behavior seems a bit more cavalier: For instance, if a fun=
ction name contains a byte outside the ASCII range, it's apparently accep=
ted
regardless of the locale settings. (This works out for encodings like ISO=
-8859-15, UTF-8, and EUC-JP, where bytes in the ASCII range always repres=
ent
the corresponding ASCII character, but it's problematic for encodings lik=
e GB18030 where bytes in the ASCII range are sometimes part of multibyte
characters) - and while it works, it's not a great rule for how these cha=
racters (esp. whitespace) are treated in the syntax.
If Bash did go the route of using the locale to set the character encodin=
g of a script, I think it would be best to have a mechanism a script can =
use
to define the character encoding for the whole script file up front, rath=
er than setting LC_CTYPE to procedurally change the behavior of the shell=
.
This is because, in principle at least, the meaning of shell code shouldn=
't change based on the state of the shell. (That's not always the case, t=
here
are compatibility options that enable or disable certain keywords, and so=
me of those keywords have specific syntax associated with them...) =C2=A0=
The
character encoding used to interpret a script can fundamentally change ho=
w a script is parsed (especially for encodings like GB18030 where bytes t=
hat
look like ASCII characters may actually be part of multi-byte characters)=
 - so it should be allowed just once, at the start of parsing a file, rat=
her
than at any point in the script's execution. And for scripts loaded with =
"source", such a script should be able to communicate its own character
encoding without impacting the locale settings of the shell loading the s=
cript.

From MAILER-DAEMON Mon Jun 05 19:16:54 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI1F0-0007P5-Jt
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 19:16:54 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43771)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dI1Ex-0007Ob-NO
	for bug-bash@gnu.org; Mon, 05 Jun 2017 19:16:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dI1Et-0002qI-PH
	for bug-bash@gnu.org; Mon, 05 Jun 2017 19:16:51 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:52788
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dI1Et-0002ps-Dm
	for bug-bash@gnu.org; Mon, 05 Jun 2017 19:16:47 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v55NGftA071618; Mon, 5 Jun 2017 16:16:43 -0700
Message-ID: <5935E659.9040308@tlinx.org>
Date: Mon, 05 Jun 2017 16:16:41 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: George <tetsujin@scope-eye.net>
CC: Peter & Kelly Passchier <peterkelly@passchier.net>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>	<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>	<59327149.6000007@tlinx.org>
	<1496512817.17253.69.camel@scope-eye.net>	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>	<1496652739.17253.82.camel@scope-eye.net>	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
In-Reply-To: <1496702373.17253.179.camel@scope-eye.net>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 05 Jun 2017 23:16:52 -0000

George wrote:
> On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
>   
>> On 05/06/2560 15:52, George wrote:
>>     
>>> there's not a reliable mechanism in place to run a script in a locale
>>> whose character encoding doesn't match that of the script
>>>       
>> From my experience running such scripts is no problem, but correct
>> rendering it might depend on the client/editor.
>>
>>     
> It depends on the source and target encodings. For most pairs of source and target encoding there is some case where reinterpreting a string from the
> source encoding as a string in the target encoding (without proper conversion) will result in an invalid string in the target encoding.
> For instance, if a script were written in ISO-8859-1, many possible sequences involving accented characters would actually be invalid in UTF-8.
---
    Um... I think you are answering a case that is different than
what is stated (i.e. locale being same as used in script).  So no
conversion should take place.

(if you have an issue w/that, talk to George.  :-) )

-linda




From MAILER-DAEMON Mon Jun 05 20:41:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI2YV-0006k8-Ko
	for mharc-bug-bash@gnu.org; Mon, 05 Jun 2017 20:41:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34142)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI2YT-0006jx-Fc
	for bug-bash@gnu.org; Mon, 05 Jun 2017 20:41:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI2YQ-000628-7d
	for bug-bash@gnu.org; Mon, 05 Jun 2017 20:41:05 -0400
Received: from mail-pf0-x230.google.com ([2607:f8b0:400e:c00::230]:34312)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dI2YP-0005yu-Ru
	for bug-bash@gnu.org; Mon, 05 Jun 2017 20:41:02 -0400
Received: by mail-pf0-x230.google.com with SMTP id 9so90247584pfj.1
	for <bug-bash@gnu.org>; Mon, 05 Jun 2017 17:41:01 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=rsiulmmCC00w6OvGaNRbGtaaMJcD2FCbmYRePi7FE7g=;
	b=cKZr0ug+xkOJvuITPVt8sNLFqL0a8VbSywNc6m6rsrDQ11PqpKIjQfC53AOFxYT857
	HXGOWFsgiUQqWPw72M24bVd10MP8wT9y9K8wh7DW6Aau1ReDugwWKjUqlHKK6FJB2uA1
	w3kS7SQgcut+o3NGqhLGrRiK8QEIaa/1+c64xc7AEz9waUqVHf684ahrZgU/pzumvRJu
	hwps1rSF8XgmBLzf3OHqy3dgr1xYkLg9DFTp8Zk9g7o6tv0VIKm61o8AQ+Mi9mqHKkAu
	VBol6jEWI6jCt2xaMSeRhk4Fhd4ch57pTA6Ef2agh21x1WaAEbLRKXC5AHSk44wamBrL
	9U3A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=rsiulmmCC00w6OvGaNRbGtaaMJcD2FCbmYRePi7FE7g=;
	b=o8IHOzOsZL4aCZfz66t5RXMlQ6d1GnRaXHjkA9koQJ4L86w4JWXooJoNLJvYjxzUi7
	RZvNqMNntqMSbiFCTYDuKeBWjC1oLz7zJ9TkZ625zT8dzr6vk50+6UHveuVf2luVqobr
	5XZd7ljZsfADfnfQUYOSYeF59+GAHwaAOGENJDrsDEOnb5iAC6C3PQncr21JKqpgJLKn
	6o14s9NSIWyiIHHBEdfmRoW6qZz5r1QQjBvHk+x0Mi2aRWUDJjGukwbZk2OPPEMYD8+u
	HI0sS78PcC9HBDTP94mSxFZSUPq0NKpSToG8DA8EnqJouX965ajdrZZlXk90a0uXQwrY
	fQhw==
X-Gm-Message-State: AODbwcBwOqHk3hF3DqEaL9Lnr5ks5fxvW5JVckIoi4d7+o5EBxQ1GmHV
	rQ0eynkvTqV8RpgM
X-Received: by 10.98.224.194 with SMTP id d63mr17152077pfm.174.1496709660707; 
	Mon, 05 Jun 2017 17:41:00 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.59.122])
	by smtp.gmail.com with ESMTPSA id
	x6sm57429139pfk.22.2017.06.05.17.40.57 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Mon, 05 Jun 2017 17:40:58 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Patch for unicode in varnames...
Cc: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <18501171-7633-752e-1abd-d82a9f247796@passchier.net>
Date: Tue, 6 Jun 2017 07:40:55 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496702373.17253.179.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 00:41:06 -0000

On 06/06/2560 05:39, George wrote:
> So if you had "Pokémon" as an identifier in a Latin-1-encoded script (byte value 0xE9 between the "k" and "m") and then tried running that script in a
> UTF-8 locale, that byte sequence (0xE9 0x6D) would actually be invalid in UTF-8, so Eduardo's patch would indicate that the identifier is invalid and
> fail to run the script.

I often work with a locale that has a UTF-8 encoding and an
different/older encoding that are incompatible. I haven't tried the
patch, but if I use unicode characters in function names, if I write a
script in one encoding, and run it in an environment in the other
encoding, it still runs correctly, but it won't render correctly. (I
guess this depends whether the editor recognizes different encodings,
like Geany does render it correctly, but I don't know of a console
editor that does that.)

Peter


From MAILER-DAEMON Tue Jun 06 03:37:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI93L-0001u5-NW
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 03:37:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42366)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dI93I-0001ru-Rj
	for bug-bash@gnu.org; Tue, 06 Jun 2017 03:37:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dI93F-00033B-Nu
	for bug-bash@gnu.org; Tue, 06 Jun 2017 03:37:20 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:55596
	helo=homiemail-a92.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dI93F-00032X-BF
	for bug-bash@gnu.org; Tue, 06 Jun 2017 03:37:17 -0400
Received: from homiemail-a92.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTP id B2A11801B03D; 
	Tue,  6 Jun 2017 00:37:14 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=/QUwse3hiPAla57z
	3qUxKL/T7lo=; b=Ah50Qwy5VAlCGynC8YrCpx5HH/Ebp8iNfG1nIgPQk8Pk0+4w
	JjTZqkCplGnL6aY9ZrThvn2z+uSHjpiQFV4lgKWD3CzRdcnvub7nH8szm5ceMtVd
	Mo5gt5f5bN609QNnClVIZzcerEillciHMqMvIWvMmGzSvH0EcfogwcaAj5o=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a92.g.dreamhost.com (Postfix) with ESMTPSA id 44EB6801B039;
	Tue,  6 Jun 2017 00:37:14 -0700 (PDT)
Message-ID: <1496734633.17253.275.camel@scope-eye.net>
Subject: Re: Patch for unicode in varnames...
From: George <tetsujin@scope-eye.net>
To: L A Walsh <bash@tlinx.org>
Cc: Peter & Kelly Passchier <peterkelly@passchier.net>, bug-bash
	<bug-bash@gnu.org>
Date: Tue, 06 Jun 2017 03:37:13 -0400
In-Reply-To: <5935E659.9040308@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 07:37:22 -0000

On Mon, 2017-06-05 at 16:16 -0700, L A Walsh wrote:
> George wrote:
> >=20
> > On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
> > =C2=A0=C2=A0
> > >=20
> > > On 05/06/2560 15:52, George wrote:
> > > =C2=A0=C2=A0=C2=A0=C2=A0
> > > >=20
> > > > there's not a reliable mechanism in place to run a script in a lo=
cale
> > > > whose character encoding doesn't match that of the script
> > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0
> > > From my experience running such scripts is no problem, but correct
> > > rendering it might depend on the client/editor.
> > >=20
> > > =C2=A0=C2=A0=C2=A0=C2=A0
> > It depends on the source and target encodings. For most pairs of sour=
ce and target encoding there is some case where reinterpreting a string f=
rom
> > the
> > source encoding as a string in the target encoding (without proper co=
nversion) will result in an invalid string in the target encoding.
> > For instance, if a script were written in ISO-8859-1, many possible s=
equences involving accented characters would actually be invalid in UTF-8=
.
> ---
> =C2=A0=C2=A0=C2=A0=C2=A0Um... I think you are answering a case that is =
different than
> what is stated (i.e. locale being same as used in script).=C2=A0=C2=A0S=
o no
> conversion should take place.
Eduardo's patch for allowing Unicode in parameter names uses information =
from the locale setting to transform the string and test whether the
characters in it are valid characters (alphanumeric or underscore) for pa=
rameter names. But that logic can only work correctly if the character se=
t
configured in the locale is the same as the character set of the script. =
Otherwise, the byte sequence is interpreted with the wrong character
encoding, which can cause the script to fail with an "invalid parameter n=
ame" error if:
1: The byte sequence in the script is not a valid string in the new encod=
ing, or
2: The character sequence obtained by applying the new encoding results i=
n an invalid parameter name.
As it stands, it's possible in Bash to use bytes in the 0x80-0xFF range a=
s part of function names, for instance, because the Bash parser treats al=
l of
these byte values as valid "word" characters. This makes the Bash parser =
fairly "encoding neutral", which is why scripts using non-ASCII character=
s in
command names or function names work even if the script is run on a diffe=
rent locale in current versions of Bash. Bash just ignores the issue, and
that works for a fair number of encodings. (Encodings like GB-18030 or Sh=
ift-JIS are exceptions, because byte values in the 0x00-0x7F range can be
part of multi-byte character, so Bash's parser may misinterpret part of a=
 multi-byte character as something else.)
...However, I wasn't talking about currently-released versions of Bash, I=
 was talking about Eduardo's patch.
Broadly speaking I think the approach taken in Eduardo's patch (interpret=
ing the byte sequence according to the rules of its character encoding) i=
s
better than the approach taken in current versions of Bash (letting 0x80-=
0xFF slide through the parser) - but that approach only works if you know=
 the
correct character encoding to use when processing the script. The informa=
tion has to be provided in the script somehow.


From MAILER-DAEMON Tue Jun 06 04:05:55 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI9Ux-0001r6-74
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 04:05:55 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48549)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI9Uu-0001qz-N1
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:05:53 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI9Ur-0007dz-JQ
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:05:52 -0400
Received: from mail-pg0-x234.google.com ([2607:f8b0:400e:c05::234]:33153)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dI9Ur-0007dL-DJ
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:05:49 -0400
Received: by mail-pg0-x234.google.com with SMTP id f185so31876102pgc.0
	for <bug-bash@gnu.org>; Tue, 06 Jun 2017 01:05:49 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=/NUS+KCx9ffwMdUwX6cVeEx1zC75vHN+ujd5yVLbh6Y=;
	b=oce+7Yc8pOj46v0cXYypcZ0qK1lxFTch/2RMyDgYqUwMyeiAi2t25cIgNtxGdK9+kG
	ZpMsNvMQBliN2Ao/0WH8z2F97NM7okkM5xzI1wPyGl7vF7o4MtV8zZ5qmKhXVYqOKVOS
	JRf3ew1WvvEBvr9CpJzJyvUyYFP7VOWQDIbjBTUjVYxmj3GZrvlN5effk3fkpr+sGlqu
	E57iRT4gIT2apm6ia3Wm7bwuYi8os7tSzZkiP6l4OSPepRh/SeZ66O2PdcNCP8l/ciP9
	og4fyTd8MJ2TA4j3RDQ7vPG2drBK3pBBenItoZhQIcP5HlHlSwgGwptqVofhlHV3KDu7
	xCzw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=/NUS+KCx9ffwMdUwX6cVeEx1zC75vHN+ujd5yVLbh6Y=;
	b=bcrG++51wILEoTXsZuv80aIoyt1o9c2JwxJG4+7VkhpCgBNCnw6kebh+n8+pvMKAs7
	AsmZfyvYH1tBoWDEmc/uwqfLTdJZ4dEmX8NyGXtWQdpmtTIhvIw07PzoliPmblC3Yjtl
	/OKHksnrvDBsER2o4rQmHLKsAKn7SsKX4NVlJAfWmI921plVopo9YBIsCru4DbJXBHee
	/3cd95/2Ji2CGPUKSik495QLepEfgmLGqV7WpfaQLmxhS0q99QbDT/R8GAcaTk8+vT4u
	tDkL9Hl0P1tyVnG9bETHVGenrrm9cCD2mA4uhuEvYUlpeYC9z2o67Hn32fHrQjjOD1ap
	z6Tg==
X-Gm-Message-State: AODbwcD58U2a9EIRnKYF1mfCcYlcY2R3vjCFJknOUerShKIjx15XsdVc
	lPZzaa9DQp+bwFPi
X-Received: by 10.98.16.220 with SMTP id 89mr7616275pfq.210.1496736347733;
	Tue, 06 Jun 2017 01:05:47 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.56.199])
	by smtp.gmail.com with ESMTPSA id y9sm6336242pgc.27.2017.06.06.01.05.44
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 06 Jun 2017 01:05:45 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Patch for unicode in varnames...
Cc: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <e4c8c9be-2d5d-3235-d2a1-9b4428c30432@passchier.net>
Date: Tue, 6 Jun 2017 15:05:43 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496734633.17253.275.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 08:05:53 -0000

On 06/06/2560 14:37, George wrote:
> As it stands, it's possible in Bash to use bytes in the 0x80-0xFF range as part of function names, for instance, because the Bash parser treats all of
> these byte values as valid "word" characters. This makes the Bash parser fairly "encoding neutral", which is why scripts using non-ASCII characters in
> command names or function names work even if the script is run on a different locale in current versions of Bash. Bash just ignores the issue, and
> that works for a fair number of encodings.

Thanks for the elucidation. Sorry, my terminology was off. I meant to
say, same glyphs, different encodings/locale. A TIS-620 encoded script
works in UTF-8, like you said above.

Peter



From MAILER-DAEMON Tue Jun 06 04:08:14 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dI9XC-00035e-Gb
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 04:08:14 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49134)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI9XA-00035S-6A
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:08:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dI9X7-0008Jq-3D
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:08:12 -0400
Received: from mail-pg0-x22e.google.com ([2607:f8b0:400e:c05::22e]:34480)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dI9X6-0008Ji-SU
	for bug-bash@gnu.org; Tue, 06 Jun 2017 04:08:09 -0400
Received: by mail-pg0-x22e.google.com with SMTP id v18so22346468pgb.1
	for <bug-bash@gnu.org>; Tue, 06 Jun 2017 01:08:08 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=xfUNxNB9n9sJGudOXPTV09vct2jMr9TQyh8GozfKdBw=;
	b=TIF5ZicmST4a8Rhq09IHkUAjkIPguWx63xcduj6Q0YJkqI3Gniqz535FrV9tYeA2ny
	01epuvlg6E6xfAFIoyD7myB+hrrEIP3G7XkRMQe1Y1zn8KnISHyO1dassl0+P8hhjrjc
	jRxCRL2PY5N0jRLhyKmL2/cYfbkzg+4XknD7uk13Z81ocSoazVVhNuYURn2Cy62kEXfl
	fZ0NHFVggKbVuFy5bUWpqVznlMw5Jb2ryCZUldqEDJ67lPsPzEkOH5JNdbsh9/IglpZF
	rlILProa237hZJoYmeOZZzYCh7XzBfpVxxnFSiyoLVpu+kEJXHR3Mqo+zu1CpRQuZJ7n
	OfsA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=xfUNxNB9n9sJGudOXPTV09vct2jMr9TQyh8GozfKdBw=;
	b=JfOIPN07d+OQxFsW5vr3hRiwcKz1Xw5O+g2WwbIiwtsQiZWo0pjVjxRAekDn2svPer
	mnhI+EpQONWn0dWP/SabZgaVmMmn5znZ+ksBK83TpE1qwgO1b0fOQNUi9cQGkCfjtrBk
	VxEpP9j05G4Yg+ZX6Mu58S51aEwXs1g/ukGsnvbvKEc23AZmdpL6tgPLOhmy8t8BCA8j
	Ktu34EWfDwdjd279zf7mzB26iR0V/fqjf/K4ZOP4mY4i6+Qw9bSNpH1N4qe37KQSy2wU
	vkNExvZJlq0U6MdtVG6pye7xCkFqdMCd0PeC+yvqK/4av0f3dXaMgsWeTM08gpJN7dC0
	XCkw==
X-Gm-Message-State: AODbwcDaoW/ckHYKkrQP8VUpB8I9g95PvznOOQ1TRKoNmS31p37FMy2f
	mCf6V+Q2nlezzmtO
X-Received: by 10.99.94.70 with SMTP id s67mr24902909pgb.82.1496736487863;
	Tue, 06 Jun 2017 01:08:07 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.56.199])
	by smtp.gmail.com with ESMTPSA id
	p76sm61459379pfa.53.2017.06.06.01.08.06 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 06 Jun 2017 01:08:07 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Patch for unicode in varnames...
Cc: bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <2b440105-75dc-5979-8105-b480d48752fd@passchier.net>
Date: Tue, 6 Jun 2017 15:08:04 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496734633.17253.275.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::22e
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 08:08:13 -0000



On 06/06/2560 14:37, George wrote:
> Broadly speaking I think the approach taken in Eduardo's patch
> (interpreting the byte sequence according to the rules of its character
> encoding) is better than the approach taken in current versions of Bash
> (letting 0x80-0xFF slide through the parser) - but that approach only
> works if you know the correct character encoding to use when processing
> the script. The information has to be provided in the script somehow.

I think only supporting UTF-8 would be the easiest, it allows all glyphs
to be used. And no extra declaration needs to be added to bash.

Peter


From MAILER-DAEMON Tue Jun 06 10:01:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIF3F-0001NU-Ks
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 10:01:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54954)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIF38-0001Lu-Ex
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:01:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIF34-0005Hp-II
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:01:34 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:56548
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dIF34-0005Gp-7j
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:01:30 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v56E1NeJ031236; Tue, 6 Jun 2017 07:01:25 -0700
Message-ID: <5936B5B3.3000006@tlinx.org>
Date: Tue, 06 Jun 2017 07:01:23 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: George <tetsujin@scope-eye.net>
CC: Peter & Kelly Passchier <peterkelly@passchier.net>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
References: <5930B488.7020605@tlinx.org>		<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>		<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>		<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>		<59327149.6000007@tlinx.org>
	<1496512817.17253.69.camel@scope-eye.net>		<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>		<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>		<1496652739.17253.82.camel@scope-eye.net>		<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>	
	<1496702373.17253.179.camel@scope-eye.net>
	<5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
In-Reply-To: <1496734633.17253.275.camel@scope-eye.net>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 14:01:40 -0000



George wrote:
> On Mon, 2017-06-05 at 16:16 -0700, L A Walsh wrote:
>> George wrote:
>>> On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
>>>> On 05/06/2560 15:52, George wrote:
>>>>> there's not a reliable mechanism in place to run a script in a 
>>>>> locale whose character encoding doesn't match that of the script 
>>>> From my experience running such scripts is no problem, but correct 
>>>> rendering it might depend on the client/editor. 
>>> It depends on the source and target encodings. For most pairs of 
>>> source and target encoding there is some case where reinterpreting a 
>>> string from the source encoding as a string in the target encoding 
>>> (without proper conversion) will result in an invalid string in the 
>>> target encoding. For instance, if a script were written in 
>>> ISO-8859-1, many possible sequences involving accented characters 
>>> would actually be invalid in UTF-8. 
>>
>> ---
>>     Um... I think you are answering a case that is different than
>> what is stated (i.e. locale being same as used in script).  So no
>> conversion should take place.
>>     
>
> Eduardo's patch ... can only work correctly if the character set 
> configured in the locale is the same as the character set of the script.
----
    Right.  The 1st paragraph (written by you), above, mentions that. 
Given the 1st paragraph (which no one is contesting), we are only
talking about the case where the run locale and script locale are the same.

  The Passciers wrote that regardless of such agreement, you can still find
editors that may be ignoring the locale r have no locale support at all
and only display characters where the editor was written.  While that is
also true, it can't really be helped: if your local editor only writes
in Chinese and the script is written in ASCII, you may be out of luck
in having it display properly.

> Broadly speaking I think the approach taken in Eduardo's patch 
> (interpreting the byte sequence according to the rules of its 
> character encoding) is better than the approach taken in current 
> versions of Bash (letting 0x80-0xFF slide through the parser) - but 
> that approach only works if you know the correct character encoding to 
> use when processing the script. The information has to be provided in 
> the script somehow.
---
    Not exactly -- as the only variable-length-encoding scheme that 
linux systems have had to worry about is UTF-8.  So if you encounter 
UTF-8 in the
input, it is probable that you can use UTF-8 for the whole script. 
Otherwise, use a binary decoding stream (letting 0x80-0FF) be
treated as a 2nd half of a 256-byte charset, OR a 128-byte charset
without the a parity bit stripped that is left "as-is".

    The utility "file" is one example of such a utility that can usually 
tell
the encoding type of a text file -- at least telling the difference between
UTF-8, ASCII and some 8-bit local charset.

    While such methods may not be 100% accurate, they are usually good 
enough
for most usages where one isn't running (we hope) random scripts of unknown
origin off the web.

    FWIW, I think we are in agreement, though it may not be clear!  ;-)






From MAILER-DAEMON Tue Jun 06 10:20:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIFLa-0007qE-D9
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 10:20:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59394)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIFLY-0007q7-Kz
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:20:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIFLV-00052E-Ft
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:20:36 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:59906 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIFLV-0004ts-8l
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:20:33 -0400
Received: (qmail 52790 invoked from network); 6 Jun 2017 14:20:03 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Tue, 06 Jun 2017 10:20:03 -0400
Received: (qmail 6129 invoked by uid 563); 6 Jun 2017 14:20:03 -0000
Date: Tue, 6 Jun 2017 10:20:03 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
Message-ID: <20170606142003.GF3691@eeg.ccf.org>
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
	<5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
	<5936B5B3.3000006@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5936B5B3.3000006@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 14:20:37 -0000

On Tue, Jun 06, 2017 at 07:01:23AM -0700, L A Walsh wrote:
> George wrote:
> >On Mon, 2017-06-05 at 16:16 -0700, L A Walsh wrote:
> >>George wrote:
> >>>On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
> >>>>On 05/06/2560 15:52, George wrote:
> >>>>>there's not a reliable mechanism in place to run a script in a 
> >>>>>locale whose character encoding doesn't match that of the script 

>    Right.  The 1st paragraph (written by you), above, mentions that. 
> Given the 1st paragraph (which no one is contesting), we are only
> talking about the case where the run locale and script locale are the same.

You need someone to explicit say it?  OK, I'll say it.

Scripts that can only *run* in a UTF-8 encoding-locale are a bad idea.
The whole world is not UTF-8, despite what a few people seem to think.

That's in addition to all of the issues that arise when trying to *edit*
a script that was written in one or more character set encodings that
are different from yours.  One could almost make a viable case that
"only people on UTF-8 computers are allowed to be developers".  Almost.
But if you also intend to exclude such people from even being able to
*run* your script, I can't take any of this seriously.

(OK, in reality, I am not taking any of this seriously.  This entire
proposal and discussion are like some bizarre fantasy land to me.  Bash
is a SHELL, for god's sake.  Not a serious programming language.  Even
serious programming languages are not ready for this; see the Python
proposal that was mentioned up-thread.)


From MAILER-DAEMON Tue Jun 06 10:40:49 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIFf7-0007r9-P5
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 10:40:49 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36713)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dIFf5-0007r2-Gd
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:40:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dIFf0-0004ff-JC
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:40:47 -0400
Received: from mail-pg0-x22b.google.com ([2607:f8b0:400e:c05::22b]:36230)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dIFf0-0004fJ-E4
	for bug-bash@gnu.org; Tue, 06 Jun 2017 10:40:42 -0400
Received: by mail-pg0-x22b.google.com with SMTP id a70so28284154pge.3
	for <bug-bash@gnu.org>; Tue, 06 Jun 2017 07:40:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=MlsMbQIQvobi5YTz79K6EPzlUxUwYHNBNwQWAgRCDHI=;
	b=Ng+8CPu4Sy8FtikkVs78TGwxPoXIDaZ8V8n3thgs0xC4y/c87X3ImHyMJJyr1DTOup
	2Px0sPvfNJtxNTgefdAOReJuCu0tj6GKGx5N5UfvR6o3B8ZzoV8TUP3e419CmVoRE1uM
	lXds+OOxEY5S4M/GqZ5PBIBbbWIKAPZUSY94bG8Rlm3IgHSS8IeAbDbRC97jP+7TkAh5
	9InnmnjR6mSnHbZlYna2OPdF0yxIIUkbYqE0CslAiiZ/KSVDlg2eETLiDKFwr4zpjwN2
	6xH0r6EWWt+1GIUCj9/BsEsgwyc9S0oom8LX05qIkhxtz6nM42uBTXJ9r7C7Di9p17ea
	kUiQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=MlsMbQIQvobi5YTz79K6EPzlUxUwYHNBNwQWAgRCDHI=;
	b=s1RqPpnTfp264BF59QNTPBrjBhAg/XAwMG6iTeInNggyGFwgGl4fke9iGrjnBQKON/
	9MnckoSEy4YeKOUa6iqGxkJKQcoOSeZg+VJiDeLA7fjfMIEalOEhJXZAhVCtBLW2aHym
	l9+l4kfxyBakenpsbZaGRvMdkQJkE5AF+guoD1eCvhzhy/Ow+cK8qYxZMfIb5SUdarr+
	C8JTm015Mln2v7lv4XIOnLWMj08dw5NKYggnDAcsTvKM9/nyt4fzTtEuvLRdlazjzpBa
	2WT2pkUNOTsjzDiMz2hwfdL80ed/JGWCeZ1zdbHspvOzkApuDXfNaBeuBKLYwTaM1fa6
	gJyw==
X-Gm-Message-State: AODbwcDbZ7yggceCx0Eq+4/jUnO47H50euDk6jVXxNzRlDlRHL3DeEvq
	fE5OdEcsGH91hAmp
X-Received: by 10.84.131.36 with SMTP id 33mr21417315pld.234.1496760039485;
	Tue, 06 Jun 2017 07:40:39 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.56.199])
	by smtp.gmail.com with ESMTPSA id
	b72sm61387063pfd.118.2017.06.06.07.40.33 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 06 Jun 2017 07:40:35 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: Patch for unicode in varnames...
To: bug-bash <bug-bash@gnu.org>
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net> <5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>
Message-ID: <66e75c6a-4c20-d86e-5574-ebc2c8be0fa8@passchier.net>
Date: Tue, 6 Jun 2017 21:40:31 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170606142003.GF3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::22b
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 14:40:48 -0000

On 06/06/2560 21:20, Greg Wooledge wrote:
> Scripts that can only *run* in a UTF-8 encoding-locale are a bad idea.

Even currently, when functions in a bash script are beyond ASCII, they
can still be run anywhere. I would imagine it would be the same when
variable names are also allowed to be in some unicode encoding.

Editing them might be more difficult -- even when your editor renders
the script correctly, as the names might not make sense to you. It might
help people with other native languages though.

The net loss to you is less than the potential gains for people that
want it. And remember, function names could already be in a strange
script..! There is a precedent, and it would make sense to enhance the
support to those that desire it.

But I don't think you need to be too afraid, I've never encountered a
bash script with function names in non-ASCII characters. (But who knows,
in some domains that we would not very easily encounter it is already
prevalent..?)

Peter


From MAILER-DAEMON Tue Jun 06 11:23:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIGK4-0001L6-Av
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 11:23:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49963)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIGJy-0001Aw-HH
	for bug-bash@gnu.org; Tue, 06 Jun 2017 11:23:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIGJt-0006Bz-HN
	for bug-bash@gnu.org; Tue, 06 Jun 2017 11:23:02 -0400
Received: from mail-ot0-x232.google.com ([2607:f8b0:4003:c0f::232]:36791)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dIGJt-00068i-DS
	for bug-bash@gnu.org; Tue, 06 Jun 2017 11:22:57 -0400
Received: by mail-ot0-x232.google.com with SMTP id i31so17503427ota.3
	for <bug-bash@gnu.org>; Tue, 06 Jun 2017 08:22:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=ogytAe8CcxaofAU9X6bHl5mXqjt+G+izlressDVHINY=;
	b=QTzMKOYReeU5Mzlzrqi1YkMDA+tC6IKGgr7LoD/Bm8kIa3wV8tQYvrhhxqZ45lDSmS
	8IZ/Mlqzl+iwQ1Wyu18dAN20ujD3hGtWiBVbD8QM5J4FYSkSvtjXKY/xenl1vR3Dig1Z
	gX++aj7S8zuaxXwQWPbrKuq4Eu6l05qRR28WAdVwzKlaWt11vcjPDYQE0LyaKn4a+LS0
	VQthk53kuhX56YwygTrXWf6EsG5CA8Q69pqaWyYVOLnLZylG0kgxLU+XlDUVeKCiymUX
	+kc12uDxGpgUmPi6iLtdSdJJPZN9L3CqZGe/Ti0y62FGfhZIjUbu4ZPunUfCBpGwAy9i
	H/uw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=ogytAe8CcxaofAU9X6bHl5mXqjt+G+izlressDVHINY=;
	b=HOVyPhdo48+gQMIuUP7yHpDWVGGpaX/93nPbJNBLyiE0HHj0/LlSAK7txD0hQ8lY4D
	gl7kEm6RB/TAOxef0pjOYaePXzVCCpenE4uSfiN3H9Rn8SPpb0I/538jSpYcy5jUkdt3
	6XoP20MIbtX7bYlEUdvSDDhiFlhc5IiukU1HX2bQWeMTvhkarWPJDxwmPqMjNsU1dJ14
	MP/WzAhlbI8yKhSa8npP9fHiwGrq/2+xfC+aHy+hTLiHkLvt4G6xy+zxGlFLwmHD8K4K
	OUcP4OD5H2FYIqeWZf/GhF7UvTk4s0CWSFtuQcBi6LLzyU5iQz+oI5wHKOL3TQPvROw2
	u4zw==
X-Gm-Message-State: AODbwcBy4Lb8kSBMAYCvoz/CyFZulJS3aWio1dMgbxuPysPMVlUVRyah
	WPBL9P801FNmrw==
X-Received: by 10.157.4.239 with SMTP id 102mr6146305otm.65.1496762575023;
	Tue, 06 Jun 2017 08:22:55 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id b9sm7087381oth.4.2017.06.06.08.22.53
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Tue, 06 Jun 2017 08:22:54 -0700 (PDT)
Date: Tue, 6 Jun 2017 10:22:47 -0500
From: dualbus <dualbus@gmail.com>
To: Greg Wooledge <wooledg@eeg.ccf.org>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
Message-ID: <20170606152247.4em4wea7tamoybaf@debian>
References: <b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
	<5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
	<5936B5B3.3000006@tlinx.org> <20170606142003.GF3691@eeg.ccf.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170606142003.GF3691@eeg.ccf.org>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 15:23:06 -0000

On Tue, Jun 06, 2017 at 10:20:03AM -0400, Greg Wooledge wrote:
[...]
> (OK, in reality, I am not taking any of this seriously.  This entire
> proposal and discussion are like some bizarre fantasy land to me.  Bash
> is a SHELL, for god's sake.  Not a serious programming language.  Even
> serious programming languages are not ready for this; see the Python
> proposal that was mentioned up-thread.)

To be fair, that Python Enhancement Proposal (PEP 3131) was accepted
around 10 years ago. It seems to have landed in the Python 3.x series.

I brought it up for other reasons, specifically, to point out the
complications that arise from implementing non-ASCII identifiers (to
support my argument that there's a high cost in implementing this
feature).

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 06 15:02:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIJkn-0006Cj-1M
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 15:02:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59009)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIJkk-0006C6-EI
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:02:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIJkh-0001IT-Bj
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:02:54 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:39766
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dIJkg-0001Gh-V6
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:02:51 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v56J2f3a056348; Tue, 6 Jun 2017 12:02:43 -0700
Message-ID: <5936FC51.9060204@tlinx.org>
Date: Tue, 06 Jun 2017 12:02:41 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
References: <1496512817.17253.69.camel@scope-eye.net>	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>	<20170604074538.36cmislgervrqiqw@debian>	<593455D1.9050706@tlinx.org>	<1496652739.17253.82.camel@scope-eye.net>	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>	<1496702373.17253.179.camel@scope-eye.net>	<5935E659.9040308@tlinx.org>	<1496734633.17253.275.camel@scope-eye.net>	<5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>
In-Reply-To: <20170606142003.GF3691@eeg.ccf.org>
Content-Type: multipart/mixed; boundary="------------050504080507060902000704"
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 19:02:55 -0000

This is a multi-part message in MIME format.
--------------050504080507060902000704
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

Greg Wooledge wrote:
> On Tue, Jun 06, 2017 at 07:01:23AM -0700, L A Walsh wrote:
>   
>> George wrote:
>>     
>>> On Mon, 2017-06-05 at 16:16 -0700, L A Walsh wrote:
>>>       
>>>> George wrote:
>>>>         
>>>>> On Mon, 2017-06-05 at 15:59 +0700, Peter & Kelly Passchier wrote:
>>>>>           
>>>>>> On 05/06/2560 15:52, George wrote:
>>>>>>             
>>>>>>> there's not a reliable mechanism in place to run a script in a 
>>>>>>> locale whose character encoding doesn't match that of the script 
>>>>>>>               
>
>   
>>    Right.  The 1st paragraph (written by you), above, mentions that. 
>> Given the 1st paragraph (which no one is contesting), we are only
>> talking about the case where the run locale and script locale are the same.
>>     
Actually, I need to correct myself since BASH and other computer
languages have run in non-native locales since forever.  The compilers
and interpreters don't necessarily pay attention to the current locale. 
So of course the scripts will run in any locale.
My bad for my uncritical thinking (something that usually doesn't win
me any friends)...


>
> You need someone to explicit say it?  OK, I'll say it.
>
> Scripts that can only *run* in a UTF-8 encoding-locale are a bad idea.
> The whole world is not UTF-8, despite what a few people seem to think.
>   
No one said the entire world is UTF-8.  But seems like most of the major
linux vendors default to UTF-8 for console activity.  Bash *is* the linux
shell.  It's being adopted elsewhere, but it seems to have first grown
in use in the linux community.  No one is saying it shouldn't continue
to support ASCII, in fact to remain POSIX compat, it would have to.
> That's in addition to all of the issues that arise when trying to *edit*
> a script that was written in one or more character set encodings that
> are different from yours.  
If you look at the locales on a recent linux distro, (locale -a), out of
279 country codes, you'll see
  9 that only have a local-encoding listed.
 98 have no encoding listed (guessing they default to POSIX)
172 that have UTF-8
   and
139 that ONLY have UTF-8 listed.

Just from the numbers if you _don't_ support UTF-8 you support
131 locales (47%).  If you do support UTF-8, you can reach
270 locales (97%).

Seems that by supporting UTF-8, you have a good chance of being
understandable in over 95% of the locales in the locale database,
vs. less than 50% if you don't (quick perlscript used to count
that, attached if you want to run it on your own data, or point
out some mistake in my calculations)

Seems like a reasonable tradeoff.

> One could almost make a viable case that
> "only people on UTF-8 computers are allowed to be developers".  Almost.
>   
---
    I already stated that if you want to create your script for wide
distribution one should use the least-common-denominator, but for your
own systems, shouldn't you have the freedom to write in your native
locale?
> But if you also intend to exclude such people from even being able to
> *run* your script, I can't take any of this seriously.
>   
I thought it was the case that such scripts would *run* regardless of
how they looked in an editor.

> (OK, in reality, I am not taking any of this seriously.  This entire
> proposal and discussion are like some bizarre fantasy land to me.  Bash
> is a SHELL, for god's sake.  Not a serious programming language. 
>   
Right, but ksh93 & zsh already support it in varnames, while
ksh93, zsh, bash and mksh all support UTF-8 in function names.











--------------050504080507060902000704
Content-Type: text/plain;
 name="count"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
 filename="count"

IyEvdXNyL2Jpbi9lbnYgcGVybAoKdXNlIHdhcm5pbmdzOyB1c2Ugc3RyaWN0Owp1c2UgUDsg
dXNlIFR5cGVzOjpDb3JlOwkJI05vdGU6IGluIENQQU47IGxvYWQgdy8gImNwYW4gLWkgUCBU
eXBlczo6Q29yZSIKCiMgTk9URTogZXhwZWN0cyBpbnB1dCBvbiBTVERJTiBmcm9tICJsb2Nh
bGVzIC1hIiwgYXMgaW4KIyAgICAgICAibG9jYWxlIC1hIHwgY291bnQiCgpteSAoJWxvYywl
ZW5jcyk7Cgp3aGlsZSAoPD4pIHsKCWxlbmd0aCB8fCBuZXh0OwoJY2hvbXA7CglsZW5ndGgg
fHwgbmV4dDsKCW15ICgkbCwkZSkgPSBte14oWy1cd10rKSg/OlsuQF0oWy1cd10rKSk/JH07
CglQICJfPSVzLCAobCxlPSkoJXMsJXMpIiwgJF8sICRsLCAkZSB1bmxlc3MgJGw7CgkkbG9j
eyRsfT17fSB1bmxlc3MgSEFTSCAkbG9jeyRsfTsKCWlmICgkZSkgewoJCSRlPSJVVEYtOCIg
aWYgJGUgZXEgInV0ZjgiOwoJCSRsb2N7JGx9LT57JGV9Kys7Cgl9Cn07ClAgInVuaXEgbGFu
Z3MgID0gICAgICAgJTNkIiwgc2NhbGFyIGtleXMgJWxvYzsKCm15ICgkbm9jaGFycywkbm91
dGY4LCAkb25seV91dGY4LCAkdXRmOCk7Cgpmb3IgKGtleXMgJWxvYykgewoJbXkgJGVwCQk9
ICRsb2N7JF99OwoJbXkgQGVsc3QJPSBrZXlzICUkZXA7CglteSAkZW51bQk9IHNjYWxhciBA
ZWxzdDsKCWlmICgkZW51bSA9PSAwKSB7ICsrJG5vY2hhcnMgfQoJZWxzZSB7CgkJbXkgKCRo
dmxvYywgJGh2dXRmOCwgJGUpID0gKDAsIDApOwoJCSRfIGVxICJVVEYtOCIgPyAkaHZ1dGY4
ID0gMSA6ICRodmxvYyA9IDEgZm9yIEBlbHN0OwoJCSRodmxvYyA/ICRodnV0ZjggPyArKyR1
dGY4IDogKyskbm91dGY4IAoJCQkJCSA6ICRodnV0ZjggYW5kICsrJG9ubHlfdXRmOCwgKysk
dXRmODsKCX0KfQpQICJsYW5ncyB3L25vIGVuY29kaW5nICUzZCIsICRub2NoYXJzOwpQICJs
YW5ncyB3L2xvY2FsIG9ubHk6ICUzZCIsICRub3V0Zjg7ClAgImxhbmdzIHcvdXRmODogICAg
ICAgJTNkIiwgJHV0Zjg7ClAgImxhbmdzIHcvdXRmOCBvbmx5OiAgJTNkIiwgJG9ubHlfdXRm
ODsK
--------------050504080507060902000704--


From MAILER-DAEMON Tue Jun 06 15:12:30 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIJu2-0000DZ-9L
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 15:12:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33473)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIJu0-0000DO-Jb
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:12:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIJtx-0005f4-Gz
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:12:28 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:60024 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dIJtx-0005ex-8N
	for bug-bash@gnu.org; Tue, 06 Jun 2017 15:12:25 -0400
Received: (qmail 56468 invoked from network); 6 Jun 2017 19:12:23 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Tue, 06 Jun 2017 15:12:23 -0400
Received: (qmail 6764 invoked by uid 563); 6 Jun 2017 19:12:23 -0000
Date: Tue, 6 Jun 2017 15:12:23 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
Message-ID: <20170606191223.GL3691@eeg.ccf.org>
References: <20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
	<5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
	<5936B5B3.3000006@tlinx.org> <20170606142003.GF3691@eeg.ccf.org>
	<5936FC51.9060204@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5936FC51.9060204@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 19:12:29 -0000

On Tue, Jun 06, 2017 at 12:02:41PM -0700, L A Walsh wrote:
> Bash *is* the linux
> shell.  It's being adopted elsewhere, but it seems to have first grown
> in use in the linux community.

Bash predates Linux.  Bash was first released in 1989.  Linux wasn't
released until 1991.

Bash is the GNU shell, and the GNU utilities were first used on commercial
Unix systems.


From MAILER-DAEMON Tue Jun 06 16:08:30 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIKmE-0006s8-9Z
	for mharc-bug-bash@gnu.org; Tue, 06 Jun 2017 16:08:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46467)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIKmD-0006s2-05
	for bug-bash@gnu.org; Tue, 06 Jun 2017 16:08:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dIKm8-0006Xg-0H
	for bug-bash@gnu.org; Tue, 06 Jun 2017 16:08:28 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:43110
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dIKm7-0006WO-Lx
	for bug-bash@gnu.org; Tue, 06 Jun 2017 16:08:23 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v56K8GDk061294; Tue, 6 Jun 2017 13:08:18 -0700
Message-ID: <59370BB0.8020008@tlinx.org>
Date: Tue, 06 Jun 2017 13:08:16 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
References: <20170604074538.36cmislgervrqiqw@debian>	<593455D1.9050706@tlinx.org>	<1496652739.17253.82.camel@scope-eye.net>	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>	<1496702373.17253.179.camel@scope-eye.net>	<5935E659.9040308@tlinx.org>	<1496734633.17253.275.camel@scope-eye.net>	<5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>	<5936FC51.9060204@tlinx.org>
	<20170606191223.GL3691@eeg.ccf.org>
In-Reply-To: <20170606191223.GL3691@eeg.ccf.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 06 Jun 2017 20:08:29 -0000

Greg Wooledge wrote:
> On Tue, Jun 06, 2017 at 12:02:41PM -0700, L A Walsh wrote:
>   
>> Bash *is* the linux
>> shell.  It's being adopted elsewhere, but it seems to have first grown
>> in use in the linux community.
>>     
>
> Bash predates Linux.  Bash was first released in 1989.  Linux wasn't
> released until 1991.
>
> Bash is the GNU shell, and the GNU utilities were first used on commercial
> Unix systems.
>   
----
    Thanks for the history lesson (for those of us who were too lazy to
goog it ;-)). 

Still, on what OS has it shown the most growth or popularity?
Has there been any other shell that's seen as much use on linux as bash? 
While I had worked on other unix systems (sun, hp, sgi that I remember), I
didn't encounter bash until I saw it on linux.  Before that, I mostly
used ksh as having some "comfort"s over 'sh'. 

    91 was also the year Unicode was first approved (Oct).  Isn't that
an slightly interesting coincidence? :-)

-l





From MAILER-DAEMON Wed Jun 07 08:15:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIZsK-0006IA-QR
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 08:15:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34322)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZsJ-0006I4-7n
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:15:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZsG-0007Wu-0x
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:15:47 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:64551
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIZsF-0007WQ-RR
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:15:43 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMA75047; Wed, 07 Jun 2017 08:15:38 -0400 (EDT)
Received: from casewireless09.CWRU.Edu (EHLO jenna.local) ([129.22.21.193])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFP68116 (AUTH cpr);
	Wed, 07 Jun 2017 08:15:38 -0400 (EDT)
From: Chet Ramey <chet.ramey@case.edu>
Subject: Re: test builtin does not check for nanoseconds while comparing
	timestamps
Reply-To: chet.ramey@case.edu
To: Siteshwar Vashisht <svashisht@redhat.com>, bug-bash@gnu.org
Cc: chet.ramey@case.edu
References: <1340395993.15391170.1496449820570.JavaMail.zimbra@redhat.com>
Organization: ITS, Case Western Reserve University
Message-ID: <0f1e727f-312a-e38d-f50d-0cdda49ca4ab@case.edu>
Date: Wed, 7 Jun 2017 08:15:40 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1340395993.15391170.1496449820570.JavaMail.zimbra@redhat.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.7.113615:17:8.129, ip=,
	rules=__HAS_FROM, FROM_EDU_TLD, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END, __HAS_REPLYTO,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__HAS_CC_HDR, __REFERENCES, __HAS_MSGID, __SANE_MSGID,
	DATE_TZ_NA, __USER_AGENT, __MOZILLA_USER_AGENT,
	__MIME_VERSION, __IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, SUPERLONG_LINE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_500_599, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS,
	__SINGLE_URI_TEXT, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 07 Jun 2017 12:15:48 -0000

On 6/2/17 5:30 PM, Siteshwar Vashisht wrote:

> Bash Version: 4.3
> Patch Level: 43
> Release Status: release
> 
> Description:
>         If the modified timestamp of 2 files differ by less than 1 second, test builtin sometimes returns incorrect result. It happens because HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC is not defined in config.h.

Thanks for the report.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 07 08:16:15 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIZsl-0006WN-09
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:15 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34527)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZsi-0006Uz-4y
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZse-0007fH-VD
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:12 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:26383
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIZse-0007eT-Pj
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:08 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANK75417; Wed, 07 Jun 2017 08:16:07 -0400 (EDT)
Received: from casewireless09.CWRU.Edu (EHLO jenna.local) ([129.22.21.193])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFP68158 (AUTH cpr);
	Wed, 07 Jun 2017 08:16:07 -0400 (EDT)
From: Chet Ramey <chet.ramey@case.edu>
Subject: Re: Builtin read with -n0 or -N0 (nchars == 0) behaves as a read with
	no -n/-N argument
Reply-To: chet.ramey@case.edu
To: Pranav Deshpande <deshpande.v.pranav@gmail.com>
Cc: chet.ramey@case.edu, bug-bash@gnu.org,
	Eduardo Bustamante <dualbus@gmail.com>
References: <CAOSMAut1aPYc6XzMBBUjmvUVj8MNcuVCcVZBV=2zay6q-V0Z6Q@mail.gmail.com>
	<2d102524-0a27-ef61-1cb0-48a538e5db6c@case.edu>
	<CANFkxPL6C=ZCXrkgfwDeTQr6z9jnem2OjE5EpmdbMNOHoTaFvA@mail.gmail.com>
	<CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
Organization: ITS, Case Western Reserve University
Message-ID: <3457e8b1-9e4e-2423-92f1-10923630e370@case.edu>
Date: Wed, 7 Jun 2017 08:16:09 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CANFkxP+ho8DYF50XzvjPEMphDNWjiO3AcTHsHhYcqtj0g94NGQ@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.7.105715:17:8.317, ip=,
	rules=__HAS_FROM, FROM_EDU_TLD, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END, __HAS_REPLYTO,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2, __CC_NAME,
	__CC_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_600_699, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 07 Jun 2017 12:16:13 -0000

On 6/3/17 1:15 PM, Pranav Deshpande wrote:
> Hello,
> Sorry for the late reply.
> 
> My solution is to change *line 294* of builtins/read.def.
> 
> Change
> if (code == 0 || *intval < 0* || intval != (int)intval)
> 
> to
> 
> if (code == 0 || i*ntval <= 0* || intval != (int)intval)

That's a fine solution for behavior 1.  If you'd prefer behavior 2,
obviously you have to do something else. :-)

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 07 08:16:27 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIZsx-0006dX-56
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:27 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34592)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZsu-0006br-M9
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:25 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIZsr-0007j4-Fr
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:24 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:26430
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIZsr-0007iv-AE
	for bug-bash@gnu.org; Wed, 07 Jun 2017 08:16:21 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANK75429; Wed, 07 Jun 2017 08:16:17 -0400 (EDT)
Received: from casewireless09.CWRU.Edu (EHLO jenna.local) ([129.22.21.193])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFP68166 (AUTH cpr);
	Wed, 07 Jun 2017 08:16:14 -0400 (EDT)
From: Chet Ramey <chet.ramey@case.edu>
Subject: Re: minor: man-page: history file time comments for following not
	preceding history line
Reply-To: chet.ramey@case.edu
To: =?UTF-8?Q?J=c3=b6rn_Hees?= <dev@joernhees.de>, bug-bash@gnu.org
Cc: chet.ramey@case.edu
References: <F4A5F9FA-2484-4AFE-8193-F16337EACB1C@joernhees.de>
Organization: ITS, Case Western Reserve University
Message-ID: <67c0a892-b82c-b267-9a17-e8d16bfbe265@case.edu>
Date: Wed, 7 Jun 2017 08:16:16 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <F4A5F9FA-2484-4AFE-8193-F16337EACB1C@joernhees.de>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.7.105715:17:7.944, ip=,
	rules=__HAS_FROM, FROM_EDU_TLD, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END, __HAS_REPLYTO,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__HAS_CC_HDR, __REFERENCES, __HAS_MSGID, __SANE_MSGID,
	DATE_TZ_NA, __USER_AGENT, __MOZILLA_USER_AGENT,
	__MIME_VERSION, __IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	SINGLE_URI_IN_BODY, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 07 Jun 2017 12:16:26 -0000

On 6/4/17 6:36 AM, Jörn Hees wrote:
> Hi,
> 
> in the HISTORY section of the man-page it says:
> 
>> ... When the history  file
>> is  read, lines beginning with the history comment character followed immediately by a digit are interpreted
>> as timestamps for the preceding history line.
> 
> s/preceding/following/

Thanks for the report.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 07 17:03:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIi6t-0003X1-Bw
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 17:03:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43227)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dIi6q-0003Va-QO
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:03:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dIi6k-000778-NI
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:03:19 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:33764
	helo=homiemail-a46.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dIi6k-00076Y-Bo
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:03:14 -0400
Received: from homiemail-a46.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a46.g.dreamhost.com (Postfix) with ESMTP id F2D225530;
	Wed,  7 Jun 2017 14:03:08 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=TjbnKsEhV+FHIcvB
	fZnawZZYoK4=; b=DponSYoMDjKsToXGZ3J6fdYaGXGUGcx6C5DpVhUAzXVilWF6
	xFKZmE1VWs0sgAT1aJOQyT/A6kfE8CNccDMNDEquzKgAZB7VPCAqcn6Z7SP6mVVN
	lc72Do8vL/n1x2Vc8NTKP1BReeuEl9XvYmvncWqGfHrHT7QCnqrEn2Hk8DA=
Received: from frontier (unknown [76.191.34.78])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a46.g.dreamhost.com (Postfix) with ESMTPSA id 9BB3F552E;
	Wed,  7 Jun 2017 14:03:08 -0700 (PDT)
Message-ID: <1496869388.17253.349.camel@scope-eye.net>
Subject: Re: Patch for unicode in varnames...
From: George <tetsujin@scope-eye.net>
To: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Date: Wed, 07 Jun 2017 17:03:08 -0400
In-Reply-To: <20170606142003.GF3691@eeg.ccf.org>
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net> <5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 07 Jun 2017 21:03:22 -0000

On Tue, 2017-06-06 at 10:20 -0400, Greg Wooledge wrote:
> (OK, in reality, I am not taking any of this seriously.=C2=A0=C2=A0This=
 entire
> proposal and discussion are like some bizarre fantasy land to me.=C2=A0=
=C2=A0Bash
> is a SHELL, for god's sake.=C2=A0=C2=A0Not a serious programming langua=
ge.=C2=A0=C2=A0Even
> serious programming languages are not ready for this; see the Python
> proposal that was mentioned up-thread.)
>=20
I don't think "shell" and "serious programming language" must be consider=
ed mutually exclusive.
Shell scripting is "serious" in the sense that there are people who rely =
upon and actively develop shell scripts to keep their products working. I=
f
the language itself seems not "serious" I think that is because not enoug=
h effort has been made to extend and improve its functionality over time.=
 (At
least, not in the Bash project... =C2=A0Korn Shell has done some good wor=
k along those lines.)
But I think the "interactive" aspect is probably the most compelling argu=
ment for supporting something like this. The shell can serve as one of th=
e
primary tools for operating the computer. As such it should also aim to b=
e a comfortable environment. If you tell a programmer that a shell only
accepts ASCII in some contexts, there's a fair chance they'll understand =
why, and accept the limitation. For more casual users, this may not be th=
e
case. I think they'd be likely to wonder why they can't use accented char=
acters, or other alphabets for parameter names. I don't think there's a
particularly good reason not to allow it... =C2=A0Though I'd personally l=
ike to see it implemented in a way that allows scripts to take advantage =
of that,
and still work reliably regardless of the locale setting in which they're=
 ultimately run.
As a side note, I had expressed concern that Bash might not work correctl=
y with GB-18030 encoding, but it appears that I was wrong. I set up a
terminal to display the GB-18030 character set, set the locale within the=
 terminal to GB-18030, and formed a string that I would expect to expose =
a
parser bug (a string of multi-byte Chinese characters including 0x7C, the=
 byte that corresponds to the ASCII vertical bar character), but it appea=
red
to parse the string correctly according to the locale rather than break i=
t up on the 0x7C byte. So that's good. :)

From MAILER-DAEMON Wed Jun 07 18:04:37 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIj49-0005eQ-QS
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 18:04:37 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49719)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dethrophes@web.de>) id 1dIicS-0004dE-7A
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:36:01 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dethrophes@web.de>) id 1dIicO-0002bQ-Vq
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:36:00 -0400
Received: from mout.web.de ([212.227.17.12]:59890)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dethrophes@web.de>) id 1dIicO-0002Zb-Em
	for bug-bash@gnu.org; Wed, 07 Jun 2017 17:35:56 -0400
Received: from [10.43.11.15] ([213.105.49.242]) by smtp.web.de (mrweb102
	[213.165.67.124]) with ESMTPSA (Nemesis) id 0MYw1v-1dNpAL2DQ3-00VkkG;
	Wed, 07 Jun 2017 23:35:19 +0200
Date: Wed, 07 Jun 2017 22:33:50 +0100
User-Agent: K-9 Mail for Android
In-Reply-To: <1496869388.17253.349.camel@scope-eye.net>
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
	<5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
	<5936B5B3.3000006@tlinx.org> <20170606142003.GF3691@eeg.ccf.org>
	<1496869388.17253.349.camel@scope-eye.net>
MIME-Version: 1.0
Subject: Re: Patch for unicode in varnames...
To: bug-bash@gnu.org, George <tetsujin@scope-eye.net>,
	Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
From: Dethrophes <dethrophes@web.de>
Message-ID: <697E1957-01B5-4283-89CE-AF052DA3171B@web.de>
X-Provags-ID: V03:K0:IA+H8EzLVt7C27EnTv6qgZKK09sGlorkDHAFUFkezccERqtgdAd
	YHXjX+fNfimsbtw6FsgppArc9cgCCZ+BDVuL4bsj1pCHDjpc8qVpgt3+HG8l60X3JgJ9oda
	MZoxYCh9Ghtn+bYZpOrHWjwehwyzSbP03GRrLh+HtTmYf9+ipaOfaDHKNYax8ktPJMittC8
	b9EPw7mTntDjtggxADYmQ==
X-UI-Out-Filterresults: notjunk:1;V01:K0:S4lkH1N6UA4=:Vn68hjfizf63phdI84YkOK
	9XsiXYQBeYx3xgzmJ7Q3S5nk+aFDAGpJZRCAL36wr99yAqiutgK33uvrGku0iLEQmrHSvZu1S
	919E31Es0Uns/I/eEV/39heM6qn5O5e/0bYoUrKz+VDHh1nhrJZvcF+eLC5zQlFK8s9CjEWXa
	Hm8Sw1ayMlkGYcAj7wZXg/zSvxox8WJn4jlWpW3VL69hkr6o3IZkqGve9/ypCm+g8PztZpgA4
	YDR7hHWAkiYn0YnV0BpROrDIYIOi9ix4M9uo+nz6nzenRy5n3kqr2RJP8W3FFlI7dzPFtIiDX
	rvd0EMdFW95z+8mG4LR3GG9G8n1cu4HAxC04IL+CiMHybuwIaFPEBY8IpelAFHr4K186MKWkB
	/wdOuBdqImkRK4O4RJowpvij96ZG5HdHBQFd0J/RDRiol/Nb+x+C16VRixsX0q9aVs88ccRSa
	O/VhYGOE1uO++p+FihQ9BxsoW6DGi2FR47FAvIGV3lsbRIHNdzkjeKDrjc56LSEz8rmekuHTt
	y2UqCrkjmJsfl6OxzWso4ZG+mIOpV1uNFXk3KicKtYSEoSDtbb+F6rUm2HDJNeFw7u2NqOts0
	9k7vJT7T4UVXR1ah3gTRo2aafOb/vmg2+b3hQUqATjC/6XU8W2bORH02B6GYigKhvUNWVuGx4
	NNXJ7xdhqwxKI7CnxyaflHM8ovebZhKO1bw+X/scNRHxi5WaiM9hj+dATLiQy09+ykI2JwTr/
	Nyj5zVklpKVuvRfZLTS7y+yhabSN0b9JdvxrXm6tGHCsxu+fGYz/lXi+J0xcw0eTSYYflfeid
	Q9w/a1E
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 212.227.17.12
X-Mailman-Approved-At: Wed, 07 Jun 2017 18:04:36 -0400
Content-Type: text/plain;
 charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 07 Jun 2017 21:36:02 -0000

Instead of talking in terms of seriousness, it may be more use to think in =
terms of formality=2E=20

Even in gramitically strong and formal languages variable and function nam=
es are restricted in the characters they may use=2E This is not just becaus=
e it makes the parsing simpler but because it simplifies reading comprehens=
ion of the code=2E=20

Now bash is already very difficult for most to appreciate the subtitles of=
 how it is written=2E Supporting an almost endless number of characters in =
car and fun names would just make it endlessly more complex to understand=
=2E

This would be a bad idea in the same way that having control characters in=
 filenames is a bad idea, just because you can do something doesn't mean yo=
u should=2E

This is also a question of the tco (total cost of ownership) of code=2E Th=
e flexible you allow the coding to be the more difficult it is to understan=
d others code=2E Perl(need to be a guru to read someone else's code) vs pyt=
hon(a noob can figure it out pretty quickly with Google=2E)=2E




On June 7, 2017 10:03:08 PM GMT+01:00, George <tetsujin@scope-eye=2Enet> w=
rote:
>On Tue, 2017-06-06 at 10:20 -0400, Greg Wooledge wrote:
>> (OK, in reality, I am not taking any of this seriously=2E=C2=A0=C2=A0Th=
is entire
>> proposal and discussion are like some bizarre fantasy land to
>me=2E=C2=A0=C2=A0Bash
>> is a SHELL, for god's sake=2E=C2=A0=C2=A0Not a serious programming
>language=2E=C2=A0=C2=A0Even
>> serious programming languages are not ready for this; see the Python
>> proposal that was mentioned up-thread=2E)
>>=20
>I don't think "shell" and "serious programming language" must be
>considered mutually exclusive=2E
>Shell scripting is "serious" in the sense that there are people who
>rely upon and actively develop shell scripts to keep their products
>working=2E If
>the language itself seems not "serious" I think that is because not
>enough effort has been made to extend and improve its functionality
>over time=2E (At
>least, not in the Bash project=2E=2E=2E =C2=A0Korn Shell has done some go=
od work
>along those lines=2E)
>But I think the "interactive" aspect is probably the most compelling
>argument for supporting something like this=2E The shell can serve as one
>of the
>primary tools for operating the computer=2E As such it should also aim to
>be a comfortable environment=2E If you tell a programmer that a shell
>only
>accepts ASCII in some contexts, there's a fair chance they'll
>understand why, and accept the limitation=2E For more casual users, this
>may not be the
>case=2E I think they'd be likely to wonder why they can't use accented
>characters, or other alphabets for parameter names=2E I don't think
>there's a
>particularly good reason not to allow it=2E=2E=2E =C2=A0Though I'd person=
ally like
>to see it implemented in a way that allows scripts to take advantage of
>that,
>and still work reliably regardless of the locale setting in which
>they're ultimately run=2E
>As a side note, I had expressed concern that Bash might not work
>correctly with GB-18030 encoding, but it appears that I was wrong=2E I
>set up a
>terminal to display the GB-18030 character set, set the locale within
>the terminal to GB-18030, and formed a string that I would expect to
>expose a
>parser bug (a string of multi-byte Chinese characters including 0x7C,
>the byte that corresponds to the ASCII vertical bar character), but it
>appeared
>to parse the string correctly according to the locale rather than break
>it up on the 0x7C byte=2E So that's good=2E :)

--=20
Envoy=C3=A9 de mon t=C3=A9l=C3=A9phone Android avec K-9 Mail=2E Excusez la=
 bri=C3=A8vet=C3=A9=2E

From MAILER-DAEMON Wed Jun 07 21:32:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dImJN-0008GB-MZ
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 21:32:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36133)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dImJK-00085H-BK
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:32:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dImJH-0004Tj-64
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:32:30 -0400
Received: from mail-pg0-x22c.google.com ([2607:f8b0:400e:c05::22c]:35030)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dImJH-0004Sf-0A
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:32:27 -0400
Received: by mail-pg0-x22c.google.com with SMTP id k71so10728184pgd.2
	for <bug-bash@gnu.org>; Wed, 07 Jun 2017 18:32:25 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:to:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=Yr0et+wP9zObl9dBIWU+HESAhtBrqVFoWdczIDiFYkU=;
	b=Nfu8qG5bieTtAtWsIaPNGknHML4yjohorQxJy7rkxe23F1iPcXlxCZstxSVOtKtZW0
	VMOHmZCCNeRXdrc1nvJxnhVCcavnrdi4cI/zafDnre7M5kfqPcATSWd45nRY7PQvMLrK
	3n1TEqL4ykQzPo5kXE+sqxeWsHjWbps46Qd+EyftZVX142INi7eEqtbQtS1zc6iDwAu+
	7Nr+tZfarQqkOEwmU1gaNijytaBAtyVypwJKUeGo0VFSk5UVl8ECpL8wEnaL5YJDAUVO
	BfKln/W17ccdSXOnUu1v23tXEGukOLQdFnGWZdF8bkd2FnGbpxHZmfXjZZ0ZbdUm2aj0
	9uNA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:to:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=Yr0et+wP9zObl9dBIWU+HESAhtBrqVFoWdczIDiFYkU=;
	b=rMqWOMkNzWtBpYS3Dl5HUuYndwn8MmvNZfx8egqm69TRFTs4xJeXQV2/a3l/D33U5v
	Ja3y4y3JSLpW/EufexVsFbKNIzPDwwGmIB0Byp9qvFHFfKK2Y1zyskUuf0dk1eZug/Tg
	AQB+8lJxTC2pyTjtxQeeNzkszwn5mKgMMLb/IDTXmK+gbIih/MOTMJMLib+lLBoE4i5h
	LXuBWWztFeZ1ibKGL8fF0wOSLSgGHjvl9hA+5IHPvdmkGnXI73TUVEpkEIC2NeuHdsLK
	jSN2k+FDpMm00nefhCw672+54J6hJOKo0ut4/M/7ix2QId6F109OXQhPFcqFCGLlTm8X
	WqgA==
X-Gm-Message-State: AODbwcAaZAvWrUkC8KrpDucQMhS84J0PfKlX8qqNu6MplFZmMQjWXlhT
	cAu92u2Bb8QWuXZe
X-Received: by 10.98.65.26 with SMTP id o26mr16201631pfa.88.1496885544406;
	Wed, 07 Jun 2017 18:32:24 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	w10sm4741927pge.48.2017.06.07.18.32.22 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Wed, 07 Jun 2017 18:32:23 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Patch for unicode in varnames...
To: bug-bash@gnu.org
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net> <5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>
	<1496869388.17253.349.camel@scope-eye.net>
	<697E1957-01B5-4283-89CE-AF052DA3171B@web.de>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <208aa83e-f89d-5e96-57d8-1c167537f150@passchier.net>
Date: Thu, 8 Jun 2017 08:32:21 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <697E1957-01B5-4283-89CE-AF052DA3171B@web.de>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::22c
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 01:32:32 -0000

On 08/06/2560 04:33, Dethrophes wrote:
> This would be a bad idea in the same way that having control characters in filenames is a bad idea, just because you can do something doesn't mean you should.

I would personally advocate NOT to use it in code. But then, I am
biassed by upbringing towards ASCII... But, I wouldn't want others to be
deprived of the option.

Remember, function names, and aliases already can be in unicode
encodings! Which probably already helps shell endusers the most. But
allowing variable names in unicode is a logical progression, and as we
can see from Eduardo's quick patch, doesn't involve a big overhead in
added complexity.

(Advocating because of living now in a country with a different script.)
Peter


From MAILER-DAEMON Wed Jun 07 21:46:55 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dImXH-00043z-De
	for mharc-bug-bash@gnu.org; Wed, 07 Jun 2017 21:46:55 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38248)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dImXD-00043d-Pv
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:46:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dImXA-000091-Mz
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:46:51 -0400
Received: from mail-oi0-x242.google.com ([2607:f8b0:4003:c06::242]:36785)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dImXA-00008A-GL
	for bug-bash@gnu.org; Wed, 07 Jun 2017 21:46:48 -0400
Received: by mail-oi0-x242.google.com with SMTP id g14so1515439oib.3
	for <bug-bash@gnu.org>; Wed, 07 Jun 2017 18:46:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=bh86rNkwKPFjeSrSvXLZTPlLSj7eSwngv5NHa+YDzWY=;
	b=q8Vps8wE/gUzPzVDsdJZEgKpiCb3mGDtpDionnhAcsQ5lNPdbaoMBtFoSKypyJCXUo
	06TgWNtU23iVtvK8OWKngHstrt0UMuOOIyQON2hhaRRbk/ufq2L4VDor//og3cgLpOWX
	W40Y4FuF9S4ZYFcvrdihKpvZSxaorqLw9yMzyWv7+QJJf7JOzwf5te7DaoIkHIYYvqwQ
	tmee0DYzHydUMS6D/fFXZ57y/FnGcjauY+9P3bhwmlah5uhMU0j1PoLfn7xO20Grxv9l
	QBL6chaxTl/DMtj4CtCP/hYMmxXoLw7fUvQMZRhFZFgyaV+Q1uzDlcdOVQlH6VZjFxh5
	pNMQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=bh86rNkwKPFjeSrSvXLZTPlLSj7eSwngv5NHa+YDzWY=;
	b=TqIzZz3O2i0J5zJnn8px2Ur+W3pXBSMfE5FKKDa7219pXeTlMBsU7/BlzuMKfT4qBi
	zgzLIHiJ/MpADm842nbpZQH8xh13SB+UzFxsH8AnftmM53nutAbMttOvqH546ts+vwJj
	AbIVW3WM4LGvg3VY8BlvZCRGt/oRay6f3qo58Pzn3V+i0nEzRt3OnOAEtIIhPtu82nAr
	qATP9QZHJ4YRMuOvmbdOjSpNzj25qx/eU9GoJRYgw7ApCJLoOFhSyeSIu/XHVGk7aZ2s
	ghyCPJGWsUo7Mgcpif53TMLJNpsK4EA/XdxwWIdz4FOyOL2GQktx2N5l7L3LNiCG3ipY
	yFbg==
X-Gm-Message-State: AODbwcB8JmGH5zmh+a+mZZD1ibD3MBDXQpfDv3kIuUkR5MH4Ky3xf8cx
	lmOz21Qljqh6WEGx
X-Received: by 10.202.220.67 with SMTP id t64mr16264928oig.134.1496886406083; 
	Wed, 07 Jun 2017 18:46:46 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	p20sm1958209otp.29.2017.06.07.18.46.45 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Wed, 07 Jun 2017 18:46:45 -0700 (PDT)
Date: Wed, 7 Jun 2017 20:46:43 -0500
From: dualbus <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: [PATCH] Memory leak in locale.c set_default_locale
Message-ID: <20170608014643.gyghstg3tnsil6ko@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::242
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 01:46:54 -0000

Found by running the test suite under ASAN.

    =================================================================
    ==3298==ERROR: LeakSanitizer: detected memory leaks
    
    Direct leak of 12 byte(s) in 1 object(s) allocated from:
        #0 0x7f2b94db1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
        #1 0x558589eb06d6 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x14f6d6)
        #2 0x558589ea2c62 in set_default_locale (/home/dualbus/src/gnu/bash-build/bash+0x141c62)
        #3 0x558589de17f0 in main (/home/dualbus/src/gnu/bash-build/bash+0x807f0)
        #4 0x7f2b945442b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    
    SUMMARY: AddressSanitizer: 12 byte(s) leaked in 1 allocation(s).


*** /tmp/R6GbnO_locale.c	2017-06-07 20:40:25.575118629 -0500
--- locale.c	2017-06-07 20:39:59.054419575 -0500
***************
*** 85,91 ****
    textdomain (PACKAGE);
  
    locale_mb_cur_max = MB_CUR_MAX;
!   locale_utf8locale = locale_isutf8 (default_locale);
    locale_shiftstates = mblen ((char *)NULL, 0);
  }
  
--- 85,98 ----
    textdomain (PACKAGE);
  
    locale_mb_cur_max = MB_CUR_MAX;
!   locale_utf8locale = 0;
! #if defined (HAVE_SETLOCALE)
!   if (default_locale)
!     {
!       locale_utf8locale = locale_isutf8 (default_locale);
!       free (default_locale);
!     }
! #endif /* HAVE_SETLOCALE */
    locale_shiftstates = mblen ((char *)NULL, 0);
  }
  
-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 08 09:59:49 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIxyX-0000OM-DT
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 09:59:49 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54790)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIxyV-0000Lx-Ar
	for bug-bash@gnu.org; Thu, 08 Jun 2017 09:59:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIxyQ-0000X6-Fm
	for bug-bash@gnu.org; Thu, 08 Jun 2017 09:59:47 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:25455
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIxyQ-0000Ve-At
	for bug-bash@gnu.org; Thu, 08 Jun 2017 09:59:42 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANL33271; Thu, 08 Jun 2017 09:59:40 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFH24224 (AUTH cpr);
	Thu, 08 Jun 2017 09:59:39 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: [PATCH] Memory leak in locale.c set_default_locale
To: dualbus <dualbus@gmail.com>, bug-bash@gnu.org
References: <20170608014643.gyghstg3tnsil6ko@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <cda90a45-fed0-1c00-764a-5391d07bd59f@case.edu>
Date: Thu, 8 Jun 2017 09:59:39 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608014643.gyghstg3tnsil6ko@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.8.125415:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_1700_1799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	__PHISH_SPEAR_STRUCTURE_1, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 13:59:48 -0000

On 6/7/17 9:46 PM, dualbus wrote:

> *** /tmp/R6GbnO_locale.c	2017-06-07 20:40:25.575118629 -0500
> --- locale.c	2017-06-07 20:39:59.054419575 -0500
> ***************
> *** 85,91 ****
>     textdomain (PACKAGE);
>   
>     locale_mb_cur_max = MB_CUR_MAX;
> !   locale_utf8locale = locale_isutf8 (default_locale);
>     locale_shiftstates = mblen ((char *)NULL, 0);
>   }
>   
> --- 85,98 ----
>     textdomain (PACKAGE);
>   
>     locale_mb_cur_max = MB_CUR_MAX;
> !   locale_utf8locale = 0;
> ! #if defined (HAVE_SETLOCALE)
> !   if (default_locale)
> !     {
> !       locale_utf8locale = locale_isutf8 (default_locale);
> !       free (default_locale);
> !     }
> ! #endif /* HAVE_SETLOCALE */
>     locale_shiftstates = mblen ((char *)NULL, 0);
>   }

This is a glibc issue.  Bash keeps a copy of the default locale for its
own purposes, and copies it because the return value from setlocale() is
an opaque pointer. glibc happens to store it in malloc'd memory, but there
is no requirement that setlocale() do so, and other systems (Mac OS X) do
not.  I'm not sure why this is considered a leak, though, since glibc keeps
a handle on the memory for the current locale.

Even though glibc allocates the memory for the current locale, the man page
warns not to assume that:

"A successful call to setlocale() returns an opaque string  that  corre-
sponds to the locale set.  This string may be allocated in static storage."

Posix contains similar warning language.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 08 10:24:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIyMT-0005zp-15
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 10:24:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33378)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIyMQ-0005xE-2Y
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:24:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIyMM-0005E1-VG
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:24:30 -0400
Received: from mail-oi0-x229.google.com ([2607:f8b0:4003:c06::229]:36044)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dIyMM-0005Ds-Py
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:24:26 -0400
Received: by mail-oi0-x229.google.com with SMTP id k145so10394061oih.3
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 07:24:26 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=7XL8jQ4kH9bdbmeIKt6NcduZ6gq3oh3Wxkn4NIu07Bw=;
	b=FI5S9oe0SLHG28fi2PRrI7iJJVPp9IldEl9Q+rjkYXuMofh8fS8WUvAAWjzJzVDP6m
	ju+g+LIs9xwGlEUZU3W2AC6sxNQWnji6K5aSpgaF2HNl1Fzm+y/IOfFkzxymA8UJ+/qq
	5kM/vVpGkZn6FCVrNk/L7IhZCqtlwkGeA4Y2CCta0NHFqxMcxMe1qZjPOUKJkVxYVi+Q
	36MgeuvLlpHch8ax5+83ZiUJQ+Jg82jDeGj67WFWKk4Nd6tzfeFHvVPPiqIgwQ0QW9yX
	uL7tblnNjGNNuxZfRXR81gcqDhP1OZPSGmYUcHalqgiIlYMaOyqhP9dJ0hkdVmmdU3eW
	YQew==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=7XL8jQ4kH9bdbmeIKt6NcduZ6gq3oh3Wxkn4NIu07Bw=;
	b=YCbkHCmkYDJRh1r266yQpUgCdlvySsI0M9Voso5JMz1Iz/ug6ZKyc3ixjxKXkBCLdO
	kIW5eezb/NdQBsgsSpIlOqShKaxLsQ/pwqXUsM4FDSwEzYFLXo3OxR0FJlm++5KI/QrV
	ErnNTQaXvKAyxRAXrby0t11P4f90LV7nqDc5C35RrlI8XPsGzPLyZzGr6rbt0lfcMmt8
	JnmrnwFLWSUgZsZ1/AddNvTXGhl6gjgzOd7wBpn7xcqHJv0cxDpT0gki50nJ8v3fPqBq
	vHttvRBh7JNcglNNRZLS9OE/yrRdXHqVdXkIsWrzVDES/fC0Lc5ShwvJb+fwR7SZQNfp
	69Bw==
X-Gm-Message-State: AODbwcCBc1Vei8sYWcsNmvMpGRfDNn6BUK3dWU1B2+ectxCuBvzOAafx
	oHM3QBw6Rg5QbA==
X-Received: by 10.202.98.86 with SMTP id w83mr8314917oib.24.1496931865918;
	Thu, 08 Jun 2017 07:24:25 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id b9sm2647635oth.4.2017.06.08.07.24.24
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 08 Jun 2017 07:24:24 -0700 (PDT)
Date: Thu, 8 Jun 2017 09:24:23 -0500
From: dualbus <dualbus@gmail.com>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: [PATCH] Memory leak in locale.c set_default_locale
Message-ID: <20170608142423.yue2g6725dbegyw3@debian>
References: <20170608014643.gyghstg3tnsil6ko@debian>
	<cda90a45-fed0-1c00-764a-5391d07bd59f@case.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <cda90a45-fed0-1c00-764a-5391d07bd59f@case.edu>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 14:24:31 -0000

On Thu, Jun 08, 2017 at 09:59:39AM -0400, Chet Ramey wrote:
[...]
> Even though glibc allocates the memory for the current locale, the man page
> warns not to assume that:
> 
> "A successful call to setlocale() returns an opaque string  that  corre-
> sponds to the locale set.  This string may be allocated in static storage."

Yes. I saw the warning in the manual page.

After a closer reading, I think the Address Sanitizer is complaining
about bash's local copy (the one created with `savestring`) not being
released.

It's not a real issue, but it makes running the tests with ASAN a bit
less useful.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 08 10:30:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIySS-0008O7-Ja
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 10:30:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35150)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIySP-0008Nw-UA
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:30:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIySL-0007tr-1P
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:30:41 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:33378
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIySK-0007tU-Ri
	for bug-bash@gnu.org; Thu, 08 Jun 2017 10:30:36 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANL35797; Thu, 08 Jun 2017 10:30:35 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFH29792 (AUTH cpr);
	Thu, 08 Jun 2017 10:30:35 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: [PATCH] Memory leak in locale.c set_default_locale
To: dualbus <dualbus@gmail.com>
References: <20170608014643.gyghstg3tnsil6ko@debian>
	<cda90a45-fed0-1c00-764a-5391d07bd59f@case.edu>
	<20170608142423.yue2g6725dbegyw3@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <8443b674-49ba-1dd3-a49d-c05b96a24070@case.edu>
Date: Thu, 8 Jun 2017 10:30:34 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608142423.yue2g6725dbegyw3@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.8.135716:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_600_699, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	MULTIPLE_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 14:30:43 -0000

On 6/8/17 10:24 AM, dualbus wrote:

> After a closer reading, I think the Address Sanitizer is complaining
> about bash's local copy (the one created with `savestring`) not being
> released.
> 
> It's not a real issue, but it makes running the tests with ASAN a bit
> less useful.

That would be strange behavior.  If it complains about that, why doesn't it
complain about all memory that bash holds onto but doesn't free before it
exits?


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 08 11:02:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIyxf-0002Gy-E4
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 11:02:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43700)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIyxd-0002Gb-3B
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:02:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIyxZ-0007nR-TT
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:02:57 -0400
Received: from mail-ot0-x236.google.com ([2607:f8b0:4003:c0f::236]:34953)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dIyxZ-0007mz-NO
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:02:53 -0400
Received: by mail-ot0-x236.google.com with SMTP id a2so24712845oth.2
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 08:02:53 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=06f6IFR5/DtA3ZEPLuiqaH1SbhyAvBQevjUpOzqV9ow=;
	b=QbMkp5e3/RbHRnZ1MSYo3FWZKMVMCBGPyRHKb0CLBuT5K+4dglQBF8a3fWYFPVWZAX
	fOErl+ii1A7tqU/WFfWimsSiPs2/FYdIGTT9ckl5cSvLOV+0imlBvoCKjMHCXSH6Nr4d
	aEhj84qA2s0oYGKNY1EWGREG30Pe5o+WpFC7WzQxkuXXhNrvIhhF7SnCKY+sTiDR4G9B
	R3nv4aYkcb++pALUTWAx0CIwtnt37OuRtSxgTMzhvtGSe5SWd4FYGT4rzdWD3EN6QBJ+
	9POxc1hRfPk5jXC8mfVjRouJIHKj9EzqZLIsUzKN4wUtURB7O2yGgVfYCg8BJmpVuBH4
	0pjQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=06f6IFR5/DtA3ZEPLuiqaH1SbhyAvBQevjUpOzqV9ow=;
	b=FeeTR23lXdzOMWRS9AOTf7UCMjDiiDPmsobSZKBZOZzD7RcZ+VxGJ0GybPvTzjMgW+
	t00NF7TDz8SthiVS3zOdgF6c+ecHDIutJkZyUKFDLQ8YN7gl4K0hXBGnmaUC5rQa5tG/
	b6DZtBKecGUblmK3j8TH/W0pJ4R06EEpfPpV726VhSQ6HBArpaILbGYc63s25ifj7eXj
	LK1LQpNuIML98hRtKEd8GxwsMoDCbarmIKVp9r7n3NQx7cFjDrmCPyJh2HQnPxbM1+6t
	ZjF2/vDgo1aapiRO/Pj5yuiyYNKMrRyY7hRiHlbT9+jYm9UP810GYuv7uVB08mUQvd2f
	Y/ew==
X-Gm-Message-State: AODbwcBgssUj02yvfltrNytb5IaDzybuzkHEQ7OqivUue9mpUuznHKwz
	4P5QYP5Y3YE3Ug==
X-Received: by 10.157.36.47 with SMTP id p44mr19903241ota.14.1496934172731;
	Thu, 08 Jun 2017 08:02:52 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	a204sm2823398oii.6.2017.06.08.08.02.51
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 08 Jun 2017 08:02:51 -0700 (PDT)
Date: Thu, 8 Jun 2017 10:02:49 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: [PATCH] Memory leak in locale.c set_default_locale
Message-ID: <20170608150249.7uockuyoh5ta26ni@debian>
References: <20170608014643.gyghstg3tnsil6ko@debian>
	<cda90a45-fed0-1c00-764a-5391d07bd59f@case.edu>
	<20170608142423.yue2g6725dbegyw3@debian>
	<8443b674-49ba-1dd3-a49d-c05b96a24070@case.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <8443b674-49ba-1dd3-a49d-c05b96a24070@case.edu>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 15:02:58 -0000

On Thu, Jun 08, 2017 at 10:30:34AM -0400, Chet Ramey wrote:
[...]
> That would be strange behavior.  If it complains about that, why doesn't it
> complain about all memory that bash holds onto but doesn't free before it
> exits?

Hm. You're right. It seems to be glibc's fault here. The leak happens when I
turn on compiler optimizations, but it goes away if I turn them off. Which
means it's not bash.

Sorry about the noise :-)


== ASAN / -O2 ==

dualbus@debian:~/src/gnu/bash-build$ CFLAGS='-O2 -fsanitize=address -fno-omit-frame-pointer' LDFLAGS=-lasan ../bash/configure --without-bash-malloc && make -j4
[...]
rm -f bash
gcc -L./builtins -L./lib/readline -L./lib/readline -L./lib/glob -L./lib/tilde  -L./lib/sh  -lasan -rdynamic -O2 -fsanitize=address -fno-omit-frame-pointer -Wno-parentheses -Wno-format-security   -o bash shell.o eval.o y.tab.o general.o make_cmd.o print_cmd.o  dispose_cmd.o execute_cmd.o variables.o copy_cmd.o error.o expr.o flags.o jobs.o subst.o hashcmd.o hashlib.o mailcheck.o trap.o input.o unwind_prot.o pathexp.o sig.o test.o version.o alias.o array.o arrayfunc.o assoc.o braces.o bracecomp.o bashhist.o bashline.o  list.o stringlib.o locale.o findcmd.o redir.o pcomplete.o pcomplib.o syntax.o xmalloc.o  -lbuiltins -lglob -lsh -lreadline -lhistory -ltermcap -ltilde     -ldl 
./lib/sh/libsh.a(tmpfile.o): In function `sh_mktmpname':
tmpfile.c:(.text+0x161): warning: the use of `mktemp' is dangerous, better use `mkstemp' or `mkdtemp'
ls -l bash
-rwxr-x--- 1 dualbus dualbus 2916104 Jun  8 09:40 bash
size bash
   text    data     bss     dec     hex filename
2444962  287960   81184 2814106  2af09a bash

dualbus@debian:~/src/gnu/bash-build$ ./bash
bash-4.4$ echo hi
hi
bash-4.4$ exit
exit

=================================================================
==3830==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 12 byte(s) in 1 object(s) allocated from:
    #0 0x7f4981cd1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55d742038866 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x14f866)
    #2 0x55d74202adf2 in set_default_locale (/home/dualbus/src/gnu/bash-build/bash+0x141df2)
    #3 0x55d741f697f0 in main (/home/dualbus/src/gnu/bash-build/bash+0x807f0)
    #4 0x7f49814642b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)

SUMMARY: AddressSanitizer: 12 byte(s) leaked in 1 allocation(s).


== Valgrind / -O2 ==

dualbus@debian:~/src/gnu/bash-build$ CFLAGS='-O2 -fno-omit-frame-pointer' LDFLAGS= ../bash/configure --without-bash-malloc && make -j4 
[...]
rm -f bash
gcc -L./builtins -L./lib/readline -L./lib/readline -L./lib/glob -L./lib/tilde  -L./lib/sh  -rdynamic -O2 -fno-omit-frame-pointer -Wno-parentheses -Wno-format-security   -o bash shell.o eval.o y.tab.o general.o make_cmd.o print_cmd.o  dispose_cmd.o execute_cmd.o variables.o copy_cmd.o error.o expr.o flags.o jobs.o subst.o hashcmd.o hashlib.o mailcheck.o trap.o input.o unwind_prot.o pathexp.o sig.o test.o version.o alias.o array.o arrayfunc.o assoc.o braces.o bracecomp.o bashhist.o bashline.o  list.o stringlib.o locale.o findcmd.o redir.o pcomplete.o pcomplib.o syntax.o xmalloc.o  -lbuiltins -lglob -lsh -lreadline -lhistory -ltermcap -ltilde     -ldl 
./lib/sh/libsh.a(tmpfile.o): In function `sh_mktmpname':
tmpfile.c:(.text+0x161): warning: the use of `mktemp' is dangerous, better use `mkstemp' or `mkdtemp'
ls -l bash
-rwxr-x--- 1 dualbus dualbus 1321952 Jun  8 09:51 bash
size bash
   text    data     bss     dec     hex filename
1114390   47940   40496 1202826  125a8a bash

dualbus@debian:~/src/gnu/bash-build$ valgrind ./bash
==18244== Memcheck, a memory error detector
==18244== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==18244== Using Valgrind-3.12.0.SVN and LibVEX; rerun with -h for copyright info
==18244== Command: ./bash
==18244== 
bash-4.4$ echo hi
hi
bash-4.4$ exit
exit
==18244== 
==18244== HEAP SUMMARY:
==18244==     in use at exit: 347,357 bytes in 2,879 blocks
==18244==   total heap usage: 4,406 allocs, 1,527 frees, 607,170 bytes allocated
==18244== 
==18244== LEAK SUMMARY:
==18244==    definitely lost: 12 bytes in 1 blocks
==18244==    indirectly lost: 0 bytes in 0 blocks
==18244==      possibly lost: 0 bytes in 0 blocks
==18244==    still reachable: 347,345 bytes in 2,878 blocks
==18244==         suppressed: 0 bytes in 0 blocks
==18244== Rerun with --leak-check=full to see details of leaked memory
==18244== 
==18244== For counts of detected and suppressed errors, rerun with: -v
==18244== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)


== ASAN / -O0 ==

dualbus@debian:~/src/gnu/bash-build$ CFLAGS='-O0 -fsanitize=address -fno-omit-frame-pointer' LDFLAGS=-lasan ../bash/configure --without-bash-malloc && make -j4
[...]
rm -f bash
gcc -L./builtins -L./lib/readline -L./lib/readline -L./lib/glob -L./lib/tilde  -L./lib/sh  -lasan -rdynamic -O0 -fsanitize=address -fno-omit-frame-pointer -Wno-parentheses -Wno-format-security   -o bash shell.o eval.o y.tab.o general.o make_cmd.o print_cmd.o  dispose_cmd.o execute_cmd.o variables.o copy_cmd.o error.o expr.o flags.o jobs.o subst.o hashcmd.o hashlib.o mailcheck.o trap.o input.o unwind_prot.o pathexp.o sig.o test.o version.o alias.o array.o arrayfunc.o assoc.o braces.o bracecomp.o bashhist.o bashline.o  list.o stringlib.o locale.o findcmd.o redir.o pcomplete.o pcomplib.o syntax.o xmalloc.o  -lbuiltins -lglob -lsh -lreadline -lhistory -ltermcap -ltilde     -ldl 
./lib/sh/libsh.a(tmpfile.o): In function `sh_mktmpname':
tmpfile.c:(.text+0x3e4): warning: the use of `mktemp' is dangerous, better use `mkstemp' or `mkdtemp'
ls -l bash
-rwxr-x--- 1 dualbus dualbus 3433608 Jun  8 09:56 bash
size bash
   text    data     bss     dec     hex filename
2933580  297264   83904 3314748  32943c bash

dualbus@debian:~/src/gnu/bash-build$ ./bash
bash-4.4$ echo hi
hi
bash-4.4$ exit


== Valgrind / -O0 ==

dualbus@debian:~/src/gnu/bash-build$ CFLAGS='-O0 -fno-omit-frame-pointer' LDFLAGS= ../bash/configure --without-bash-malloc && make -j4 
[...]
rm -f bash
gcc -L./builtins -L./lib/readline -L./lib/readline -L./lib/glob -L./lib/tilde  -L./lib/sh  -rdynamic -O0 -fno-omit-frame-pointer -Wno-parentheses -Wno-format-security   -o bash shell.o eval.o y.tab.o general.o make_cmd.o print_cmd.o  dispose_cmd.o execute_cmd.o variables.o copy_cmd.o error.o expr.o flags.o jobs.o subst.o hashcmd.o hashlib.o mailcheck.o trap.o input.o unwind_prot.o pathexp.o sig.o test.o version.o alias.o array.o arrayfunc.o assoc.o braces.o bracecomp.o bashhist.o bashline.o  list.o stringlib.o locale.o findcmd.o redir.o pcomplete.o pcomplib.o syntax.o xmalloc.o  -lbuiltins -lglob -lsh -lreadline -lhistory -ltermcap -ltilde     -ldl 
./lib/sh/libsh.a(tmpfile.o): In function `sh_mktmpname':
tmpfile.c:(.text+0x25e): warning: the use of `mktemp' is dangerous, better use `mkstemp' or `mkdtemp'
ls -l bash
-rwxr-x--- 1 dualbus dualbus 1511808 Jun  8 10:00 bash
size bash
   text    data     bss     dec     hex filename
1286664   48380   41072 1376116  14ff74 bash

dualbus@debian:~/src/gnu/bash-build$ valgrind ./bash
==333== Memcheck, a memory error detector
==333== Copyright (C) 2002-2015, and GNU GPL'd, by Julian Seward et al.
==333== Using Valgrind-3.12.0.SVN and LibVEX; rerun with -h for copyright info
==333== Command: ./bash
==333== 
bash-4.4$ echo hi
hi
bash-4.4$ exit
exit
==333== 
==333== HEAP SUMMARY:
==333==     in use at exit: 347,442 bytes in 2,885 blocks
==333==   total heap usage: 4,412 allocs, 1,527 frees, 607,323 bytes allocated
==333== 
==333== LEAK SUMMARY:
==333==    definitely lost: 0 bytes in 0 blocks
==333==    indirectly lost: 0 bytes in 0 blocks
==333==      possibly lost: 0 bytes in 0 blocks
==333==    still reachable: 347,442 bytes in 2,885 blocks
==333==         suppressed: 0 bytes in 0 blocks
==333== Rerun with --leak-check=full to see details of leaked memory
==333== 
==333== For counts of detected and suppressed errors, rerun with: -v
==333== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)


-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 08 11:09:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIz49-0005Gg-CM
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 11:09:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46176)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIz47-0005FF-Lg
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:09:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dIz44-0004cf-Ao
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:09:39 -0400
Received: from mail-ot0-x22f.google.com ([2607:f8b0:4003:c0f::22f]:35598)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dIz44-0004c3-5I
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:09:36 -0400
Received: by mail-ot0-x22f.google.com with SMTP id a2so24827537oth.2
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 08:09:36 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=pNnBfsTuvY19ES1dbTHw7RidvCwdx2fELrGHTQh4Urs=;
	b=NMl5RCQDaVwvLr0S3vT5ztcIPUUG/PQJFO6scHKRQxPwxL82SKMORn+mr/hevnuOTt
	L1R6wt4k9HjrH9A80mJ/Arij3gZRJqFuHXGK7rRYJgLVarPe5Kk7Irt1RbDfKwSo2N+P
	n5J28ZyWZ6QJWMr8rgc1FZxCf0e30xiF/PPReFRTLXIi56rCRZb+oUQgStTzWMjZz+TZ
	d5VKhjYSPh3RZmHqd7HNZKUVlmGx4xxyrS471Tg6BF/TY0b55x3tQx200WL7LWlhAKzW
	vcYK8/im/1iDNGyToeMwbzMW7pHi+VCOcieDJ4NecZ56peo9KscxlM+wTo/cphKfUDLl
	vjPQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=pNnBfsTuvY19ES1dbTHw7RidvCwdx2fELrGHTQh4Urs=;
	b=tcaIvkInJKMVyTkOUQSncHwpUafzha5wQ+MOm+LePUg0t+vRSFujTK71JJUj1FXJdB
	A6HCeLIMonztlwORcTlhN5dwm5mhMht5M1Lp1Rwi8mFckNtpVT1Y+1Pt0cc7ebXe6C+z
	tHeIlC5Zwc6zJRAPE6XbXxt+LccA4zL0cmNWJ/oBk7thY+1TA2dJX1eaBG33VxlJ28+l
	EyQA/wz519FDD5WEro6O6kNr7bPEjg/cW8TsQrMdt6I5a9Z801JV+nLC6OzDnBK8v+tl
	YbnzfbRvuwgal/JI2ArMjfzMLhiGKd271aRwlsnQIFaJKY32s6WjeSEJEpY+mIKIsBXo
	ay1w==
X-Gm-Message-State: AODbwcAvIDEzbOBCxdGEraWJGgT91Mjeq3tgDtW1fh3MD9Lixc1npOKy
	4iZglYN95iVWp1Ig
X-Received: by 10.157.42.167 with SMTP id e36mr18810466otb.26.1496934575246;
	Thu, 08 Jun 2017 08:09:35 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	q35sm2729033ota.20.2017.06.08.08.09.34 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 08 Jun 2017 08:09:34 -0700 (PDT)
Date: Thu, 8 Jun 2017 10:09:33 -0500
From: dualbus <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: Remaining memory corruption bugs in readline
Message-ID: <20170608150933.tqkeflh46jxnsrt2@debian>
References: <20170602050734.a2jjlilt32mbk5t2@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170602050734.a2jjlilt32mbk5t2@debian>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 15:09:40 -0000

On Fri, Jun 02, 2017 at 12:07:34AM -0500, dualbus wrote:
[...]
> #1 _rl_get_char_len / update_line
[...]
>   ==5781==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f400d00b063 bp 0x7ffcbce72250 sp 0x7ffcbce71a00
>   READ of size 851 at 0x61900000cc80 thread T0
>       #0 0x7f400d00b062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
>       #1 0x559b50a04821 in _rl_get_char_len ../../../bash/lib/readline/mbutil.c:223
>       #2 0x559b50a048e0 in _rl_compare_chars ../../../bash/lib/readline/mbutil.c:252
>       #3 0x559b509db526 in update_line ../../../bash/lib/readline/display.c:1664
[...]

I have been looking at this specific example for some time now.

The problem is that _rl_get_char_len assumes it's being called with a
\0-terminated string, but under some cases (that I haven't been able to
figure out), there's no \0 at the end, so the strlen reads more than it
should.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 08 11:35:03 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dIzSh-0008Ni-8L
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 11:35:03 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55035)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIzSe-0008N8-Is
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:35:01 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dIzSa-0004S8-Hm
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:35:00 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:20545
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dIzSa-0004Rt-Bh
	for bug-bash@gnu.org; Thu, 08 Jun 2017 11:34:56 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMB40377; Thu, 08 Jun 2017 11:34:54 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFR43414 (AUTH cpr);
	Thu, 08 Jun 2017 11:34:54 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Remaining memory corruption bugs in readline
To: dualbus <dualbus@gmail.com>, bug-bash@gnu.org
References: <20170602050734.a2jjlilt32mbk5t2@debian>
	<20170608150933.tqkeflh46jxnsrt2@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <6e78feee-edfe-4596-7384-62f2e53c630a@case.edu>
Date: Thu, 8 Jun 2017 11:34:53 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608150933.tqkeflh46jxnsrt2@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.8.141815:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1200_1299,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 15:35:01 -0000

On 6/8/17 11:09 AM, dualbus wrote:
> On Fri, Jun 02, 2017 at 12:07:34AM -0500, dualbus wrote:
> [...]
>> #1 _rl_get_char_len / update_line
> [...]
>>   ==5781==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f400d00b063 bp 0x7ffcbce72250 sp 0x7ffcbce71a00
>>   READ of size 851 at 0x61900000cc80 thread T0
>>       #0 0x7f400d00b062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
>>       #1 0x559b50a04821 in _rl_get_char_len ../../../bash/lib/readline/mbutil.c:223
>>       #2 0x559b50a048e0 in _rl_compare_chars ../../../bash/lib/readline/mbutil.c:252
>>       #3 0x559b509db526 in update_line ../../../bash/lib/readline/display.c:1664
> [...]
> 
> I have been looking at this specific example for some time now.
> 
> The problem is that _rl_get_char_len assumes it's being called with a
> \0-terminated string, but under some cases (that I haven't been able to
> figure out), there's no \0 at the end, so the strlen reads more than it
> should.

I've been traveling and have not looked at this.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 08 13:38:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ1OB-00023N-Rl
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 13:38:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56959)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ1O9-00021v-3d
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:38:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ1O6-0003d3-Df
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:38:29 -0400
Received: from mail-pf0-x22c.google.com ([2607:f8b0:400e:c00::22c]:36734)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJ1O6-0003cs-7I
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:38:26 -0400
Received: by mail-pf0-x22c.google.com with SMTP id x63so19473452pff.3
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 10:38:26 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:to:subject:message-id:date:user-agent:mime-version
	:content-language:content-transfer-encoding;
	bh=aTEr+0FoLp1Y2mG3cXXhexu4lWEjWcqQwUg3iG6nqK8=;
	b=DFg0ZqJBk2AUwOaDh0OWzEGWRYH1VNgagHAIJdORRCf0lH0eTcdR8Ejo7KfdX1shtD
	QpDdbQIy+DTJpFpTBMh20g0PzqTeo2MzarUsHw4UyzIVSt9px/j2Ecqd9SErx/e3hrNS
	BZFB0YLe7/WIiE4cRv037g3IprnkHFYm+K3ZR8KY2w/JaHyyLVQ3zP71yCyQYCNpnzf8
	WPM9fuYDsJUwwOvKGZv/8OeY18Z65pwqnqLQKqXhE0R+CDevG1r71Bz3k8I1fvPRhNmT
	pw+3d2ir8K8w1oB1rzI7g4xSj7iTQn72BXP2R1uKZ3Xxl1x4l0CO5Y+Ho9DTbPx2WV4b
	TmTg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:to:subject:message-id:date
	:user-agent:mime-version:content-language:content-transfer-encoding;
	bh=aTEr+0FoLp1Y2mG3cXXhexu4lWEjWcqQwUg3iG6nqK8=;
	b=dNi50VBjLNS7yKQ38FE3yxWASWj3D7luDW/pqoK/6ntpvNr5ncN3YWIuiG+wQkEYp5
	Jn71nzC3kdCd/RXc0M6P7cfwrwp8jYSSC8HxhUi6Jy3FqqcuHSMkqwcKFJmzrokvRUjZ
	4vZRBXmpthBN+dIrAHQDIj7FPvwoaJ4IFWSOX5d/qR1ZcTMSO7+coprHvLS9c5mpt6JX
	D+YAxHs+rOlaqEQy/bFMeSthtBHXMK1Fd4JjWnO9+xmZdNtFui/8707jGJgyTcocQQ28
	rEqNXANNJudCjk192aC7WS0t+84vrKwkKrTePaMjCxIgJr7inTVmRlKeh34BWanZVX5B
	vBCQ==
X-Gm-Message-State: AODbwcAlmtjvmqE1StEH5LS/7hz/rLqKxHMnqlqZtK/xcbKuH1+vFU17
	GxpT3zmwB9+eWRhx
X-Received: by 10.98.153.153 with SMTP id t25mr38436490pfk.160.1496943505135; 
	Thu, 08 Jun 2017 10:38:25 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	l131sm5095498pga.65.2017.06.08.10.38.21 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 10:38:22 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Trailing newlines disappear
Message-ID: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
Date: Fri, 9 Jun 2017 00:38:19 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22c
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 17:38:30 -0000

I would think this is a bug:

4.3.48(1)-release> printf "q\n\n\n" >w
4.3.48(1)-release> cat w
q


4.3.48(1)-release> printf "$(cat w)"
q
4.3.48(1)-release>

Is there some workaround to somehow preserve the trailing newlines?

Peter


From MAILER-DAEMON Thu Jun 08 13:42:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ1SK-0003NI-HO
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 13:42:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57720)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ1SH-0003KY-Kn
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:42:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ1SD-0004v5-CT
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:42:45 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33103 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ1SD-0004v1-43
	for bug-bash@gnu.org; Thu, 08 Jun 2017 13:42:41 -0400
Received: (qmail 22160 invoked from network); 8 Jun 2017 17:42:39 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 08 Jun 2017 13:42:39 -0400
Received: (qmail 11368 invoked by uid 563); 8 Jun 2017 17:42:39 -0000
Date: Thu, 8 Jun 2017 13:42:39 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: PePa <peterkelly@passchier.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170608174238.GH3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 17:42:46 -0000

On Fri, Jun 09, 2017 at 12:38:19AM +0700, PePa wrote:
> I would think this is a bug:

> 4.3.48(1)-release> printf "q\n\n\n" >w
> 4.3.48(1)-release> printf "$(cat w)"
> q
> 4.3.48(1)-release>
> 
> Is there some workaround to somehow preserve the trailing newlines?

It's not a bug.  This is how command substitution has worked since
the original Bourne shell.

The workaround is to put something inside the command substitution,
so that the newlines aren't trailing any more, and then strip it away
afterward:

foo=$(cat "$file"; printf x) foo=${foo%x}

This also means that you can't use the $(< "$file") shortcut any more,
if you need to preserve the full contents of a file.


From MAILER-DAEMON Thu Jun 08 14:52:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ2YD-0007si-3V
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 14:52:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48197)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ2YB-0007r8-CV
	for bug-bash@gnu.org; Thu, 08 Jun 2017 14:52:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ2Y7-0002aU-Ug
	for bug-bash@gnu.org; Thu, 08 Jun 2017 14:52:55 -0400
Received: from mail-pg0-x235.google.com ([2607:f8b0:400e:c05::235]:34955)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJ2Y7-0002Zl-Oe
	for bug-bash@gnu.org; Thu, 08 Jun 2017 14:52:51 -0400
Received: by mail-pg0-x235.google.com with SMTP id k71so18812695pgd.2
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 11:52:51 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=aZ+/fMjpQQvWXTYCafNkxOCgoOC7hBayTKTOOTKatC0=;
	b=OLG+kexOhT7FiHf11xZyfKQzAYBJ0XgKUWFVxhXF7phZ/XPmnm/oViiI0Q0fT9dlzt
	sOGgv+wDMVZblb6UERcpni7FBBVrj2xp0UejkgmY8UdeSsvkkiWq2lKaQDtYuoxFsuuz
	DKdfMUzI0QHSMsaBCnSzLlrOw3u5BHnnNpSfFOQnqKqe/RbI/w65vom9juFr11GghSTo
	qvCYYJw6s3qzGfb1f4JOGMIaDS7ggpI+NLVZWYuEablhG4WptxTAErPHfCMhQ/VO8sBV
	SXUMv2JuAHFele6pdB+qtAcpymGxIcqoYAiFT9f2cyGgBrIghn19meVJ4k+JQWd8xpYN
	WT9g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=aZ+/fMjpQQvWXTYCafNkxOCgoOC7hBayTKTOOTKatC0=;
	b=Wh2Pjk4x3PYIjhN5iNWKg0FfLh7cXW4YHIVIUtKtjvVrnh1ee2K0h7HIKME9mDA1Fn
	kdWya8t/+oMbw18O4twzLSaI1whScnbzWQlGSLnzoZOHtH0E2wJqCJRJKUdRIHCq+Cdz
	jqSyUNzmcsK7oY2f2AJYqmHhz0AA3DOEDOgjtv8ZTXADcg67yVjnFxbBsfcKYw5e1634
	UC4JgN779AcRh9LC5UIDx9c3e8IuvVbCob1365O22fevVAGUUdK/xwNU0YQBeJ+v0o7L
	XmcQT7K6jxBqOiRMOMt7l4tsLU0Uds0x+yoAQL9yyQmvRWSgRd6EYqhMxQjBg+6Xh+sZ
	SNeQ==
X-Gm-Message-State: AODbwcBH5MAz+/7YX5eKLJpZLXkvNAsKUVanLzCyJ2FkKP0ZJWRrROsi
	p8mMGAmvEqM6yiw5
X-Received: by 10.99.186.91 with SMTP id l27mr35094573pgu.87.1496947970587;
	Thu, 08 Jun 2017 11:52:50 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	k11sm11622940pfj.48.2017.06.08.11.52.46 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 11:52:47 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Trailing newlines disappear
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
Date: Fri, 9 Jun 2017 01:52:44 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608174238.GH3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 18:52:56 -0000

On 09/06/2560 00:42, Greg Wooledge wrote:
> It's not a bug.  This is how command substitution has worked since
> the original Bourne shell.
> 
> The workaround is to put something inside the command substitution,
> so that the newlines aren't trailing any more, and then strip it away
> afterward:
> 
> foo=$(cat "$file"; printf x) foo=${foo%x}

Thanks for the reply.
Seeing the hackish workaround, I would call it an ossified (or codified)
flaw...

The workaround I came up with is:
mapfile <"$file"; IFS= foo=${MAPFILE[@]}

This seems to be faster, but it probably has other disadvantages...

Peter


From MAILER-DAEMON Thu Jun 08 15:14:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ2tM-0003LA-IB
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 15:14:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54506)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ2tL-0003L3-Bb
	for bug-bash@gnu.org; Thu, 08 Jun 2017 15:14:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ2tG-0006YW-FH
	for bug-bash@gnu.org; Thu, 08 Jun 2017 15:14:47 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33112 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ2tG-0006YD-7B
	for bug-bash@gnu.org; Thu, 08 Jun 2017 15:14:42 -0400
Received: (qmail 22612 invoked from network); 8 Jun 2017 19:14:40 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 08 Jun 2017 15:14:40 -0400
Received: (qmail 11552 invoked by uid 563); 8 Jun 2017 19:14:40 -0000
Date: Thu, 8 Jun 2017 15:14:40 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170608191440.GI3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 19:14:48 -0000

On Fri, Jun 09, 2017 at 01:52:44AM +0700, Peter & Kelly Passchier wrote:
> On 09/06/2560 00:42, Greg Wooledge wrote:
> > foo=$(cat "$file"; printf x) foo=${foo%x}
> 
> The workaround I came up with is:
> mapfile <"$file"; IFS= foo=${MAPFILE[@]}
> 
> This seems to be faster, but it probably has other disadvantages...

Well, it leaves IFS changed, because you didn't revert or unset it,
or run the entire thing in a function with local IFS.  Also, I'd use
"${MAPFILE[*]}" to reinforce that you are joining an array into a string,
rather than expanding the array as a list.  Semantically, x=$@ is pretty
"huh??" to me.

It also leaves the array in memory, and requires bash 4.  Those may not
be significant.


From MAILER-DAEMON Thu Jun 08 16:30:56 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ452-0001IV-In
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 16:30:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45476)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ451-0001IP-0T
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:30:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ44x-0005Ql-PB
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:30:54 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33122 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ44x-0005QS-Gq
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:30:51 -0400
Received: (qmail 22936 invoked from network); 8 Jun 2017 20:30:49 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 08 Jun 2017 16:30:49 -0400
Received: (qmail 11634 invoked by uid 563); 8 Jun 2017 20:30:49 -0000
Date: Thu, 8 Jun 2017 16:30:49 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: PePa <peterkelly@passchier.net>
Cc: bug-bash@gnu.org
Subject: Re: Trailing newlines disappear
Message-ID: <20170608203049.GJ3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<0147f972-c968-6754-45f9-c2abf33f2639@passchier.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <0147f972-c968-6754-45f9-c2abf33f2639@passchier.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 20:30:56 -0000

ARGH!  You dropped the list address!  This was on bug-bash, right??

On Fri, Jun 09, 2017 at 03:14:10AM +0700, PePa wrote:
> On 09/06/2560 02:14, Greg Wooledge wrote:
> > Well, it leaves IFS changed, because you didn't revert or unset it,
> > or run the entire thing in a function with local IFS.  Also, I'd use
> > "${MAPFILE[*]}" to reinforce that you are joining an array into a string,
> > rather than expanding the array as a list.
> 
> Thanks for pointing all this out. I settled on:
> mapfile <"$file"; IFS= foo=${MAPFILE[*]} true
> 
> Again, much faster than a subshell. Are there order guarantees in the
> case of "a=x b=y command"??
> 
> Peter

You have a massive error here.  Your variables exist only for the
duration of that "true" command.

imadev:~$ unset x y
imadev:~$ x=1 y=3 true
imadev:~$ declare -p x y
bash: declare: x: not found
bash: declare: y: not found

In the case of "x=1 y=2", yes, there is a guarantee of processing order.
You may safely write things like:

tmp=${x##*[} tmp=${tmp%%]*} tmp=${tmp//x/y}

And they will be done from left to right.  But in your example, the
question is moot, because your variables don't survive at all.


From MAILER-DAEMON Thu Jun 08 16:34:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ48q-0002Ix-JD
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 16:34:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46329)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ48n-0002HO-NA
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:34:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ48k-0007JO-At
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:34:49 -0400
Received: from mail-pf0-x236.google.com ([2607:f8b0:400e:c00::236]:33834)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJ48k-0007J7-4v
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:34:46 -0400
Received: by mail-pf0-x236.google.com with SMTP id 9so20906126pfj.1
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 13:34:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=dsg0FZPh6u94Iaa6v1kM9l/SOC3droxzOmLEqrjoePA=;
	b=AUN2ajEQ2tAm8j0WkUNXRwTi77rlLcaknIu7T9MD9ir386n1X6b3SCWSinugmG/9SC
	J2nBAckmQxDu9V/RpwlkFCB6CYS54a+ZOrl+SVW/VbCKdt5hS9NJ947k51qaloK5S67I
	dO4r28uM8BNYsG95vWOnwlvnfbV7w1gZmc3zUQXpd+TWv5nT3D5ivzNJ9HCgAecHeDsO
	vviZ3RmEq5dn1w6AX8FjSEaMU/WNdGoHXVUxxuAWh6yRR2jBFU+08sXvM1GJcoQew16l
	tlKcCS/Yth4ZsjxerrLPEB51hkZtN5ExL0CLrKxQ8XPjBwnvzPYAr/3nxBIZAlX6pUkQ
	oLjA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=dsg0FZPh6u94Iaa6v1kM9l/SOC3droxzOmLEqrjoePA=;
	b=ZsyJsrxHv9b5zHIl0Nu60BP+G2mYzzyPPtBOQ+2Vn2zYOpPbLl2aokA3hxyLuplpcB
	0Ir+m08XWFe06Q/oNfh7CjGKm2KDptf16JjIsFYrJ59bkCTvq5mfr1Jo2F79emh4NTuu
	/uGw3svpWBYOz/enV7H09fIs6TqNDnGwuA3/nNf0YpUZjRIl0nh6wNG7sYzfqB3NDslS
	m71HGhb4R8qbK85Ke82OrM7b5bSiKfCZr4p9P+WxBymiqVMQ7iAVdbtUibaJUIphFtC4
	NQOxtJ9KCrkIjD6WXCdCaQxSylEu+rd08TEASlenE8y4BAsS+xbaWineGbE15QEpEgDK
	XbvQ==
X-Gm-Message-State: AODbwcDRljoLe7O4RNi3UNpfrSmJrvym7GPCXf1vLB7/3MRy2l+1orwi
	pBP37m1oXhZiksLY
X-Received: by 10.98.53.133 with SMTP id c127mr38920964pfa.4.1496954084877;
	Thu, 08 Jun 2017 13:34:44 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	c205sm14754943pfb.74.2017.06.08.13.34.42 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 13:34:43 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: Trailing newlines disappear
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
Message-ID: <1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
Date: Fri, 9 Jun 2017 03:34:39 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608191440.GI3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 20:34:50 -0000

On 09/06/2560 02:14, Greg Wooledge wrote:
> Well, it leaves IFS changed, because you didn't revert or unset it,
> or run the entire thing in a function with local IFS.  Also, I'd use
> "${MAPFILE[*]}" to reinforce that you are joining an array into a string,
> rather than expanding the array as a list.

Thanks for pointing all this out. I settled on:
mapfile <"$file"; IFS= foo=${MAPFILE[*]} true

Again, much faster than a subshell. Are there order guarantees in the
case of "a=x b=y command"??

Peter


From MAILER-DAEMON Thu Jun 08 16:44:43 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ4IN-00064x-8R
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 16:44:43 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48214)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <geir.hauge@gmail.com>) id 1dJ4IL-00064m-Pr
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:44:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <geir.hauge@gmail.com>) id 1dJ4IE-0002Oq-B0
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:44:37 -0400
Received: from mail-lf0-x22d.google.com ([2a00:1450:4010:c07::22d]:35605)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <geir.hauge@gmail.com>)
	id 1dJ4ID-0002Ng-Vm
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:44:34 -0400
Received: by mail-lf0-x22d.google.com with SMTP id p189so22580546lfe.2
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 13:44:32 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=NpogaqfsERwwWCFIkm3SmVSEdj0UioSM2p8+HKBpFC4=;
	b=sMHyBzt8C9p0ztuBDUo+molrkslhIwVnGUmNeQ/zM8xWKQB+QdQ+R0iKIL7RjWQVzc
	IDqx4ysZf4/FZuf/s2oZKR1VQsWfCrm7IxsdQAjuV4A9zFzksP3iYuwBD4w5Ts+lexwO
	21JAo00Ezik0fTinZuYXacZVEDGqpIS3ffodHL/auqy+u3qvrq4am+cB0Y4smjJi5ddX
	kT3wA+0HX0e5ZqDvSFnzYXo7CsM0yNwK9DgoP79+BODK6MLf8sb+erkfu5FRnlaJZmRe
	5U/Hgme2hXwIXdyw0TclEr7fDOil+eSlCCRtz0TDWWGTjyw3H/Bl11bH/EKbXsxetQdB
	bppw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=NpogaqfsERwwWCFIkm3SmVSEdj0UioSM2p8+HKBpFC4=;
	b=VeTIXsB/qij2z+ylyYmDdP6DuUstxurY6KjBne3FGSTnAvQCVpy+uJPbT2bRpIYOiS
	pGFnTb4iyKlXB9cV/zBlv6F9HsZ/X+IHAaMvYH5EAUotjkXLArJTsxN+2uzvWyvw9xio
	47FjRFa6a3KL79d6Jmf+TH/3ZcT77dOkTBjBbuzE3wQhGBtSWVklH8qCAFGB1GWAn/4c
	5DehgtXV1z2C5yfAjZ6Ol5n/T0slvZNcOYBw2NSbVelFd8fgN1VM889xr6rfD/FAoCt0
	3tsCydYoxaqlLE9nq4rLlrcLRdNCr2/gbEbR6Nh08yT95VgB5BcGLgm+CN/1S3UCGJYA
	F2rQ==
X-Gm-Message-State: AODbwcBLkaDqlgC6f880joAu9J2k2rO2v0xNMycJsrl9EF5jYjgrDljy
	XDOEANhB6JlS0ZDRyuA=
X-Received: by 10.25.25.139 with SMTP id 133mr11599242lfz.33.1496954671227;
	Thu, 08 Jun 2017 13:44:31 -0700 (PDT)
Received: from MacGeir (225.224.9.46.customer.cdi.no. [46.9.224.225])
	by smtp.gmail.com with ESMTPSA id t5sm1274841ljd.39.2017.06.08.13.44.30
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 13:44:30 -0700 (PDT)
Date: Thu, 8 Jun 2017 22:44:29 +0200
From: Geir Hauge <geir.hauge@gmail.com>
To: PePa <peterkelly@passchier.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170608204429.p3dwazxuqqlp3yeb@MacGeir>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
User-Agent: NeoMutt/20161126 (1.7.1)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:4010:c07::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 20:44:42 -0000

On Fri, Jun 09, 2017 at 03:34:39AM +0700, PePa wrote:
> On 09/06/2560 02:14, Greg Wooledge wrote:
> > Well, it leaves IFS changed, because you didn't revert or unset it,
> > or run the entire thing in a function with local IFS.  Also, I'd use
> > "${MAPFILE[*]}" to reinforce that you are joining an array into a string,
> > rather than expanding the array as a list.
> 
> Thanks for pointing all this out. I settled on:
> mapfile <"$file"; IFS= foo=${MAPFILE[*]} true

Greg already pointed out that this doesn't work.

You can pick one of these instead:

    mapfile < "$file"; IFS= foo="${MAPFILE[*]}"; unset -v IFS

or

    mapfile < "$file"; printf -v foo %s "${MAPFILE[@]}"

-- 
Geir Hauge


From MAILER-DAEMON Thu Jun 08 16:54:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ4Rd-0000Na-Q0
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 16:54:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50269)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ4Rb-0000NU-Lp
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:54:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ4RY-0006gT-K2
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:54:15 -0400
Received: from mail-pg0-x236.google.com ([2607:f8b0:400e:c05::236]:34326)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJ4RY-0006fn-Eh
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:54:12 -0400
Received: by mail-pg0-x236.google.com with SMTP id v18so19672881pgb.1
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 13:54:12 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=O3H+F04/ka2lVuXIKXrKRWonTx86Q55h0X6psbveyio=;
	b=Cc5HWH+ygzeALEpilLPvv2yV4mhPEChhQQoXhcrbaaoWffsnBn4dAYW0wjX5rXcB/6
	5Y+Nh9lRnJIP+P2d1dryKP6vmcaZGKYo57iNesiY5uFJ5mcRh2gqJ4TFhIHANnfl9rPK
	IXa8VpB685D7yIZhAQvbbxROHZgcAiLPbFaokP5Cw7/svbhag6U5CLps9MdK47XbZP59
	BC3fMjT31abWY8JqEXnP3mPlVX5+bdty6HuHZJxJ5nl9Hr27jkEeKJL1k7ZS+CpBh5eh
	Lges11kvvVLYyOh5Kzqz7rFES/idk0fY6WCVDA3qLiJkLL2xwd51BkGAicuR5aNPNAyi
	51BQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=O3H+F04/ka2lVuXIKXrKRWonTx86Q55h0X6psbveyio=;
	b=jPnMzs8R1OQ2xEn8ZwlfEbhw1lmXIQhkUOjL9WBSD7+Cq0BiXZkChKVL8xOxb4t2Pk
	Y7P/oNENdy9eW8aByDwqSa8NEtb5fuG81HyFXjljGrT6fu1cW/KxJwK8O/TSJ/mIh002
	3gXk9qRTNsy00OMKDxI3BDPumhesu1k5w0dOFLXhHUlq+cRqc3+XXSRRs+Hrg9x2HU0+
	PtpH93ca5/68rV8Pgd193Ci/ewPRJi8c5GjQf4acvpIzXQGC5SAHC2PvhlMcDjLuqBUY
	CiEQaCL0UDlyOLDVV+cHviEpjkFfgsEKXQXQ5Pd5xaoPLn9f0ps28ybQ4t3ivzpHx1nb
	7P6g==
X-Gm-Message-State: AODbwcBRw57/AaxCo7o3Ex8rfBpChfqQRY0I8WD/BzVsdf+jXnyBu/hl
	jlFV0+tyyTWJuE6B
X-Received: by 10.84.132.2 with SMTP id 2mr36163486ple.46.1496955251237;
	Thu, 08 Jun 2017 13:54:11 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	18sm11202221pfo.92.2017.06.08.13.54.09 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 13:54:10 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Trailing newlines disappear
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <8ea95806-e2ea-b866-bd7b-baac4dde892d@passchier.net>
Date: Fri, 9 Jun 2017 03:54:08 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170608204429.p3dwazxuqqlp3yeb@MacGeir>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 20:54:16 -0000

On 09/06/2560 03:44, Geir Hauge wrote:
> Greg already pointed out that this doesn't work.
> 
> You can pick one of these instead:
> 
>     mapfile < "$file"; IFS= foo="${MAPFILE[*]}"; unset -v IFS
> 
> or
> 
>     mapfile < "$file"; printf -v foo %s "${MAPFILE[@]}"
> 
Yes, thanks.
The second one looked interesting, but didn't work. I now have:

mapfile <"$file"; IFS= foo="${MAPFILE[*]}"

(without the unset, as it's in a function where it's harmless)


From MAILER-DAEMON Thu Jun 08 16:56:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ4U1-0000kU-Rc
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 16:56:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50678)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ4U0-0000kH-0D
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:56:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ4Tv-0007bN-5y
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:56:44 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33130 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJ4Tu-0007bB-Ud
	for bug-bash@gnu.org; Thu, 08 Jun 2017 16:56:39 -0400
Received: (qmail 23136 invoked from network); 8 Jun 2017 20:56:37 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 08 Jun 2017 16:56:37 -0400
Received: (qmail 11707 invoked by uid 563); 8 Jun 2017 20:56:37 -0000
Date: Thu, 8 Jun 2017 16:56:37 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170608205637.GK3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <20170608204429.p3dwazxuqqlp3yeb@MacGeir>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 20:56:44 -0000

On Thu, Jun 08, 2017 at 10:44:29PM +0200, Geir Hauge wrote:
> You can pick one of these instead:
> 
>     mapfile < "$file"; IFS= foo="${MAPFILE[*]}"; unset -v IFS
> 
> or
> 
>     mapfile < "$file"; printf -v foo %s "${MAPFILE[@]}"

or

    lambda() { local MAPFILE IFS=; mapfile < "$file"; foo="${MAPFILE[*]}"; }
    lambda


From MAILER-DAEMON Thu Jun 08 18:26:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ5sl-0006UF-Qn
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 18:26:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41228)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJ5sk-0006U7-Ay
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:26:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJ5sj-0007p7-Ez
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:26:22 -0400
Received: from mail-qt0-x232.google.com ([2607:f8b0:400d:c0d::232]:35437)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dJ5sj-0007or-8u
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:26:21 -0400
Received: by mail-qt0-x232.google.com with SMTP id w1so57952905qtg.2
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 15:26:21 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=XlyLlt7d0wIMn9H6xspnk1Grk05jZkFd+uA4Brfp9dA=;
	b=ZmfAaQv5xSwSe4pu1+n0ykofKXimz7H833Ji9E1rDfVGnS8lEP0bSCbqR3jXH+dv1F
	LILiT2ShlH+TsXfY4msRQMhxozetFHT+BLMXi7MJuEfIqfuEJV71pQeKtgiCbYVf2fWE
	0BUf3SLYQ8MiaLy548ARfAXka5NFo/P9rth3IGHHLGuo1rG83AkytJieIMEre7MMyIDF
	1t0WFpXNYZYcawnE9UxMpaEK9Y3DJcfJ3qNUTnc3eUdgDLxA+C8NfJhkooHM3ilJmY3b
	Sdmk8F5EO3uEzXGw64cU6iOunfz+Q1qhJkt0LVrYdeVMEryZTp+hvywLiR3ILOBf9z52
	BhpQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=XlyLlt7d0wIMn9H6xspnk1Grk05jZkFd+uA4Brfp9dA=;
	b=uMQy7ueiFMhNH1pJQ0IsTIXmGs17KA/SOfI5/ZcuD52vd7OLOuu7vQGWDeb+cND9Fc
	vdu+jKNBOCv26ZjD4s4IcfmqJ/Z7U+QZUpfA/zA6WyR4EqghWVunfhYnS0hvNQg5AUoC
	ppI/ec8BH+1GTuT9b+ru1Eu2IgVWgeHltUL3QAT2UaepgU6kiRJXKLFdUV0f3j22JD0u
	JMveIbh7nyD7jcvFJlaV3qEAu/bHjlNd9zg1dW6jXPF4lUKinkJ4Cec7IuVueoKdNaZJ
	FH4yvnH2DU8Bt8lj9VqCfHJC7W3yAq4rtAqHoWb4XEIh/QEnvdmETEaCDJb7rK/6Qlm3
	xI7w==
X-Gm-Message-State: AODbwcDuZztsR2ZxenTBTBqBcz/fvS1qKCM8EXhElrN6bR7beV3lEmKh
	5KjUxeb5zI3E0Ied8fR2T3zf5X96mfOp
X-Received: by 10.237.50.71 with SMTP id y65mr30739040qtd.117.1496960780617;
	Thu, 08 Jun 2017 15:26:20 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.178.25 with HTTP; Thu, 8 Jun 2017 15:26:00 -0700 (PDT)
In-Reply-To: <20170608205637.GK3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Thu, 8 Jun 2017 17:26:00 -0500
Message-ID: <CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
Subject: Re: Trailing newlines disappear
To: Greg Wooledge <wooledg@eeg.ccf.org>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 22:26:23 -0000

On Thu, Jun 8, 2017 at 3:56 PM, Greg Wooledge <wooledg@eeg.ccf.org> wrote:
> On Thu, Jun 08, 2017 at 10:44:29PM +0200, Geir Hauge wrote:
>> You can pick one of these instead:
>>
>>     mapfile < "$file"; IFS= foo="${MAPFILE[*]}"; unset -v IFS
>>
>> or
>>
>>     mapfile < "$file"; printf -v foo %s "${MAPFILE[@]}"
>
> or
>
>     lambda() { local MAPFILE IFS=; mapfile < "$file"; foo="${MAPFILE[*]}"; }
>     lambda
>

What's wrong with:

IFS= read -rd '' foo < "$file"


From MAILER-DAEMON Thu Jun 08 18:37:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ63n-00025J-6F
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 18:37:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43482)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJ63k-000256-Qg
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:37:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJ63g-0003Fh-RS
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:37:44 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:40902
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJ63g-0003EG-GR
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:37:40 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v58MbXQl017410 for <bug-bash@gnu.org>; Thu, 8 Jun 2017 15:37:35 -0700
Message-ID: <5939D1AD.9010909@tlinx.org>
Date: Thu, 08 Jun 2017 15:37:33 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
Subject: consistency probs w/ 'readonly -f' & 'export -f
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 22:37:45 -0000


First) readonly & export by show vars in a re-usable format, however,
       this doesn't work for functions.

Second) What is the official way to list functions w/their 
flags+definitions
        in a way reusable as input?

Third) How can one print the flags on a single function?


And a question - is there a reason why the "declare [flags] name=value"
format is prevented from working for functions?  Seems like it might
have worked at one time, but was disallowed?

Thanks!
-linda




From MAILER-DAEMON Thu Jun 08 18:48:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ6EB-0004lN-BA
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 18:48:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45713)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJ6E9-0004l3-4h
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:48:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJ6E6-0006dt-2v
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:48:29 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:41386
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJ6E5-0006dK-L3
	for bug-bash@gnu.org; Thu, 08 Jun 2017 18:48:26 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v58MmLct018411 for <bug-bash@gnu.org>; Thu, 8 Jun 2017 15:48:23 -0700
Message-ID: <5939D435.9050900@tlinx.org>
Date: Thu, 08 Jun 2017 15:48:21 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs w/ 'readonly -f' & 'export -f
References: <5939D1AD.9010909@tlinx.org>
In-Reply-To: <5939D1AD.9010909@tlinx.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 08 Jun 2017 22:48:30 -0000

Ooops... some more testing...

L
>
> First) readonly & export by show vars in a re-usable format, however,
>       this doesn't work for functions.
---
    It actually seems to be re-usable... though not nearly as
concisely as the var listing format.

> Second) What is the official way to list functions w/their 
> flags+definitions
>        in a way reusable as input?
---
See above.
> Third) How can one print the flags on a single function?
using> declare -pf <funcname>
output:
   <funcname> ()
   {
       <content>
   }
   declare -frx <funcname>


Which REALLY BEGS the QUESTION:

> why [is] the "declare [flags] name=value"
> format ... prevented from working for functions?

Sure seems like it would allow for some better consistency in
some circumstances, not to mention a more compact function-definition
form for re-use.




From MAILER-DAEMON Thu Jun 08 21:06:39 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJ8Nr-0004u5-8H
	for mharc-bug-bash@gnu.org; Thu, 08 Jun 2017 21:06:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39097)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ8Np-0004ty-O5
	for bug-bash@gnu.org; Thu, 08 Jun 2017 21:06:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJ8Nm-0003mS-LG
	for bug-bash@gnu.org; Thu, 08 Jun 2017 21:06:37 -0400
Received: from mail-pf0-x22d.google.com ([2607:f8b0:400e:c00::22d]:34055)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJ8Nm-0003mL-El
	for bug-bash@gnu.org; Thu, 08 Jun 2017 21:06:34 -0400
Received: by mail-pf0-x22d.google.com with SMTP id 9so22723304pfj.1
	for <bug-bash@gnu.org>; Thu, 08 Jun 2017 18:06:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=TSrd8nFqnhOjfyv8MfRM3bjkhP7de8lJ9sxU93VD06I=;
	b=WYfjDQLbGpPG7SXm2hdxNbKmP5LEkB5H/q4Tq5zGxq0dgx075pkTyOMQuoOV/PtGQp
	h3rRt5B9RYh/yDM23gS+BB8idrcvhorB6RLFWCINDLqb8dEChTAPPbuLMT1d2zU6D1c7
	V0/bSZuumA0nl8qVwRUbsTJ61aw1C8D4NcAyJmo7pa+RoF8L0Lt9ZCwx2LROX/SpLTsG
	06bNyxPAcLjBr9JWgyA4e1xTnql46iqR5sj0aow9aWemB7QLB2dqLUkr6SkSXGtb23ta
	SwQe19z4T5/bfaVvrDZsO2ztIGLaIcpWb/9UBLBY1bXIke7hD/KNSd06thecSQP+a/q4
	r82g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=TSrd8nFqnhOjfyv8MfRM3bjkhP7de8lJ9sxU93VD06I=;
	b=icGx/fLN5L2Y96zVMWm2D0H/5bedmsGXlkpHeUQdSZ/QflcUJu6ZDQSgQoQPgpcqPK
	s+HWMn8t/nhHbN+lijg1nXCedJ6/WL21OkRPY7uOELXDKZxf96P5yMajfTfAsVgcJRbP
	Uc4RfdkBp0P1y19thm9JTLVRg/Vb/ItNKwY+xSilsfxk6AieutbYmJdcOFiEHLfVVvJs
	B37KspJRPrdnbOCScGUXgDob5cwC0fv3wmMFne7lniwy5CUQ2zrqxNb665QUC3sNzjW6
	UfvdFtlB18Tic3fa8ZrRIE7nkZud1dS1AeYAsFShWfLAtAxdCnVyXBiSfVM1GnM1XuP2
	Z3MQ==
X-Gm-Message-State: AODbwcDE1vXdvzLc5hG7j7Y7GHE7VQkUzZ7MrdkP883ffpq2NdF7O/DM
	JSVvXdezY/8iuvHd
X-Received: by 10.98.41.130 with SMTP id p124mr36089067pfp.220.1496970393214; 
	Thu, 08 Jun 2017 18:06:33 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id f1sm10920669pgc.8.2017.06.08.18.06.30
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 08 Jun 2017 18:06:31 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Trailing newlines disappear
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
Date: Fri, 9 Jun 2017 08:06:28 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 01:06:38 -0000

On 09/06/2560 05:26, Eduardo Bustamante wrote:
> What's wrong with:
> 
> IFS= read -rd '' foo < "$file"

I think that's the winner!


From MAILER-DAEMON Fri Jun 09 08:06:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJIgl-0007RI-MQ
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 08:06:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42702)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIgj-0007QA-Kc
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:06:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIge-0000E4-Ij
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:06:49 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33549 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIge-0000Dn-Bx
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:06:44 -0400
Received: (qmail 28701 invoked from network); 9 Jun 2017 12:06:42 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 09 Jun 2017 08:06:42 -0400
Received: (qmail 12997 invoked by uid 563); 9 Jun 2017 12:06:42 -0000
Date: Fri, 9 Jun 2017 08:06:42 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170609120642.GL3691@eeg.ccf.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 12:06:50 -0000

On Fri, Jun 09, 2017 at 08:06:28AM +0700, Peter & Kelly Passchier wrote:
> On 09/06/2560 05:26, Eduardo Bustamante wrote:
> > What's wrong with:
> > 
> > IFS= read -rd '' foo < "$file"
> 
> I think that's the winner!

So long as you know the file doesn't contain any NUL bytes.  The other
variants will silently or loudly strip them out, while this one stops
reading at the first one it sees.

imadev:~$ unset a
imadev:~$ a=$(printf 'foo\0bar\nbaz\nquux\n'; printf x) a=${a%x}
bash: warning: command substitution: ignored null byte in input
imadev:~$ declare -p a
declare -- a="foobar
baz
quux
"

imadev:~$ unset a
imadev:~$ IFS= read -rd '' a < <(printf 'foo\0bar\nbaz\nquux\n')
imadev:~$ declare -p a
declare -- a="foo"

Actually, it looks like the mapfile variant also has its own... let's
call it "idiosyncratic" NUL handling:

imadev:~$ unset a
imadev:~$ mapfile -t a < <(printf 'foo\0bar\nbaz\nquux\n')
imadev:~$ declare -p a
declare -a a=([0]="foo" [1]="baz" [2]="quux")

Where did "bar" go?  Looks like mapfile loses the contents after a NUL
byte within each line, but then subsequent lines are fine.  (E.g. what
you would get if you blindly called strcpy() for each line, with the
source buffer possibly having multiple NULs.)


From MAILER-DAEMON Fri Jun 09 08:25:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJIyf-0006Wd-5U
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 08:25:21 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46048)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIyc-0006WO-8u
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:25:19 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIyY-0006Fd-6J
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:25:18 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33552 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJIyX-0006FT-VH
	for bug-bash@gnu.org; Fri, 09 Jun 2017 08:25:14 -0400
Received: (qmail 28831 invoked from network); 9 Jun 2017 12:25:12 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 09 Jun 2017 08:25:12 -0400
Received: (qmail 13034 invoked by uid 563); 9 Jun 2017 12:25:12 -0000
Date: Fri, 9 Jun 2017 08:25:12 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs w/ 'readonly -f' & 'export -f
Message-ID: <20170609122511.GM3691@eeg.ccf.org>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5939D435.9050900@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 12:25:20 -0000

On Thu, Jun 08, 2017 at 03:48:21PM -0700, L A Walsh wrote:
> >Second) What is the official way to list functions w/their 
> >flags+definitions
> >       in a way reusable as input?

declare -fp funcname

> >Third) How can one print the flags on a single function?
> using> declare -pf <funcname>

Why are you asking if you already know the answer?

> output:
>   <funcname> ()
>   {
>       <content>
>   }
>   declare -frx <funcname>

Right.  There you go.

> >why [is] the "declare [flags] name=value"
> >format ... prevented from working for functions?

I don't know what you mean.  A function is not a name=value pair.
Why would you expect the output to have an = sign in it?  Or, why
would you expect name=value to create a function?

Are you asking to see the internal serialization syntax that bash uses
when it hacks a function definition into the environment?  You can just
dump the raw environment variable if that's what you want.

imadev:~$ export -f sprunge
imadev:~$ env | awk '/_sprunge/{print; getline; print}'
BASH_FUNC_sprunge%%=() {  tail -n +1 -- "$@" | curl -F 'sprunge=<-' http://sprunge.us
}

Is that what you're looking for?  Bear in mind, the environment variable
name is dependent on which shellshock patch your version of bash uses.
E.g. in Debian wheezy:

greg@remote:~$ foo() { echo foo; }; export -f foo
greg@remote:~$ env | awk '/_foo/{print; getline; print}'
BASH_FUNC_foo()=() {  echo foo
}

This is not meant to be seen by the ordinary end user.  It's internal
voodoo.

> Sure seems like it would allow for some better consistency in
> some circumstances, not to mention a more compact function-definition
> form for re-use.

What are you talking about?  Consistency between what two things?

Are you allergic to newlines?  declare -p uses raw newlines in its output
whenever it feels they are appropriate.  Even in ordinary shell variables:

imadev:~$ x=$'foo\nbar'
imadev:~$ declare -p x
declare -- x="foo
bar"

Is that "consistent" enough for you?

Remember, a newline only takes 1 byte of memory.

The output is reusable, but only if you actually use it correctly.  E.g.
stuff it into a variable and use eval "$myvar" with the double quotes.
Or redirect it into a file and use source ./myfile.

What are you trying to do?  What did you try?  What happened?  What did
you expect to happen instead?


From MAILER-DAEMON Fri Jun 09 09:23:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJJsZ-0004J8-96
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 09:23:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58743)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJJsX-0004HW-2r
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:23:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJJsT-0001zU-Th
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:23:05 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:63109
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dJJsT-0001zK-NF
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:23:01 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMB71215; Fri, 09 Jun 2017 09:22:59 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFS36098 (AUTH cpr);
	Fri, 09 Jun 2017 09:22:59 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Trailing newlines disappear
To: Greg Wooledge <wooledg@eeg.ccf.org>, "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
Date: Fri, 9 Jun 2017 09:22:58 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170609120642.GL3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.9.123316:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_1100_1199,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	__FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS, IN_REP_TO,
	MSG_THREAD, __FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 13:23:06 -0000

On 6/9/17 8:06 AM, Greg Wooledge wrote:

> Actually, it looks like the mapfile variant also has its own... let's
> call it "idiosyncratic" NUL handling:
> 
> imadev:~$ unset a
> imadev:~$ mapfile -t a < <(printf 'foo\0bar\nbaz\nquux\n')
> imadev:~$ declare -p a
> declare -a a=([0]="foo" [1]="baz" [2]="quux")
> 
> Where did "bar" go?  Looks like mapfile loses the contents after a NUL
> byte within each line, but then subsequent lines are fine.  (E.g. what
> you would get if you blindly called strcpy() for each line, with the
> source buffer possibly having multiple NULs.)

There's no mystery here. Mapfile reads lines delimited by newlines --
read(2) is happy to do that job. Shell variable values can't contain NULs;
they never have been able to. The entire line read gets stored as the
value, but since C strings are NULL-terminated, you just see the contents
preceding the first NUL. Should mapfile silently drop the NULs?

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 09 09:37:00 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJK60-0002Ud-Eg
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 09:37:00 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34450)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJK5x-0002SQ-UD
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:36:59 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJK5t-0007Rx-1X
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:36:57 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33564 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJK5s-0007L0-Qm
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:36:52 -0400
Received: (qmail 29265 invoked from network); 9 Jun 2017 13:36:22 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 09 Jun 2017 09:36:22 -0400
Received: (qmail 13175 invoked by uid 563); 9 Jun 2017 13:36:22 -0000
Date: Fri, 9 Jun 2017 09:36:22 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170609133622.GN3691@eeg.ccf.org>
References: <20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 13:36:59 -0000

On Fri, Jun 09, 2017 at 09:22:58AM -0400, Chet Ramey wrote:
> On 6/9/17 8:06 AM, Greg Wooledge wrote:
> > imadev:~$ mapfile -t a < <(printf 'foo\0bar\nbaz\nquux\n')
> > imadev:~$ declare -p a
> > declare -a a=([0]="foo" [1]="baz" [2]="quux")
> 
> There's no mystery here. Mapfile reads lines delimited by newlines --
> read(2) is happy to do that job. Shell variable values can't contain NULs;
> they never have been able to. The entire line read gets stored as the
> value, but since C strings are NULL-terminated, you just see the contents
> preceding the first NUL. Should mapfile silently drop the NULs?

I'm not requesting any changes.  I'm simply trying to show all of the
existing behaviors, and specifically the three different results that one
gets by using three different techniques to read a file into a variable.
(Either you get the entire file with all NULs removed; or you get the
file with each line truncated at the first NUL within that line; or you
get the file only up to the first NUL.)  That way, people can choose the
appropriate technique for the result they want.

If anything, the fact that $() drops NUL bytes is the surprising outlier.
But it's definitely too late to change that.  Remember how many people
bitched and complained when 4.4 added a warning?


From MAILER-DAEMON Fri Jun 09 09:47:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJKFr-0000Dn-4U
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 09:47:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38051)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJKFo-0000Bh-3Y
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:47:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJKFk-0003Ni-7B
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:47:08 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:3555
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dJKFk-0003NW-1K
	for bug-bash@gnu.org; Fri, 09 Jun 2017 09:47:04 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMB72726; Fri, 09 Jun 2017 09:47:02 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFS40420 (AUTH cpr);
	Fri, 09 Jun 2017 09:47:01 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Trailing newlines disappear
To: Greg Wooledge <wooledg@eeg.ccf.org>, "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<20170609133622.GN3691@eeg.ccf.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <72d0710a-c905-5227-1339-596f2b29d2bc@case.edu>
Date: Fri, 9 Jun 2017 09:47:01 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170609133622.GN3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.9.133316:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 13:47:09 -0000

On 6/9/17 9:36 AM, Greg Wooledge wrote:

> If anything, the fact that $() drops NUL bytes is the surprising outlier.
> But it's definitely too late to change that.  Remember how many people
> bitched and complained when 4.4 added a warning?

How could I forget? But the complaining came because they wanted the NUL-
dropping behavior (which had been in place forever) and objected to the
noise.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 09 12:36:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJMu9-0007WV-A7
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 12:36:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54953)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJMu7-0007WO-Jv
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:36:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJMu3-0005MC-JX
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:36:55 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:53064
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJMu3-0005LZ-9P
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:36:51 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v59Gagkb027275; Fri, 9 Jun 2017 09:36:44 -0700
Message-ID: <593ACE9A.4080100@tlinx.org>
Date: Fri, 09 Jun 2017 09:36:42 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs w/ 'readonly -f' & 'export -f
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org>
In-Reply-To: <20170609122511.GM3691@eeg.ccf.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 16:36:56 -0000

Greg Wooledge wrote:
> I don't know what you mean. A function is not a name=value pair.
The name is the name of the function, the value is
what the function does. 

   declare -f hw='() { echo "Hello World\n"; }'

The above has a name on the left side, and the value of the name
is on the right side.  One can reformat it so it looks like a
function, but that's eye-candy.

Isn't this a legal variable assignment?:

    hw='() { echo "Hello World\n"; }'

the left is the name and the right side is a string-value.

Now suppose you could set the 'f' flag via declare:

   declare -f hw

It would move 'hw' out of the variable space and into the function
space (since vars and funcs are in separate spaces in bash) where you
could then execute it. 

In bash instead of just allowing the flag change, you need to go through
'eval' to enable execution on it,

But it theoretically could be enabled by allow the 'f' flag to be set
when it isn't.




From MAILER-DAEMON Fri Jun 09 12:38:42 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJMvq-0007we-Il
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 12:38:42 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55191)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJMvo-0007wL-In
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:38:41 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJMvk-0005jo-Jc
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:38:40 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:53164
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJMvk-0005jX-92
	for bug-bash@gnu.org; Fri, 09 Jun 2017 12:38:36 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v59GcPjF027444; Fri, 9 Jun 2017 09:38:27 -0700
Message-ID: <593ACF01.3000404@tlinx.org>
Date: Fri, 09 Jun 2017 09:38:25 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: Greg Wooledge <wooledg@eeg.ccf.org>, "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>	<20170608174238.GH3691@eeg.ccf.org>	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>	<20170608191440.GI3691@eeg.ccf.org>	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>	<20170608205637.GK3691@eeg.ccf.org>	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
In-Reply-To: <ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 16:38:41 -0000

Chet Ramey wrote:
>
>  Should mapfile silently drop the NULs?
>   

Maybe add a flag to ignore NUL bytes that could be used in the 'read'
statement as well?  If not specified, keep same behavior?




From MAILER-DAEMON Fri Jun 09 13:35:12 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJNoW-00025B-Jf
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 13:35:12 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35288)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJNoU-00023K-0m
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:35:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJNoQ-0007xl-3h
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:35:10 -0400
Received: from mail-pg0-x230.google.com ([2607:f8b0:400e:c05::230]:33903)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJNoP-0007w6-Tb
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:35:06 -0400
Received: by mail-pg0-x230.google.com with SMTP id v18so28609168pgb.1
	for <bug-bash@gnu.org>; Fri, 09 Jun 2017 10:35:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=GO1ekgkvCZZqSZJ06z3czqc+Qi5tJlXciWELPjIq+Uk=;
	b=hyZGxP2dv/oaS59dL4/0Jb6hcw0ssf0WKANLqRW/ozTQpaJzVjR8rpV/TZKKTZCN5S
	pOrXZsaOUI/btEIK8jkdzD8Cxxc6DuDqAe2MQbRso+Nto/e+s1wf3cdawhn2LH4oDC1a
	0uUNQohKUvhFgUxz5e/zdTGZ/b/GYSlK7hdzWYpO0dcMCOMod8iLapIUJjnS6CbWrPSf
	PcBG+7zEMuH+AL8XN4QEMv4flPiMQDDi/C90y9SpFH4ecyfRf6Vs+iLNPQ8LBMG3uQe/
	puMJpMi0heQCbywpjgjp3qQ6RorCfKnbaBlJTNdh52E8MalFz4LPFA8SAT+PWaqcFSh/
	8q3A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=GO1ekgkvCZZqSZJ06z3czqc+Qi5tJlXciWELPjIq+Uk=;
	b=ALZzSl9wGuT8iHaFCm/Xc/hPHsN2LM2MO/4HxL7KgW+Q8RTbVT5Xaga6HUZatbUQyY
	LhMt0bIU/Ee+uWB+e+g/Gtbk64u/+h9EaLFGe84iVZ36ITz7cUWqLMzRAjfIDE1Ku1Wv
	Pzp6jOuq6P/Ul6y8TvXhztMo0rwyIwInA3CcCHQiqgNdibvYJ99c2NPbZGFWuvqzilXw
	oAd9pwnDOgyqkGmKuUby7RKpgoa9aiT4ifI6BSryyJAKXSxX363Kxi64pHgZQZPQhJbo
	nnHChQ1aASdQpzwS7fAxz0se6hYEz9UmasbhNwZ5lKBwrgpVQU8D9fbUYdyMh4MH11pr
	G8bg==
X-Gm-Message-State: AODbwcBnmL+djVtwnt+33YJjs5ziFQJr1jE25nuio4XG6MODS4c7mlYd
	dATfmztyoqBzmS1B
X-Received: by 10.84.209.238 with SMTP id y101mr41515746plh.290.1497029700796; 
	Fri, 09 Jun 2017 10:35:00 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	m123sm4444207pfc.51.2017.06.09.10.34.59 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Fri, 09 Jun 2017 10:34:59 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: Trailing newlines disappear
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
Message-ID: <d7741ae3-f29c-1446-18e4-b37af432dda5@passchier.net>
Date: Sat, 10 Jun 2017 00:34:57 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170609120642.GL3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 17:35:10 -0000

On 09/06/2560 19:06, Greg Wooledge wrote:
> imadev:~$ a=$(printf 'foo\0bar\nbaz\nquux\n'; printf x) a=${a%x}
> bash: warning: command substitution: ignored null byte in input
> imadev:~$ declare -p a
> declare -- a="foobar
> baz
> quux
> "
> 
> imadev:~$ IFS= read -rd '' a < <(printf 'foo\0bar\nbaz\nquux\n')
> imadev:~$ declare -p a
> declare -- a="foo"
> 
> imadev:~$ unset a
> imadev:~$ mapfile -t a < <(printf 'foo\0bar\nbaz\nquux\n')
> imadev:~$ declare -p a
> declare -a a=([0]="foo" [1]="baz" [2]="quux")

That is good to realize. I guess languages that strive for improvements
and yet backward comparibility over many years just end op being arcane!

Peter


From MAILER-DAEMON Fri Jun 09 13:41:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJNuF-0003cg-8q
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 13:41:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36434)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJNuD-0003cR-2l
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:41:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dJNu9-0001XN-2Y
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:41:05 -0400
Received: from mail-pf0-x22d.google.com ([2607:f8b0:400e:c00::22d]:32939)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dJNu8-0001X9-Rd
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:41:00 -0400
Received: by mail-pf0-x22d.google.com with SMTP id 83so30727885pfr.0
	for <bug-bash@gnu.org>; Fri, 09 Jun 2017 10:41:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=PFEx/QdZsDLbeqxdEzxo2kuAdizxyysZdo4mJ3EJ7O4=;
	b=YpC3N2Xxb8ZKwIcAh3/zawzo9GyOMNSnFKtgIa2aw21wB3Edl+v8TfEJNQO0Un/mS4
	DsW6+pLc5pWA4u1YIYzN6ciw5IRA1gA9gV0QQXr5CXJJDZjzB5nbU/BGycAagjv6C+Ys
	5mtxdL+xQQmbb7NSKLQLeUhHueeOl7B7KfcsPJjL/WpQqNxYBOMVQL89QhygtZjmpV4o
	0FBXD6kPPN5m0bmd/V6Aei2aqtY7VwZAXjQKUa1XNwuGJt8icLeLkcBD4rn+sh/O6Qv5
	ojMAQJOsP1eT4+VxzUkwuI316KfSa/+hWXEa1xqv6zTWe+BWynwU4B450r8hPUbgfl26
	tqeg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=PFEx/QdZsDLbeqxdEzxo2kuAdizxyysZdo4mJ3EJ7O4=;
	b=mbTsmn0MQPNMxVlXK7FoDeg5KudgFc9m3JlQYl19ReaGORt9t5wOu9r9CU5UJkfuSI
	x60g9zRSesohUcaYDiTTaHvt3QNBzgBL2zzdTOC38x4OX9sRglKfF9OOdsZvEGylPoNs
	ZmWZqoE144zfgYGA2PNFlnl7GBWigrmJnwCSJqDXnJ004kPunapgGFNkWdJawH/+5IE9
	qOaMhBnGHP0yCUAjxHun4+DRWRFaZE2AwwBtiaxtyS4Cu5hAPqqZsjHFLEEI4WdM0cgZ
	pCKl9ONTp57NsF6edoWS4TokIYeFgGkqR6J0AUIEf3A1e4gtriQDVycV3KDuGxYd2iSU
	b8lw==
X-Gm-Message-State: AODbwcAbuI8F0WyD9d/sgv84E0uJtCCa42Kliw1q+ogLGDXmr9XxPaAw
	mKUh6bNt8buSpH7Z
X-Received: by 10.98.163.25 with SMTP id s25mr43295441pfe.217.1497030059585;
	Fri, 09 Jun 2017 10:40:59 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.66.43])
	by smtp.gmail.com with ESMTPSA id
	u62sm3662613pgd.53.2017.06.09.10.40.58 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Fri, 09 Jun 2017 10:40:58 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Trailing newlines disappear
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
Date: Sat, 10 Jun 2017 00:40:56 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <593ACF01.3000404@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 17:41:06 -0000

On 09/06/2560 23:38, L A Walsh wrote:
> Chet Ramey wrote:
>>
>>  Should mapfile silently drop the NULs?
> 
> Maybe add a flag to ignore NUL bytes that could be used in the 'read'
> statement as well?  If not specified, keep same behavior?

That sounds like it might be useful.
It might be more desirable to change it to a newline instead of dropping
it? (Or both, with different flags??)

And how about a shell option to not omit trailing newlines in command
substitutions?? I find that very undesirable and unnecessary behaviour.

Peter



From MAILER-DAEMON Fri Jun 09 13:58:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJOB5-00006u-A7
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 13:58:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39037)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dJOB3-00006R-0U
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:58:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dJOB2-0006tw-28
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:58:29 -0400
Received: from mail-qt0-x22e.google.com ([2607:f8b0:400d:c0d::22e]:33162)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <pierre.gaston@gmail.com>)
	id 1dJOB1-0006tk-UL
	for bug-bash@gnu.org; Fri, 09 Jun 2017 13:58:28 -0400
Received: by mail-qt0-x22e.google.com with SMTP id u12so84423837qth.0
	for <bug-bash@gnu.org>; Fri, 09 Jun 2017 10:58:26 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=2R7fZ9xl/sQbs7faeg/VKLrUi/AeTP4vnyiHpFZZFI8=;
	b=jT9R6aNobTJncmaJHtxj/2plplFPMxYi89/Rb5em0GfNmiDF3gJQY24s1Zq/rlotce
	R1nZedF8yJ/LomunwRDRlgkMAKJx4iCnJMkD98DqjLpc75WusWffe0dIRqG+yzfJl/WC
	eP4qBNaO2PFd1jwOAloTGRjWLHRP0aJz6b4O+s0eYe5FkcvPyQEbZOyu44KkNZmADpZF
	8mthlj9LCMSE+X0OF0RlV3Dgt0vzLXWI2S4IPvY0rQF2jxh/xp82hDNZCq9AzxOXc36R
	T7RKoVsg+rThbz0SHAQ20hWYPcq9ZPHJkloULfEqauhYvzoolV905weQq+xhaueC5Bes
	N/PQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=2R7fZ9xl/sQbs7faeg/VKLrUi/AeTP4vnyiHpFZZFI8=;
	b=Dkls+giX+eTokC26b74yxRjpP3KbSVxLVJOPPXGiJf1OuUtjRHyVEKezBnbSG+SHaH
	GA2Q/lwWuD7HEYHFi9vJOsOMsRk01p6L8vL7qfbVKRYGZMs11zixWmlJDSXZptIBTwYf
	6LZleR4xsPlesgVcZHnq3kTarcELZdKg9es3Bc5Y7iod/n564KCW6R0G1oVsGJuqzD/q
	9O9tghz6Ru64e6Mo16CE6uxU0Nc6OY+AVDqcyLPwOUCTr+P7gdVjLicReeUpBbbYWds6
	RHOfMWHRV408eD1eZuKzrHQZBy19bleS513MU0TTDk2ajXd59zKMKufgUoJnwHYqkgch
	rFQQ==
X-Gm-Message-State: AODbwcCHKgwFvcH7w2z8vYHxZkhrFYs/beATppB5CaFGi0RAXX9rqW99
	k0EN4+R4pbmJAxB2/RIheu3EdumxcUlh
X-Received: by 10.55.165.81 with SMTP id o78mr43430210qke.229.1497031105986;
	Fri, 09 Jun 2017 10:58:25 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.160.166 with HTTP; Fri, 9 Jun 2017 10:58:05 -0700 (PDT)
In-Reply-To: <b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
From: Pierre Gaston <pierre.gaston@gmail.com>
Date: Fri, 9 Jun 2017 20:58:05 +0300
Message-ID: <CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
Subject: Re: Trailing newlines disappear
To: "Peter & Kelly Passchier" <peterkelly@passchier.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::22e
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 17:58:30 -0000

On Fri, Jun 9, 2017 at 8:40 PM, Peter & Kelly Passchier <
peterkelly@passchier.net> wrote:

> On 09/06/2560 23:38, L A Walsh wrote:
> > Chet Ramey wrote:
> >>
> >>  Should mapfile silently drop the NULs?
> >
> > Maybe add a flag to ignore NUL bytes that could be used in the 'read'
> > statement as well?  If not specified, keep same behavior?
>
> That sounds like it might be useful.
> It might be more desirable to change it to a newline instead of dropping
> it? (Or both, with different flags??)
>

I feel this kind of magic behavior would result in hackish scripts or fill
a somewhat rare niche at best.
I'd rather have bash to fully handle arrays of byte, or nothing.


> And how about a shell option to not omit trailing newlines in command
> substitutions?? I find that very undesirable and unnecessary behaviour.
>
> Peter
>
> I would argue that dropping the trailing newlines is what most use and
want.
Even if they don't realize it, few people would expect:

var=$(wc -l file);echo "$var"

to print 2 lines.

Trailing newlines are often not that interesting.

From MAILER-DAEMON Fri Jun 09 14:04:27 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJOGp-0003hX-2V
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 14:04:27 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40003)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJOGm-0003gW-0l
	for bug-bash@gnu.org; Fri, 09 Jun 2017 14:04:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJOGi-0000Dh-Tu
	for bug-bash@gnu.org; Fri, 09 Jun 2017 14:04:24 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:33661 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dJOGi-0000DX-MN
	for bug-bash@gnu.org; Fri, 09 Jun 2017 14:04:20 -0400
Received: (qmail 31017 invoked from network); 9 Jun 2017 18:04:19 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 09 Jun 2017 14:04:19 -0400
Received: (qmail 13613 invoked by uid 563); 9 Jun 2017 18:04:18 -0000
Date: Fri, 9 Jun 2017 14:04:18 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: Pierre Gaston <pierre.gaston@gmail.com>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
Message-ID: <20170609180418.GO3691@eeg.ccf.org>
References: <1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 18:04:24 -0000

On Fri, Jun 09, 2017 at 08:58:05PM +0300, Pierre Gaston wrote:
> Even if they don't realize it, few people would expect:
> 
> var=$(wc -l file);echo "$var"
> 
> to print 2 lines.

imadev:~$ file=$'a\nb\nc\nd\ne'; touch "$file"
imadev:~$ var=$(wc -l "$file"); echo "$var"
0 a
b
c
d
e

> Trailing newlines are often not that interesting.

But embedded newlines certainly are!


(Really, though, I know what you meant.  Command substitution strips
trailing newlines because that's how it has always worked, and because
95% of the time, that's what you want.)


From MAILER-DAEMON Fri Jun 09 17:59:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJRwe-0007Nr-QJ
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 17:59:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33856)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJRwZ-0007Nj-N1
	for bug-bash@gnu.org; Fri, 09 Jun 2017 17:59:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dJRwU-0005QE-TA
	for bug-bash@gnu.org; Fri, 09 Jun 2017 17:59:47 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:6861
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dJRwU-0005PV-Nr
	for bug-bash@gnu.org; Fri, 09 Jun 2017 17:59:42 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMG88909; Fri, 09 Jun 2017 17:59:36 -0400 (EDT)
Received: from 162.248.43.3 (EHLO jenna.local) ([162.248.43.3])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HNZ80528 (AUTH cpr);
	Fri, 09 Jun 2017 17:59:35 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Remaining memory corruption bugs in readline
To: dualbus <dualbus@gmail.com>, bug-bash@gnu.org
References: <20170602050734.a2jjlilt32mbk5t2@debian>
	<20170608150933.tqkeflh46jxnsrt2@debian>
	<6e78feee-edfe-4596-7384-62f2e53c630a@case.edu>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <450de173-8890-85f4-8944-4be372123e40@case.edu>
Date: Fri, 9 Jun 2017 17:59:34 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <6e78feee-edfe-4596-7384-62f2e53c630a@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.9.204216:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_1300_1399, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 21:59:51 -0000

On 6/8/17 11:34 AM, Chet Ramey wrote:
> On 6/8/17 11:09 AM, dualbus wrote:
>> On Fri, Jun 02, 2017 at 12:07:34AM -0500, dualbus wrote:
>> [...]
>>> #1 _rl_get_char_len / update_line
>> [...]
>>>   ==5781==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f400d00b063 bp 0x7ffcbce72250 sp 0x7ffcbce71a00
>>>   READ of size 851 at 0x61900000cc80 thread T0
>>>       #0 0x7f400d00b062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
>>>       #1 0x559b50a04821 in _rl_get_char_len ../../../bash/lib/readline/mbutil.c:223
>>>       #2 0x559b50a048e0 in _rl_compare_chars ../../../bash/lib/readline/mbutil.c:252
>>>       #3 0x559b509db526 in update_line ../../../bash/lib/readline/display.c:1664
>> [...]
>>
>> I have been looking at this specific example for some time now.
>>
>> The problem is that _rl_get_char_len assumes it's being called with a
>> \0-terminated string, but under some cases (that I haven't been able to
>> figure out), there's no \0 at the end, so the strlen reads more than it
>> should.
> 
> I've been traveling and have not looked at this.

It's an off-by-one error.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 09 18:50:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJSjs-0002aY-WB
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 18:50:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46443)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJSjr-0002aP-17
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:50:43 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJSjq-0007qM-4n
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:50:43 -0400
Received: from mail-qt0-x230.google.com ([2607:f8b0:400d:c0d::230]:36355)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dJSjp-0007pd-Vj
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:50:42 -0400
Received: by mail-qt0-x230.google.com with SMTP id u19so91651232qta.3
	for <bug-bash@gnu.org>; Fri, 09 Jun 2017 15:50:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=cz8zQmoSOa5zNMYPxtmLJO1Lv57ZjWMh6EnauyXW94Y=;
	b=ZTWeIngKhWz6p5KGozTfgjy+uUQu4zbcaMm0GnmqtcD8f8c2UQqEpI+AJTvd7mNy4d
	HRo/YsLfxTrj4Z/XTcpf1l2RYoIlY3vnrqBz48exR+JfFCQUVlSOK+ycTI9ZiHbAW4Sd
	oqI4oyO2mgxSAmxcyCqG8SZyPeDuzH0Zf+NQPMaJ28VKxRJ7ojveP1vpjmc1C38t4JJv
	DJ0zsDRk+H7pTNnM0e4PcZncQM78vLHgdJY5DXMv7ig3vqG0cmUrGAZUyCCFNjhslToC
	4JwiHTMCHXsg0LyznBHYkZ9CH0vK1JUrdc0MRuP5ec0adXUtYQObzS1MFryAmJ28KL4L
	Id9w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=cz8zQmoSOa5zNMYPxtmLJO1Lv57ZjWMh6EnauyXW94Y=;
	b=bStH6dWMXKn/sxK6+Gqx2WrnUtmcyxpHiNhgYAiilZxkr41Dx1J5ppMRE9wY8c4b7o
	/Kcrn0rXF/KZ5x4d/7XtDenmeYVZcVhh/oilZ3W0oraRA19ZDnba3R0XFh5zfhDqxqVe
	LIMm4fSyWp7PS6CASy4bgqHdweRI4xozKIgeZ8aGgW37KT6AqWLl2DbRzANu3Bwq+nfx
	fSX9w50L6MIhgF/niroT758bBSvHM8+UnLXCPNCPeqa/UARhR7/v/Qpy+xgi5BVtTGqW
	keNDTRHZpiTsaVoPjtA5Pdto64rmu+HhnrSOYccK2dd0P7tRhxI0dZZN6vNQdu/zQZBx
	/X+w==
X-Gm-Message-State: AKS2vOyaODYduCFMSj4RxIAgs7+8fkJb1/TCW3YbqAPf/4PWm4waE4VQ
	XHMODVL0aIynHra4Ib3YI8exHY3CiQ==
X-Received: by 10.55.55.207 with SMTP id e198mr55524625qka.44.1497048639756;
	Fri, 09 Jun 2017 15:50:39 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.178.25 with HTTP; Fri, 9 Jun 2017 15:50:19 -0700 (PDT)
In-Reply-To: <450de173-8890-85f4-8944-4be372123e40@case.edu>
References: <20170602050734.a2jjlilt32mbk5t2@debian>
	<20170608150933.tqkeflh46jxnsrt2@debian>
	<6e78feee-edfe-4596-7384-62f2e53c630a@case.edu>
	<450de173-8890-85f4-8944-4be372123e40@case.edu>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Fri, 9 Jun 2017 17:50:19 -0500
Message-ID: <CAOSMAusF1R9Y9aW8e30X2HPnpPknmaoqCNMwSqsHTGuVBrBt1w@mail.gmail.com>
Subject: Re: Remaining memory corruption bugs in readline
To: Chet Ramey <chet.ramey@case.edu>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 22:50:43 -0000

On Fri, Jun 9, 2017 at 4:59 PM, Chet Ramey <chet.ramey@case.edu> wrote:
[...]
> It's an off-by-one error.

Thank you! Do you have a patch? I want to run the patched version
against the corpus of crashing inputs that I have to see if there are
any remaining.


From MAILER-DAEMON Fri Jun 09 18:53:10 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJSmE-0003hA-DM
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 18:53:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46911)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJSmB-0003gk-SU
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:53:08 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJSm7-0008Qz-Tr
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:53:07 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:39430
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJSm7-0008Oq-Ji
	for bug-bash@gnu.org; Fri, 09 Jun 2017 18:53:03 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v59MqrxS053928; Fri, 9 Jun 2017 15:52:56 -0700
Message-ID: <593B26C5.6070002@tlinx.org>
Date: Fri, 09 Jun 2017 15:52:53 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org>
In-Reply-To: <20170609122511.GM3691@eeg.ccf.org>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 22:53:08 -0000

Greg Wooledge wrote:
> What are you talking about? Consistency between what two things?
> Are you allergic to newlines? declare -p uses raw newlines in its output
> whenever it feels they are appropriate. Even in ordinary shell variables:
>
> imadev:~$ x=$'foo\nbar'
> imadev:~$ declare -p x
> declare -- x="foo
> bar"
>
> Is that "consistent" enough for you?
----
    First problem: If you are assigning a string to a variable,
you need to put quotes around the string.  That shows that "-p"
doesn't insert newlines:

  > x="$'foo\nbar'"
  > declare -p x
  declare -- x="\$'foo\\nbar'"

    However, if that is your example showing dcl-p's rule for inserting
newlines, then given this funcdef:

   hh(){ echo "hi";}

There shouldn't be any newlines (only inserting them when user
inserted a newline via $'\n').  However, in bash's output of
that function:

  > alias my=declare pf='my -pf'
  > pf hh
  hh ()
  {
      echo "hi"
  }
---
Oops... superfluous newlines were added :-(

>
> Remember, a newline only takes 1 byte of memory.
>
> The output is reusable, but only if you actually use it correctly. E.g.
> stuff it into a variable and use eval "$myvar" with the double quotes.
> Or redirect it into a file and use source ./myfile.
>
> What are you trying to do? 
Read var & func defs via a 'read' of 1 line.

> What did you try? 
  x="$'foo\nbar'"
  read -r mydef< <(declare -p x)
  echo "$mydef"

  hh(){ echo hi;}
  read -r mydef< <(declare -pf hh)
  echo "$mydef"


> What happened? 
1st case worked:
declare -- x="\$'foo\nbar'"

2nd case didn't:
hh ()

> What did you expect to happen instead?
If there was a consistency, then would have expected both to work.




From MAILER-DAEMON Fri Jun 09 19:01:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJSuL-0005gj-6W
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 19:01:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48359)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJSuI-0005gZ-CU
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:01:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJSuF-00039n-7w
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:01:30 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:39734
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJSuE-00039N-Ui
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:01:27 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v59N1MYl054507; Fri, 9 Jun 2017 16:01:24 -0700
Message-ID: <593B28C2.3030704@tlinx.org>
Date: Fri, 09 Jun 2017 16:01:22 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Dethrophes <dethrophes@web.de>
CC: bug-bash@gnu.org
Subject: Re: Patch for unicode in varnames...
References: <1496512817.17253.69.camel@scope-eye.net>	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>	<20170604074538.36cmislgervrqiqw@debian>	<593455D1.9050706@tlinx.org>	<1496652739.17253.82.camel@scope-eye.net>	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>	<1496702373.17253.179.camel@scope-eye.net>	<5935E659.9040308@tlinx.org>	<1496734633.17253.275.camel@scope-eye.net>	<5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>	<1496869388.17253.349.camel@scope-eye.net>
	<697E1957-01B5-4283-89CE-AF052DA3171B@web.de>
In-Reply-To: <697E1957-01B5-4283-89CE-AF052DA3171B@web.de>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 23:01:31 -0000

Dethrophes wrote:
> This would be a bad idea in the same way that having control characters in filenames is a bad idea, just because you can do something doesn't mean you should.
>   
Not true.  While POSIX has *discussed* disallowing control characters in
filenames, using Unicode in filenames is fully supported on linux and 
windows.

Using your 'meter' as what is good/bad (what is allowed & good in filenames)
unicode in function & varnames would be "as good" (as in proper) as the
use of it in filenames.





From MAILER-DAEMON Fri Jun 09 19:06:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJSz6-0006rK-UF
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 19:06:28 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49261)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJSz4-0006pn-GQ
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:06:27 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJSz1-0004eS-1U
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:06:26 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:50432
	helo=homiemail-a79.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dJSz0-0004cp-Ls
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:06:22 -0400
Received: from homiemail-a79.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a79.g.dreamhost.com (Postfix) with ESMTP id F1E32600341A; 
	Fri,  9 Jun 2017 16:06:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=mEjhuQA9/fNa/s9y
	UsIW2x9/5TE=; b=0rUsnvqHCTUSAOsPUPdKMFZm3ethW8jN5frKLMWZOKcByS6s
	3MMvMX5bx/qSyhaFq9VXqkPtTXj8EiqUZNIBpxRat6YKpjDEUDV9oEcCM0Xsv4kT
	p+sSsQpv48uDeDXEUQGCTUF1fCIDhTSPmh263WnrOPkUOZbLIwAU++lr660=
Received: from frontier (unknown [76.191.34.78])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a79.g.dreamhost.com (Postfix) with ESMTPSA id 84FF46003419;
	Fri,  9 Jun 2017 16:06:18 -0700 (PDT)
Message-ID: <1497049577.17253.408.camel@scope-eye.net>
Subject: Storing NUL in variables
From: George <tetsujin@scope-eye.net>
To: Pierre Gaston <pierre.gaston@gmail.com>, Peter & Kelly Passchier
	<peterkelly@passchier.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Date: Fri, 09 Jun 2017 19:06:17 -0400
In-Reply-To: <CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 23:06:28 -0000

On Fri, 2017-06-09 at 20:58 +0300, Pierre Gaston wrote:
> On Fri, Jun 9, 2017 at 8:40 PM, Peter & Kelly Passchier <
> peterkelly@passchier.net> wrote:
>=20
> >=20
> > On 09/06/2560 23:38, L A Walsh wrote:
> > >=20
> > > Chet Ramey wrote:
> > > >=20
> > > >=20
> > > > =C2=A0Should mapfile silently drop the NULs?
> > > Maybe add a flag to ignore NUL bytes that could be used in the 'rea=
d'
> > > statement as well?=C2=A0=C2=A0If not specified, keep same behavior?
> > That sounds like it might be useful.
> > It might be more desirable to change it to a newline instead of dropp=
ing
> > it? (Or both, with different flags??)
> >=20
> I feel this kind of magic behavior would result in hackish scripts or f=
ill
> a somewhat rare niche at best.
> I'd rather have bash to fully handle arrays of byte, or nothing.
>=20
I think allowing shell variables to contain NUL would be lovely. How abou=
t we make that happen? =C2=A0:)
(I would be up for writing a patch to do it, of course, though I have a f=
ew other things in the pipeline... A feature like this could take a fair =
bit
of work depending on how far the implementation goes in supporting variou=
s things.)
Of course such variables couldn't be exported (the NULs would be lost if =
the data were stored in an environment variable) and for compatibility,
variables should probably support containment of NULs only if the caller =
specifically requests it with an argument to "declare" or "read".
...And then there is the problem of how to use such variables. They can't=
 be exported as environment variables or passed as command arguments, or =
used
as file names... =C2=A0Essentially they'd be limited to use in I/O within=
 the shell, and within a handful of built-in commands or shell functions =
equipped
to properly handle that data.
I think that this approach, capturing an arbitrary byte stream and then t=
aking further actions to process or encode it, is preferable to the
alternative of capturing the byte stream and simultaneously encoding it i=
nto a text format. In principle commands like "read" shouldn't transform =
the
data they're given, they should just store it. (I think the fact that rea=
d requires the option "-r" to read data without transforming it is kind o=
f
unfortunate...)
(That said, one could argue that it would be equally reasonable, or even =
more reasonable to implement an operation that simultaneously reads and
encodes the data, and another that decodes the data and writes it out, an=
d then any commands designed to perform operations on byte stream data in=
 the
shell (re-encode it in a different format, etc.) should simply use that f=
irst encoding as a common format for exchanging the data.. =C2=A0Given th=
e
limitations of the shell with respect to its ability to handle NUL in var=
ious contexts, I think it's a reasonable argument. I tend to prefer the i=
dea
of providing true shell support for capturing a byte stream because it ma=
kes it easier to write code that handles the data without having to build=
-in
a parser to interpret the data first.)
One option that might make a feature like this integrate into the shell b=
etter would be to store a captured byte stream as an integer array rather
than as an atomic variable. The back-end implementation in this case coul=
d be very efficient, and the stored data would be manipulable using exist=
ing
array syntax. The main limitation perhaps would be that one could not cre=
ate an array of these arrays.

From MAILER-DAEMON Fri Jun 09 19:35:56 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJTRc-0004W2-1F
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 19:35:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52386)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJTRa-0004Uh-Ip
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:35:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJTRX-0005YA-A0
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:35:54 -0400
Received: from a1i872.smtp2go.com ([43.228.187.104]:43878)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chris@cfajohnson.com>)
	id 1dJTRW-0005T4-Ih
	for bug-bash@gnu.org; Fri, 09 Jun 2017 19:35:51 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
	d=smtphost.com; s=a1-5;
	h=Feedback-ID:X-Smtpcorp-Track:Message-ID:Subject:To:
	From:Date:Reply-To:Sender:List-Unsubscribe;
	bh=I5IurmW2rMapxZT/nuqLBpxsQogfBcfIM9OcKI9fFF8=;
	b=MeZEsRAyq+BjyoPb88MqrqPi1C
	GR8Gpt6NPoJhbTlPzHMEXF446UVc3QQIgJtv3uABVyCtspYFCUbH8myWWo2TEiBXKRkPLwCOqyu/4
	3nXDr8IvUv1hXA+mNWBjCpnp6Zuay5QlOlLtcWmJB5MwqD6aExTKfIkMxR3miZwFN67GNYfKaA2TN
	lQzNpo68aZwD4kchweY6veRoVKDmPbBlKkmFPZsE6n+AUoc6pq2XxvTPly8ZZk4spQ2UkUZl6ffTU
	6x7JpXUFQZKuink74INHwtowR1pe+9XsJKOsP7zl4E4DKAygYYhWiBXpKKcP+lUQ0/bimiATtJCdM
	+D5xteNA==;
Date: Fri, 9 Jun 2017 19:35:25 -0400 (EDT)
From: "Chris F.A. Johnson" <chris@cfajohnson.com>
X-X-Sender: chris@cfajohnson.ca
To: L A Walsh <bash@tlinx.org>
cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
In-Reply-To: <593B26C5.6070002@tlinx.org>
Message-ID: <alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
User-Agent: Alpine 2.10 (DEB 1266 2009-07-14)
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
X-Smtpcorp-Track: 1dJTRU4gfmXE5k.O3DChbp8C
Feedback-ID: 124612m:124612a-vpTX9:124612seI8GVP1r_:SMTPCORP
X-Report-Abuse: Please forward a copy of this message, including all
	headers, to <abuse-contact@smtp2go.com>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 43.228.187.104
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 09 Jun 2017 23:35:55 -0000

On Fri, 9 Jun 2017, L A Walsh wrote:
> ----
>   First problem: If you are assigning a string to a variable,
> you need to put quotes around the string.

    You don't need to quote it unless it contains literal whitespace.

-- 
Chris F.A. Johnson, <http://cfajohnson.com>


From MAILER-DAEMON Fri Jun 09 20:30:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJUIl-0007Fu-Go
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 20:30:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57838)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJUIk-0007Fn-0A
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:30:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dJUId-0004bQ-Mj
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:30:49 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:43544
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dJUId-0004b1-7V
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:30:43 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5A0UFYP060003; Fri, 9 Jun 2017 17:30:17 -0700
Message-ID: <593B3D98.4050002@tlinx.org>
Date: Fri, 09 Jun 2017 17:30:16 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: "Chris F.A. Johnson" <chris@cfajohnson.com>
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
In-Reply-To: <alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 00:30:50 -0000



Chris F.A. Johnson wrote:
> On Fri, 9 Jun 2017, L A Walsh wrote:
>> ----
>>   First problem: If you are assigning a string to a variable,
>> you need to put quotes around the string.
>
>    You don't need to quote it unless it contains literal whitespace.
Not exactly true -- "any" type of white space, including newlines, which
was the case in Greg's example.




From MAILER-DAEMON Fri Jun 09 20:54:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJUft-0004bH-Mu
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 20:54:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60957)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJUfr-0004b3-LV
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:54:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJUfo-0004Al-K9
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:54:43 -0400
Received: from a1i872.smtp2go.com ([43.228.187.104]:57913)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chris@cfajohnson.com>)
	id 1dJUfo-000493-Cn
	for bug-bash@gnu.org; Fri, 09 Jun 2017 20:54:40 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
	d=smtphost.com; s=a1-5;
	h=Feedback-ID:X-Smtpcorp-Track:Message-ID:Subject:To:
	From:Date:Reply-To:Sender:List-Unsubscribe;
	bh=Honz2bjh/zLnp0D9bk0apggGK4HuKhOqlnnHJfP7c4w=;
	b=GRtDcoaox+eUfs4YFP5ClLq12n
	mZP6nGCo5EMGITjtwISvtjxlVj4ZkIAp1T+Ge0DMDHKUMhxhlZNU+m6OqSTK4TmQABPoat3QC68AJ
	CLKT0XYFpPQdME+7EJwOGwbPfty+JQG8vaBM8rTX86R1PnzYGAF6oMhK47MVsND7jfkmigx8RNkev
	mezTr999D0pb7CzGCTq02YyAvzuqLEmun9JyH+8wM72wfiVtL6TKDXOH4lQONu1Q1ELywgLS9uA5M
	jQ7NHcpz6lXEabeav7L3XLkKnaxvTu9pvPOBpOl5UgJIdIK8adpzqPb1i6DcqqSlxbMUAHYAnFqAu
	llFcABrw==;
Date: Fri, 9 Jun 2017 20:54:30 -0400 (EDT)
From: "Chris F.A. Johnson" <chris@cfajohnson.com>
X-X-Sender: chris@cfajohnson.ca
To: L A Walsh <bash@tlinx.org>
cc: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
In-Reply-To: <593B3D98.4050002@tlinx.org>
Message-ID: <alpine.DEB.2.10.1706092054000.10104@cfajohnson.ca>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
	<593B3D98.4050002@tlinx.org>
User-Agent: Alpine 2.10 (DEB 1266 2009-07-14)
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
X-Smtpcorp-Track: 1dJlfgmkf1PoRC.OwNK9K1F0
Feedback-ID: 124612m:124612a-vpTX9:124612seI8GVP1r_:SMTPCORP
X-Report-Abuse: Please forward a copy of this message, including all
	headers, to <abuse-contact@smtp2go.com>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 43.228.187.104
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 00:54:44 -0000

On Fri, 9 Jun 2017, L A Walsh wrote:
>
> Chris F.A. Johnson wrote:
>> On Fri, 9 Jun 2017, L A Walsh wrote:
>>> ----
>>>   First problem: If you are assigning a string to a variable,
>>> you need to put quotes around the string.
>>
>>    You don't need to quote it unless it contains literal whitespace.
> Not exactly true -- "any" type of white space, including newlines, which
> was the case in Greg's example.

    A newline IS literal whitespace.

-- 
Chris F.A. Johnson, <http://cfajohnson.com>


From MAILER-DAEMON Fri Jun 09 21:23:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJV8A-0002gs-Bj
	for mharc-bug-bash@gnu.org; Fri, 09 Jun 2017 21:23:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37547)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJV88-0002fS-7O
	for bug-bash@gnu.org; Fri, 09 Jun 2017 21:23:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chris@cfajohnson.com>) id 1dJV83-0006Cl-VJ
	for bug-bash@gnu.org; Fri, 09 Jun 2017 21:23:56 -0400
Received: from a1i872.smtp2go.com ([43.228.187.104]:43078)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chris@cfajohnson.com>)
	id 1dJV83-0006Bs-NA
	for bug-bash@gnu.org; Fri, 09 Jun 2017 21:23:51 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
	d=smtphost.com; s=a1-5;
	h=Feedback-ID:X-Smtpcorp-Track:Message-ID:Subject:To:
	From:Date:Reply-To:Sender:List-Unsubscribe;
	bh=O1xGaenxzs01sjbiP6MibFhEmjs55dfLb1YazItoKgo=;
	b=ixL5OUlAnWvNiY/AIvijjUtzu7
	ZymNUsrJPWQbWoVMQV7U49sPVa4SRQ6FATG7GCKHK06DwWGLgXmDPU/yjOn0P8zoiRwHG6Vs+/sa7
	shGI8adCk1phlPIv0Ke49nl6x/HT2RyHL6QEuxzi/tx8oh+aWzJyrkNvymp1MSCfDgfWeJV+7ekUf
	Dvk5ehViZ61T8UjJmbOPmnlq5zafxWi8gs4EO+Fu0CvzzfPRO+vBnnXQEyngQsaHzGV+pN7ExgL4V
	6qA5Z+4m++ytG6vn2tbQqZwItFB2T/NN7+fYL+0mw57ojaAmmmXHzlSeRiEfkkBEgv53WFgkBy1EV
	voL8f2Qw==;
Date: Fri, 9 Jun 2017 21:23:40 -0400 (EDT)
From: "Chris F.A. Johnson" <chris@cfajohnson.com>
X-X-Sender: chris@cfajohnson.ca
To: L A Walsh <bash@tlinx.org>
cc: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
In-Reply-To: <593B3D98.4050002@tlinx.org>
Message-ID: <alpine.DEB.2.10.1706092123080.10104@cfajohnson.ca>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
	<593B3D98.4050002@tlinx.org>
User-Agent: Alpine 2.10 (DEB 1266 2009-07-14)
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
X-Smtpcorp-Track: 1dJV7wtxokjUHs.Owoi8oR8K
Feedback-ID: 124612m:124612a-vpTX9:124612seI8GVP1r_:SMTPCORP
X-Report-Abuse: Please forward a copy of this message, including all
	headers, to <abuse-contact@smtp2go.com>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 43.228.187.104
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 01:23:57 -0000

On Fri, 9 Jun 2017, L A Walsh wrote:
>
> Chris F.A. Johnson wrote:
>> On Fri, 9 Jun 2017, L A Walsh wrote:
>>> ----
>>>   First problem: If you are assigning a string to a variable,
>>> you need to put quotes around the string.
>>
>>    You don't need to quote it unless it contains literal whitespace.
> Not exactly true -- "any" type of white space, including newlines, which
> was the case in Greg's example.

A newline IS literal whitespace.

-- 
Chris F.A. Johnson, <http://cfajohnson.com>


From MAILER-DAEMON Sat Jun 10 10:16:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJhC7-0002JX-C6
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 10:16:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57644)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <seejay.11@gmail.com>) id 1dJhC5-0002JP-Jc
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:16:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <seejay.11@gmail.com>) id 1dJhC0-0002oA-Ki
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:16:49 -0400
Received: from mail-wr0-x241.google.com ([2a00:1450:400c:c0c::241]:36322)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <seejay.11@gmail.com>) id 1dJhC0-0002nu-Dr
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:16:44 -0400
Received: by mail-wr0-x241.google.com with SMTP id e23so12507405wre.3
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 07:16:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:references:from:message-id:date:user-agent:mime-version
	:in-reply-to; bh=U2sHkdgMrY8nE74gzkR4ElIgggZ0QqQZGRwzMpiHlzE=;
	b=LUIaPO9qyKOqrOfbis33UFySpupMkGP3BlbIXUwSz4fJrM5I9yra5hMKfls/NLxOFB
	lG69t7WdhOYxyu8b9524Z/zb5fF0SR6E5NM3VYlw5rQC6soMeSkEmX3J8Ca/3UXLav10
	9zQxqOADB0OjIgqiRwG613t/+cI0LaYDnTRYvWzXxsHfmrGgBpBxOLQT6wB6hNzYd3R/
	gOMeaAcZQ9MoUxjL9qDDXBzrm680K2jJXNLR0S7e3+WYsp8L72P4SEydijp5q0nk56EX
	JK3sE2e0iHwscIlhAHzJjqcEVlT+2cIHetBapqKrjueOy0HB8oLSDFa6B0CInFVido8A
	mIKg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:references:from:message-id:date
	:user-agent:mime-version:in-reply-to;
	bh=U2sHkdgMrY8nE74gzkR4ElIgggZ0QqQZGRwzMpiHlzE=;
	b=UzWpGND4ehR0XqRkGwtLbh21a/bYRKk4OJ/9tureoXdrQAED68ZifZlpWuJMjr7dYQ
	6al1CwtZKFSCvJuVDzHlR0PS112vSLe8fyuAX42jCJ0HL24ql3W0WFWu0jKEDu5pfk2D
	JA0L8PKHVbHwocXZ2ApcmKul+UUOPqkoWhwLHJlXHK2QHpN6tirVUxG5/Y1Zr3GKfn12
	S8RgIn9OY+b7oc1C1rfMeewZdSgHtCoWj06GfrqF7Fl3X0Iv8DhqHdmnejuvv5EQXl/u
	DynmjZAX22TjPdeDWHzfwRLhnZpGj+snruwmXamw6Y4V/sM8rOwfANu/NO4mb/yhK18J
	Nqtg==
X-Gm-Message-State: AODbwcCkjsGs6PvsLblFtiufZDaQwmjIzWdLj/pbKN8hbSAfqfa10jYu
	zmX6+jmEMJnAH2MXWkU=
X-Received: by 10.80.147.133 with SMTP id o5mr37459543eda.112.1497104201479;
	Sat, 10 Jun 2017 07:16:41 -0700 (PDT)
Received: from [192.168.1.2] (94.133.93.209.dyn.plus.net. [209.93.133.94])
	by smtp.gmail.com with ESMTPSA id
	z44sm2283680edz.57.2017.06.10.07.16.40 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Sat, 10 Jun 2017 07:16:40 -0700 (PDT)
Subject: Re: consistency probs var & function re-use
To: bug-bash@gnu.org
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
From: Charles Daffern <seejay.11@gmail.com>
Message-ID: <4acada15-9482-e024-d8f6-de431fb8da58@gmail.com>
Date: Sat, 10 Jun 2017 15:16:27 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
	Thunderbird/45.8.0
MIME-Version: 1.0
In-Reply-To: <593B26C5.6070002@tlinx.org>
Content-Type: multipart/signed; micalg=pgp-sha256;
	protocol="application/pgp-signature";
	boundary="RJfD7NTsPuVhwgDp92uiJupeXpLbkrngF"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::241
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 14:16:50 -0000

This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--RJfD7NTsPuVhwgDp92uiJupeXpLbkrngF
From: Charles Daffern <seejay.11@gmail.com>
To: bug-bash@gnu.org
Message-ID: <4acada15-9482-e024-d8f6-de431fb8da58@gmail.com>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
 <20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
In-Reply-To: <593B26C5.6070002@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

>    First problem: If you are assigning a string to a variable,
> you need to put quotes around the string.  That shows that "-p"
> doesn't insert newlines:
>=20
>  > x=3D"$'foo\nbar'"
>  > declare -p x
>  declare -- x=3D"\$'foo\\nbar'"

You do not have any newlines in that string, so of course the
demonstration with -p will show no newlines.

>> What are you trying to do?=20
> Read var & func defs via a 'read' of 1 line.

In your variable "x" above, you have encoded the string in a format
which contains no raw newlines and which can be "eval"ed to produce the
original contents.
Why don't you encode the function the same way?



--RJfD7NTsPuVhwgDp92uiJupeXpLbkrngF
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQJIBAEBCAAyFiEEr2wXDlnoJ2Vo3VOaKwKpjZm7NoMFAlk7/zsUHHNlZWpheS4x
MUBnbWFpbC5jb20ACgkQKwKpjZm7NoNAHg/9F6vMdwzTdCxWheP2PGNhZp2nI76+
iP38vZObbIrqdpWAQZHOeTcX54Z9ywJEr53Fu+Swf1qHczyXdHqYMviWNVNErpmX
LrxJ5hChLo5A2XNe2Nt/vhhU1P5zxruPT+W7As2UnnsEqBJIEVbvK3V9nZGA5zO+
DR5cZdvH2AeYVjVzAz+CpkEVM8phMHCRWy93Io78RuPurHifF6DpdZ+szTAuc9ed
ci5nshEvKM1oc2HbAjkNHqb0UeT692I7je0xZRMXAfR4y1oIeFdgVnCO2Rc9yeax
ykoXKJ3XdMxlShrofEqCP8prxUYjbLj5dPqVqf/gr6Y1e/buff0tOYr5m+qz0bas
yK917RakEgUvwF9yQVS19DKdGK0/3BXp5u7jQYvxNmaWKfI6azEVx/hMeD6jy5OB
M0LInk5GFYKeRUL9pBZSciAXcxSXVb97nvgmY1B0KgSVuX+f7bLTjmD9FNZ3s+W9
RvvmLwbrg1vrJyWkfLPxQf1ERgxnX2ikw7csYmfcWZyKBHUL7/MAX3f7013mgLii
+4WdAYPvJJwzEXISkCf8h7CSF33e0AXoZ1wYTs9XkgbaUb2pgtHqzORGsoVnfTNZ
crpmN6qtLOfVM92RHrrRxPil8wynzZ3kaPLEwF8srNpskuXPV5IVoqg1gDkv4gcH
PmzKaEIbXkTh4Mk=
=cCCW
-----END PGP SIGNATURE-----

--RJfD7NTsPuVhwgDp92uiJupeXpLbkrngF--


From MAILER-DAEMON Sat Jun 10 10:19:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJhEx-0003A4-OU
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 10:19:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57844)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dJhEv-00039n-Vk
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:19:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dJhEv-0003Ge-5K
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:19:45 -0400
Received: from mail-pf0-x232.google.com ([2607:f8b0:400e:c00::232]:36399)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dJhEu-0003GC-Va
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:19:45 -0400
Received: by mail-pf0-x232.google.com with SMTP id x63so37321130pff.3
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 07:19:43 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:from:date:message-id:subject:to;
	bh=KNc2qq8yfVx8TJKVYXqtZBuEMs771P0uIalf1OhrT/M=;
	b=dU092zlvBfuoNv5mqupKvBxtTFD7Cvvi1Ak5w23h0ttCBrD+VlPJ+/nWXl8XQL0YBO
	Idog+2KDWx3w1Q4zHhkuB5xcGzo/mdr5bNVZCOPi5fQzDbZq4sMlOxeBTWfxtfL3lIIJ
	6QGCGK9etYep2TyXyE+qOh0OOyDBtUOQQXaPktOg6zXiHcFRuuvUSB8WYoKmMJfQa2AE
	DCHZlIS7pWSDGGDlQotNhf+h4b5IFUmrKrlimH5fr8vz1XUK5L2VlmQ+63AN7+L8LVan
	zMZmBfPFWjz3NQUCDJFdkjdMBv4wdXxR4GFxnE+mLEpKO2f6+q8g+whjqDpW06ZelXqP
	Vmcg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
	bh=KNc2qq8yfVx8TJKVYXqtZBuEMs771P0uIalf1OhrT/M=;
	b=nas1U2M4pbcbnJ3A/LguBcM63f8gR+NE5+attrdXw1Rn8T8lDO4GWcJc+d6tbbMuCM
	pqZOkIg7uLM8UOo0C3hUYti+MPIUex8cAGrV8rTrdr2llYjDJRXdGVpI9Si6cenEWLyD
	vJtFABRE6EYoqwbLNA9Tvcr5o74J/MA6YZINqFlCE9/LKXmdJxvBU2HozlYgA+R7p04c
	lKzS+uUY003ereE0NbQ3mtmZyvW1yJ3gAOPcYvxjkpI7cC399qdqkb8Ka29vqs1urrp/
	I9qGvdhuRgeHRM+hpATBCrwEt0SPnZmBSLDeFKSntpgYa/PZDpQQC01/30i8jcK0aGAc
	WLlw==
X-Gm-Message-State: AODbwcC/3TEigkHSIuvrgp6zzrry4ZMfY2aENu0KKoJrCmpvA99VH+NF
	QMAu6R6RXU68TzmLqprMvFS7vr6/yr+8
X-Received: by 10.84.224.205 with SMTP id k13mr46963939pln.279.1497104382378; 
	Sat, 10 Jun 2017 07:19:42 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.153.219 with HTTP; Sat, 10 Jun 2017 07:19:02 -0700 (PDT)
From: Clark Wang <dearvoid@gmail.com>
Date: Sat, 10 Jun 2017 22:19:02 +0800
Message-ID: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
Subject: A background ssh can take over the tty from bash?
To: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::232
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 14:19:47 -0000

(I'm using bash 4.4.12 on Debian 8)

Please follow the following steps to reproduce.

>From tty #1:

$ tty
/dev/pts/11
$ ssh -o ControlMaster=yes -o ControlPath=/tmp/socket.tmp -N -f 127.0.0.1
root@127.0.0.1's password:
$ ps -C ssh uw
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root       716  0.0  0.2  44428   692 ?        Ss   22:04   0:00 ssh -o
ControlMaster=yes -o ControlPath=/tmp/socket.tmp -N -f 127.0
$
$ ssh -o ControlMaster=no -o ControlPath=/tmp/socket.tmp 127.0.0.1 sleep
9999 &
[1] 725
$    <-- Then I cannot input anything except CTRL-C

Go to tty #2:

$ ps t pts/11 jw
 PPID   PID  PGID   SID TTY      TPGID STAT   UID   TIME COMMAND
32714   725   725 32714 pts/11   32714 S        0   0:00 ssh -o
ControlMaster=no -o ControlPath=/tmp/socket.tmp 127.0.0.1 sleep 9999
  579 32714 32714 32714 pts/11   32714 Ss+      0   0:00 bash
$

If I kill the "ssh -o ControlMaster=no -o ControlPath=/tmp/socket.tmp
127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my input
again. Seems like the background "ssh" at tty #1 is consuming all input. I
cannot understand this since it should be stopped by SIGTTIN if it tries to
read from the tty.

Idea?

-clark

From MAILER-DAEMON Sat Jun 10 11:00:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJhso-000436-Tq
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 11:00:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36026)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dJhsm-00041S-4B
	for bug-bash@gnu.org; Sat, 10 Jun 2017 11:00:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <john.archie.mckown@gmail.com>) id 1dJhsk-0001UH-V8
	for bug-bash@gnu.org; Sat, 10 Jun 2017 11:00:56 -0400
Received: from mail-pf0-x232.google.com ([2607:f8b0:400e:c00::232]:34033)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <john.archie.mckown@gmail.com>)
	id 1dJhsk-0001Tt-K5
	for bug-bash@gnu.org; Sat, 10 Jun 2017 11:00:54 -0400
Received: by mail-pf0-x232.google.com with SMTP id 15so9966842pfc.1
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 08:00:52 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=++rBHi170/yP03craNfSzRf2nKH2j86hXDqUzbB7ZyQ=;
	b=W/fA3T420EE4DmJBpE+wOcxNmISp150eW/sIYGhylJLY7UzDdLfkMR7rFnPJuTRljL
	Egfyr927h6uyngX5pYa/4iE54Ueg1FP4SnTNrT9VxNh/1GpWBGAPuPD/I3XN3cb5RFKl
	ANSvA7RMOez1WHSQVjNBQWyGbZgNhz/vJFxL+atZddUrbEjdWUyueB417j8VthNyHuZv
	Nday0yRYHXoRDXK8oeD/ousUwkc+3eZ43AgAQBw2MUWIsAdS6yIQqa4TUMaMFolU8s0l
	j7cBd55io7OG0ZbYDEbpIbCjdIJFBY238+Kp7Zp+qr1o+AGqV5qjHTGMwrKfnkPCylqU
	oypQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=++rBHi170/yP03craNfSzRf2nKH2j86hXDqUzbB7ZyQ=;
	b=HlnQMjyvKWVgTZ4nNW3dpcrsVoEJZ2MtG1VCUXUl1DtKju8rLbaED+QhDrn9jU5OUC
	rOXtGEp/asYsug4/Qo+A6XKX9s7ufeZByao9v9njIfFvgBIUePo4zkRZAr5Hv3aqOt8R
	RIJ98VTwZEmrAsVyFifgYsEDlyeyHCVKcStACfihCJbJAcBsjF49hIJ6ODPztbIclTzq
	4BqGcp3OLocA3JEFofvgONXPgOlCkQvtVA4ocW+1b6eVkDi1qKGsfKOyhwU8/2656CMH
	NqSL4FL/ASbPbz54wLVp41Ani5h9lxPtMSxlDtA54GjNscHYKIsj9N31xo5HmdZi15Tf
	gRVw==
X-Gm-Message-State: AODbwcCfRJAeoUVnrGVUg8+6dy/rE4tceNgIVH67C+BHKitesoeWx5dr
	SsyxAOE5l4xZbL7cif23GwnNRWSXpw==
X-Received: by 10.84.217.89 with SMTP id e25mr46715062plj.275.1497106851820;
	Sat, 10 Jun 2017 08:00:51 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.178.107 with HTTP; Sat, 10 Jun 2017 08:00:51 -0700 (PDT)
In-Reply-To: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
From: John McKown <john.archie.mckown@gmail.com>
Date: Sat, 10 Jun 2017 10:00:51 -0500
Message-ID: <CAAJSdjg5YBq42q2HBMqTJvcDYoJMAz4xoou7hq_cJe9r=UPG8A@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: Clark Wang <dearvoid@gmail.com>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::232
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 15:00:57 -0000

On Sat, Jun 10, 2017 at 9:19 AM, Clark Wang <dearvoid@gmail.com> wrote:

> (I'm using bash 4.4.12 on Debian 8)
>
> Please follow the following steps to reproduce.
>
> From tty #1:
>
> $ tty
> /dev/pts/11
> $ ssh -o ControlMaster=3Dyes -o ControlPath=3D/tmp/socket.tmp -N -f 127.0=
.0.1
> root@127.0.0.1's password:
> $ ps -C ssh uw
> USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
> root       716  0.0  0.2  44428   692 ?        Ss   22:04   0:00 ssh -o
> ControlMaster=3Dyes -o ControlPath=3D/tmp/socket.tmp -N -f 127.0
> $
> $
> =E2=80=8B=E2=80=8B
> ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 slee=
p
> 9999 &
> [1] 725
> $    <-- Then I cannot input anything except CTRL-C
>
> Go to tty #2:
>
> $ ps t pts/11 jw
>  PPID   PID  PGID   SID TTY      TPGID STAT   UID   TIME COMMAND
> 32714   725   725 32714 pts/11   32714 S        0   0:00 ssh -o
> ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 sleep 9999
>   579 32714 32714 32714 pts/11   32714 Ss+      0   0:00 bash
> $
>
> If I kill the "ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp
> 127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my inp=
ut
> again. Seems like the background "ssh" at tty #1 is consuming all input. =
I
> cannot understand this since it should be stopped by SIGTTIN if it tries =
to
> read from the tty.
>
> Idea?
>
> -clark
>

=E2=80=8BIMO, not a bug in BASH, so this is the wrong forum. But, since I'm=
 already
blathering on, I'd say the problem is that you have invoked "ssh"
incorrectly.=E2=80=8B In particular, ssh _does_ read from stdin normally. B=
ut, from
the man page:

 -f      Requests ssh to go to background just before command execution.
This is useful if ssh is going to ask for passwords
             or passphrases, but the user wants it in the background.  This
implies -n.  The recommended way to start X11 programs
             at a remote site is with something like ssh -f host xterm.

             If the ExitOnForwardFailure configuration option is set to
=E2=80=9Cyes=E2=80=9D, then a client started with -f will wait for all
             remote port forwards to be successfully established before
placing itself in the background.


So instead of:

=E2=80=8B
ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 sleep =
9999
&

Try:

=E2=80=8B
ssh -f -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 sle=
ep
9999

--=20
Windows. A funny name for a operating system that doesn't let you see
anything.

Maranatha! <><
John McKown

From MAILER-DAEMON Sat Jun 10 12:13:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJj1N-0006gd-R6
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:13:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34999)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJhod-00036Q-38
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:56:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJhoc-0007XO-4P
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:56:39 -0400
Received: from mail-wr0-x230.google.com ([2a00:1450:400c:c0c::230]:35414)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dJhob-0007WV-Uc
	for bug-bash@gnu.org; Sat, 10 Jun 2017 10:56:38 -0400
Received: by mail-wr0-x230.google.com with SMTP id q97so57753519wrb.2
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 07:56:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:from:date:message-id:subject:to;
	bh=76m1RNv0q5n5CVSB0RrEF0oYoOtV0FxQ4q9ecegidnM=;
	b=sKYVV+Er2gQyOmRkF0nJf5Cg4KSEJXIGr2cqMNYkevjJcbNhTDIC2MSLsAzxAvVZfg
	aw42EmrBjHj6GW6bWCoJhLYLHm7F3qLsXZkqgpUnCGbXaQYOSms+j/WZDRv10vw3KVHb
	ywALnUJuqdJiM8P9WO+lhMtPgAiv96qDIucFiM/otGUJ5Eu9gSriLspC4dVKyccS8kHF
	wqeBwoOITsDnL7O7Ji3hAMbVH6vl2t1D8RVHSGmZos9EpaLMMJGT+lk/vF5a81YQzqXx
	4g7nlf7NXN7CGop+JtM+GIJeeW8hYXaslnbQeemekvuS8Z04P9sSJOPT3BI41/N+EJqa
	nr4g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
	bh=76m1RNv0q5n5CVSB0RrEF0oYoOtV0FxQ4q9ecegidnM=;
	b=dVCvV0SCWiErjB8JKMwTFtpVxe+nRSIaZ9+Qh7k5h6yhQvGrXulU8MJ2QmV5X2dfpk
	wxNdia262/iQGzIlxSSSHNWdawesVPQiXmxVgPWi/Mwu6EPPQUbHFh16tmq7Z1Trz5ob
	+NWRDrkPXdccZtW673MPmTjZG9E/EjJ5xfMwoq29whZWY4u45ow2s50LIIOkxFhO6lt+
	DUjAX9dfQSIrwHT/4kgpU3JC6IwkmyxBVJOh6xSU26OfHXxsrldJxHb6JELT+sAT2hjR
	ExChLosksydoho/Nf4qQkD/rEALWnYr1/cxJjEO7PGXJlF59N05b8GMGizGnj4l15Fkv
	yfVg==
X-Gm-Message-State: AODbwcDNDVCxx3CPmz4OVchdFEWKo8GEmkaezEngLgLhQEOOthDc54Cn
	ZFoFHfjQQkDwHQ3wyNGUyEKcz8kKiUQj
X-Received: by 10.223.142.150 with SMTP id q22mr2404917wrb.180.1497106596034; 
	Sat, 10 Jun 2017 07:56:36 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Sat, 10 Jun 2017 07:56:35 -0700 (PDT)
From: Paul Peet <peetpaul69@gmail.com>
Date: Sat, 10 Jun 2017 16:56:35 +0200
Message-ID: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
Subject: Buffer corruption when the terminal is resized.
To: bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::230
X-Mailman-Approved-At: Sat, 10 Jun 2017 12:13:51 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 14:56:40 -0000

I would like to report a bug with bash (readline?). This bug can be
reproduced by opening gnome-terminal with bash running. By quickly
horizontally resizing the terminal window you can see that the buffer
seems to be corrupted as you see repeated or even removed lines or
characters.

At first I thought this might be an issue with gnome-terminal/vte but
this also happens with xterm so the conclusion was that it might be
bash/readline's fault.

This can be reproduced on stock Ubuntu 17.04.

Bash version: 4.4.7(1)-release (x86_64-pc-linux-gnu)
System: Linux 4.10.0-22-generic #24-Ubuntu SMP Mon May 22 17:43:20 UTC
2017 x86_64 x86_64

I've also uploaded a gif which shows this behavior:
https://media.giphy.com/media/3ohze1ynhK8ZDGmpq0/giphy.gif


From MAILER-DAEMON Sat Jun 10 12:20:27 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJj7j-00087X-2e
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:20:27 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48649)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJj7g-00087L-2q
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:20:25 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJj7b-00042v-5M
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:20:24 -0400
Received: from mail-ot0-x22b.google.com ([2607:f8b0:4003:c0f::22b]:33597)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dJj7a-00042q-WB
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:20:19 -0400
Received: by mail-ot0-x22b.google.com with SMTP id k4so50949169otd.0
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 09:20:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=Fiehdd/BB2Q6aH7n+YfB5943xtaLuc9hP1qR4jFLeS8=;
	b=JKyZ1b2pYbUoHCsNt0IAh8rKNKCiks0kV0Rat+VbGBmY/5k+IcDX/PhS4nrh6Rt5NP
	1KjF4MtuLnMClGdKddTU3RNyLB5mzc+c5jHWxckTaAZsMMipVG20ROPdv9p35Y7NMUzR
	GFJrSZqep1zCZHns/jOcniSjNnop+1QQr5Xvf5EUBBdAHLsbZQpo0VysiNBpJYIGaU7F
	Nslv7pMRCG+ZqviImAJia3PqpIetKgMStDIG4Cc4orO91S8uplqDSY+m2OiEuXlskBXR
	M1IcBUfMBrHrTpMnWwnhYoDW87taNsAxfWsEjj5Hw562h2r0luIEGuba+lXbXDo8sxBL
	VfVQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=Fiehdd/BB2Q6aH7n+YfB5943xtaLuc9hP1qR4jFLeS8=;
	b=QX7aR1JgX1bf2qJ5j9pvh2uOsAVJbtSMbzZKHHpls0USOfR27n+w4jrWJkJPtl/GH6
	MM4YJbG/Jp6oInT+mqMOi3O3Z8fZqjbhtzm0ZrH3M9bk1K0qJeoZ0zD0T6W1jakwiu1b
	6FbEqL1ZzndGuZeBm1wfZKrc4Z8HM1Ip/9swrRu77a0HiMitTdF8mbpxZp5/LpYu/cHV
	FrRZCW/MTVTkHfd5b5Dl8uvzqy4NxPe68pLfrtMFVcQ9Fo/kozxUQI6Ihfzka5ZbCpvJ
	5RRtvLyzCE7NpgTtlUWRQdOOS55BXAU4UeiLX3/MnaP6zTsbt9ylKnV7NBswlsur8v3J
	F26A==
X-Gm-Message-State: AODbwcCFUg+/T9476w0480ZuHFw0veGG3O/c4q9ri/Y5bsRbv9SSr+Ou
	ksIFKOxeqtywLA==
X-Received: by 10.157.31.21 with SMTP id x21mr24557206otd.162.1497111618196;
	Sat, 10 Jun 2017 09:20:18 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id 36sm1047762otr.44.2017.06.10.09.20.17
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 10 Jun 2017 09:20:17 -0700 (PDT)
Date: Sat, 10 Jun 2017 11:20:16 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Paul Peet <peetpaul69@gmail.com>
Cc: bug-bash@gnu.org
Subject: Re: Buffer corruption when the terminal is resized.
Message-ID: <20170610162016.lcc2r2eggqd2qd4w@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22b
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 16:20:25 -0000

On Sat, Jun 10, 2017 at 04:56:35PM +0200, Paul Peet wrote:
> I would like to report a bug with bash (readline?). This bug can be
> reproduced by opening gnome-terminal with bash running. By quickly
> horizontally resizing the terminal window you can see that the buffer
> seems to be corrupted as you see repeated or even removed lines or
> characters.

What's the value of your PS1? (use: declare -p PS1)

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 10 12:33:36 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJjKR-0001xL-Vo
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:33:36 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52487)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dJjKP-0001vb-5D
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:33:34 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dJjKN-0000JB-CY
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:33:33 -0400
Received: from mail-qk0-x230.google.com ([2607:f8b0:400d:c09::230]:35311)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <pierre.gaston@gmail.com>)
	id 1dJjKN-0000J5-6b
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:33:31 -0400
Received: by mail-qk0-x230.google.com with SMTP id a199so14499365qkb.2
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 09:33:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=JQv/CBZdS2bkOhdZZoO9RKYGh43+5zN7mgdKnDp7gJA=;
	b=uweO2BeXUHOzvJvcQVLtbnAWGprmogbxdlbatnOpwwK+3m5/fL/Hwrj3o3vKk6sq9t
	GIMXArsIRc1xrUgncM2hDO93ByYuOcV3w9OLBda9FIqBYGg5kM6t1QTLWiv0wmMB3KbX
	kTBK7qD7JZNxkctgHPssOt3WQypYTb+YB6B/loCkPQiLvhLRh0QxgtivBtNopdeJQLcy
	C4JNyRlRmkHvIdwVhXnq/SYW+jllHRn0+yF4dk3Zo8ux0v6KNnXSG1RrV7wI2LcBzZyz
	Rt5jbsMQUfrQLHoEKrtsUOPdUJL3sR4yYsX5dP4wpAHyLJJkRbg4qmTh4rE8MiUTFlb+
	Ttbg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=JQv/CBZdS2bkOhdZZoO9RKYGh43+5zN7mgdKnDp7gJA=;
	b=CGt7gwvwOhL49OX8mfYA85K/P5jq8nLeF3E3pAGWLQktWhwchc5TD1vpbTwiK3CF8u
	cXHoyjRZPMQFLr5o+VQWCjDMJ/Dr5U+m4JpwVt3ESXfLG0OECz/VcnnI4lXzGcyCcm8x
	HTkpfAIZgTb/KhOvSsnu7d2EX6D/bmoTh/R/IdlNbInQaKcp9hX5J/q1FgEiCiChiqg0
	1g6TMHRbhJYRLra2NW6xYJhbvGhYPXAGSqLZbC+cqO+qVwBRCw62JwcgeUaei/PAYYGL
	oLoH5spgqhmz6RE2S5OW76yoqd4cNYe9PMR5+dPe1rqB5mqQSvU4kieKwa2X8lmCKWY6
	UqKA==
X-Gm-Message-State: AODbwcDEAo9WQOQFMgxJOIM4wSkDkyXeTo3gZg4lxfQN/qf968mbNGmL
	T/HwXSNGcRA7sTKElxHkQZ6EL4JFzw==
X-Received: by 10.55.165.81 with SMTP id o78mr48295933qke.229.1497112410621;
	Sat, 10 Jun 2017 09:33:30 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.160.166 with HTTP; Sat, 10 Jun 2017 09:33:10 -0700 (PDT)
In-Reply-To: <1497049577.17253.408.camel@scope-eye.net>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
	<1497049577.17253.408.camel@scope-eye.net>
From: Pierre Gaston <pierre.gaston@gmail.com>
Date: Sat, 10 Jun 2017 19:33:10 +0300
Message-ID: <CAPSX3sThFtact3nP4jQx_rvAtxh0RXy2xsRkipaAnpGCu59oRw@mail.gmail.com>
Subject: Re: Storing NUL in variables
To: George <tetsujin@scope-eye.net>
Cc: "Peter & Kelly Passchier" <peterkelly@passchier.net>,
	"bug-bash@gnu.org" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::230
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 16:33:35 -0000

On Sat, Jun 10, 2017 at 2:06 AM, George <tetsujin@scope-eye.net> wrote:

> On Fri, 2017-06-09 at 20:58 +0300, Pierre Gaston wrote:
>
> On Fri, Jun 9, 2017 at 8:40 PM, Peter & Kelly Passchier <peterkelly@passchier.net> wrote:
>
>
>
> On 09/06/2560 23:38, L A Walsh wrote:
>
>
> Chet Ramey wrote:
>
>
>
>  Should mapfile silently drop the NULs?
>
>
>
> Maybe add a flag to ignore NUL bytes that could be used in the 'read'
> statement as well?  If not specified, keep same behavior?
>
>
>
> That sounds like it might be useful.
> It might be more desirable to change it to a newline instead of dropping
> it? (Or both, with different flags??)
>
>
>
>
> I feel this kind of magic behavior would result in hackish scripts or fill
> a somewhat rare niche at best.
> I'd rather have bash to fully handle arrays of byte, or nothing.
>
>
>
> I think allowing shell variables to contain NUL would be lovely. How about
> we make that happen?  :)
> (I would be up for writing a patch to do it, of course, though I have a
> few other things in the pipeline... A feature like this could take a fair
> bit of work depending on how far the implementation goes in supporting
> various things.)
>
> Of course such variables couldn't be exported (the NULs would be lost if
> the data were stored in an environment variable) and for compatibility,
> variables should probably support containment of NULs only if the caller
> specifically requests it with an argument to "declare" or "read".
>
> ...And then there is the problem of how to use such variables. They can't
> be exported as environment variables or passed as command arguments, or
> used as file names...  Essentially they'd be limited to use in I/O within
> the shell, and within a handful of built-in commands or shell functions
> equipped to properly handle that data.
>
> I think that this approach, capturing an arbitrary byte stream and then
> taking further actions to process or encode it, is preferable to the
> alternative of capturing the byte stream and simultaneously encoding it
> into a text format. In principle commands like "read" shouldn't transform
> the data they're given, they should just store it. (I think the fact that
> read requires the option "-r" to read data without transforming it is kind
> of unfortunate...)
>
> (That said, one could argue that it would be equally reasonable, or even
> more reasonable to implement an operation that simultaneously reads and
> encodes the data, and another that decodes the data and writes it out, and
> then any commands designed to perform operations on byte stream data in the
> shell (re-encode it in a different format, etc.) should simply use that
> first encoding as a common format for exchanging the data..  Given the
> limitations of the shell with respect to its ability to handle NUL in
> various contexts, I think it's a reasonable argument. I tend to prefer the
> idea of providing true shell support for capturing a byte stream because it
> makes it easier to write code that handles the data without having to
> build-in a parser to interpret the data first.)
>
> One option that might make a feature like this integrate into the shell
> better would be to store a captured byte stream as an integer array rather
> than as an atomic variable. The back-end implementation in this case could
> be very efficient, and the stored data would be manipulable using existing
> array syntax. The main limitation perhaps would be that one could not
> create an array of these arrays.
>

Without too much thinking about it, I'd  propose something like this:

- extend readarray (or maybe provide another builtin)  to read bytes with
an interface like the one of dd (block size, offset, skip) and store the
bytes in the array. eg:  readarray -b bs=1024 cs=100 byte_array <file

- provide another builtin to write the array to a fd, eg "write bs=1024
cs=100 byte_array" (I don't really see a good way to extend printf or echo
for this)

-  setting an array directly would store the bytes eg a[0]=0 would put a
null bye at the first index

-  conversely ${a[0]} would expend to "0"

- I think the current array could even be use, but that would not be very
efficient, and there is the question of what to do with sparse arrays

- I think I would like some efficient way to copy range of bytes from one
array to the other, maybe this could be done reusing the above "write
builtin" like: write offset=100 seek=50 -v dest_array -s source array


I think that could even been done with loadables builtins, making all the
byte arrays "special_variables"

My 2 cents....of course I probably should have checked what zsh does as I
think it supports nullbytes in variable.
Pierre

From MAILER-DAEMON Sat Jun 10 12:47:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJjXw-0004WR-EX
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:47:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54603)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJjXu-0004W4-7K
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:47:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJjXr-0004qp-4g
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:47:30 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:36475
	helo=homiemail-a58.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dJjXq-0004qE-Qr
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:47:27 -0400
Received: from homiemail-a58.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a58.g.dreamhost.com (Postfix) with ESMTP id 9B508600440C; 
	Sat, 10 Jun 2017 09:47:23 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=r1rKaydccf3Z0fCn
	MBFeNOE6HnQ=; b=y9UJp27nPtE8RGnTHYxbGgid9c9u+mkn0JIHh1ZyyBzJg2nc
	/gC05xsa0nkZ6PMJ6FOvYdVpPxZrIUt8xsG3gln6W2wzCXbFJDYtrXktTM4iNIrJ
	gDVENIEfMQWruoN/2tHcus5a4r4EWmEwQllldzGutNDTD85zTn//WcxUkk0=
Received: from frontier (unknown [76.191.34.78])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a58.g.dreamhost.com (Postfix) with ESMTPSA id 3233D6004406;
	Sat, 10 Jun 2017 09:47:23 -0700 (PDT)
Message-ID: <1497113241.17253.415.camel@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
From: George <tetsujin@scope-eye.net>
To: Eduardo Bustamante <dualbus@gmail.com>, Paul Peet <peetpaul69@gmail.com>
Cc: bug-bash@gnu.org
Date: Sat, 10 Jun 2017 12:47:21 -0400
In-Reply-To: <20170610162016.lcc2r2eggqd2qd4w@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 16:47:31 -0000

On Sat, 2017-06-10 at 11:20 -0500, Eduardo Bustamante wrote:
> On Sat, Jun 10, 2017 at 04:56:35PM +0200, Paul Peet wrote:
> >=20
> > I would like to report a bug with bash (readline?). This bug can be
> > reproduced by opening gnome-terminal with bash running. By quickly
> > horizontally resizing the terminal window you can see that the buffer
> > seems to be corrupted as you see repeated or even removed lines or
> > characters.
> What's the value of your PS1? (use: declare -p PS1)
>=20
It's actually shown in his video link... =C2=A0Looks like at the start of=
 PS1 he has \[ and \] surrounding escape characters rather than the whole=
 escape
sequence:
\[\e\]0;
Rather than:
\[\e0;\]
Bash relies on \[ and \] to determine how much space is occupied by the p=
rompt when it is to be redrawn, so in this case it thinks the prompt is 2
columns wider than it actually is.

From MAILER-DAEMON Sat Jun 10 12:49:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJjZd-0005Mc-T0
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:49:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55804)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJjZb-0005MA-OQ
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:49:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJjZb-00061W-1Z
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:49:15 -0400
Received: from mail-wr0-x22c.google.com ([2a00:1450:400c:c0c::22c]:33221)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dJjZa-00060x-R1
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:49:14 -0400
Received: by mail-wr0-x22c.google.com with SMTP id v104so58915210wrb.0
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 09:49:14 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=oXx010391s5kgs+ZpwXwMD06EXZQpo7M5PdzpuTlxcM=;
	b=PNmOu2dL96LVwNYjLfpnyeNQqC8i6fRtglCeXoZImU3f9/hJVeBQcH0U01GtMI3mq0
	O9LLiMQQs+yc2m/xxC1Z+CjHZ49YELiQuOTZY5CkqCfHGGAOe/vS3AaVF1jSK11Wgjnd
	kS0fb21XkeOU+6laLnc6ap6TcRMYtmPrOTi5E0qG+r9BpFtpjpXpInV2xbdaBYQM+F8o
	TkZ+EzxpYk2KHOS+0oj145yy0QQG71sI1KyRaFCMY2NRj4zqkSAjZgDRDRYbc33h+G+Y
	FQmYtAI6EK9oGCEXcK7JhkY4zijs/K2mOYV2S1UTOr0q6+ICr08PMbphOp8HeeDfhIpX
	K3bw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=oXx010391s5kgs+ZpwXwMD06EXZQpo7M5PdzpuTlxcM=;
	b=Q1xpZwGzsupXyR27oevZGmI6ng84O8uR9aiiKB8LfhfwnOgrdKDh13yj3Wrxl/XQCd
	JSO8cEj16PIQbuRHL6n0TpokgkcTrx0AKKkpbFz3rcuwoFpeJtm/lYP9MfYxYwjHEUCk
	FKhzubvkO54GyCTBP+Xm0SCl/3f4965Sai+fixn7P32ZhM0tdHwpSXM31iqmbz/NX0Ji
	nSWCNc+6W41qPL/fTAEVEBGrGh4+e+nGeG1e2WsSoMwK6/c0+8H0tb1KT8+ibUfo9gCg
	6ToMnvzNs14UnzVDa2N3C14NmA+7uaEuSUtd9SGvn5iWNmrJWU7hg4YOKc+B1Oa28Hdz
	OgQQ==
X-Gm-Message-State: AODbwcByhOUvBR2QgkZe1lsEsGa1QHdadNtcXAy0mbVtQPVOCeiJgatr
	52ALaTmtfSacxblGQQGXxyesT+1w2Q==
X-Received: by 10.28.170.193 with SMTP id t184mr3237055wme.124.1497113353721; 
	Sat, 10 Jun 2017 09:49:13 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Sat, 10 Jun 2017 09:49:13 -0700 (PDT)
In-Reply-To: <1497113241.17253.415.camel@scope-eye.net>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
From: Paul Peet <peetpaul69@gmail.com>
Date: Sat, 10 Jun 2017 18:49:13 +0200
Message-ID: <CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: George <tetsujin@scope-eye.net>
Cc: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22c
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 16:49:16 -0000

declare -- PS1="\\[\\e]0;\\u@\\h:
\\w\\a\\]\${debian_chroot:+(\$debian_chroot)}\\[\\033[01;32m\\]\\u@\\h\\[\\033[00m\\]:\\[\\033[01;34m\\]\\w\\[\\033[00m\\]\\\$
"


On Sat, Jun 10, 2017 at 6:47 PM, George <tetsujin@scope-eye.net> wrote:
> On Sat, 2017-06-10 at 11:20 -0500, Eduardo Bustamante wrote:
>
> On Sat, Jun 10, 2017 at 04:56:35PM +0200, Paul Peet wrote:
>
> I would like to report a bug with bash (readline?). This bug can be
> reproduced by opening gnome-terminal with bash running. By quickly
> horizontally resizing the terminal window you can see that the buffer
> seems to be corrupted as you see repeated or even removed lines or
> characters.
>
>
> What's the value of your PS1? (use: declare -p PS1)
>
> It's actually shown in his video link...  Looks like at the start of PS1 he
> has \[ and \] surrounding escape characters rather than the whole escape
> sequence:
>
> \[\e\]0;
>
> Rather than:
>
> \[\e0;\]
>
> Bash relies on \[ and \] to determine how much space is occupied by the
> prompt when it is to be redrawn, so in this case it thinks the prompt is 2
> columns wider than it actually is.


From MAILER-DAEMON Sat Jun 10 12:58:10 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJjiE-0007FN-Qg
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 12:58:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58181)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJjiD-0007FF-8y
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:58:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJjiA-0008Nw-7J
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:58:09 -0400
Received: from mail-ot0-x244.google.com ([2607:f8b0:4003:c0f::244]:35157)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dJjiA-0008Mq-2U
	for bug-bash@gnu.org; Sat, 10 Jun 2017 12:58:06 -0400
Received: by mail-ot0-x244.google.com with SMTP id t31so8129296ota.2
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 09:58:05 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=jTyk0tNPz1EJFXkOY3kaDTUELPv00uuYkyAPO/7p0UQ=;
	b=mVW5hj/rTkK6qZK5uoyoPi+8i0po+BZvXITc7+bjWCFg9Ky5Bej5/6NNJLNDQBacl4
	V5vRhqsq1Qf4WYk6HzM3CC9ZxaYhL0bNrBEGzYuCzFlL2iA/mNtY+j9GjbfXukZ4RmsC
	IfgyiP7xyqw9U12I8g8GMpOTiEq64WvcFPH2D+qPJYO0MfKjVJFLUJfALcndLeg3XKrz
	KSvUoVXASPfpX5kaFa/65UOGwu6rVxgTX1cNdrz73bx1VpymiuXiDPfwt9Hrriw0wiiy
	5MvPlYmkW4OyNX3pcdj3IFn7Cma3CzPNdQoIyboCyu9VJ5pB5Tk/aODg0mrEBZWSsYzR
	RYKA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=jTyk0tNPz1EJFXkOY3kaDTUELPv00uuYkyAPO/7p0UQ=;
	b=X8wrsu7YE7az7cVXVm+7yweDL+x0VVD6VLjKYQUHalpoj8lYjmlJWVm8Ch7O+cjGVu
	ULHq0nK6dgPi8wBqCsmG7Z4Mrm+R6JLvKZ9U2wmZ0N/plLLES98z7FduTd8feHuXWPaX
	nX3THEgtkdCtjNc3XFaTCgcw3+LRJLsH8cvdkRTNuni6LOjaq2KdJ8EELNAFx0EhHloz
	+vkQsT/QR4iCuxfJjnwvHQHjTJdko4HbZ758L0Mja6xh7c+8pSm4y+kK6QQhL1yQqcpN
	K07N/0CzuJV1CeDkdKP7zj860OBmqtUjDyMomX0BYwyUXUSOTdN6SWAhyGQJflydRwgV
	m78g==
X-Gm-Message-State: AKS2vOwqfvoVHYgiVDfcFCZt7nZ+vDxR+7lLH2Lq3OhguDPdDF+H3iuy
	KqGqF2c8b0/07g==
X-Received: by 10.157.23.195 with SMTP id j61mr115056otj.37.1497113885208;
	Sat, 10 Jun 2017 09:58:05 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	j191sm1099762oih.38.2017.06.10.09.58.04
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 10 Jun 2017 09:58:04 -0700 (PDT)
Date: Sat, 10 Jun 2017 11:58:03 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Paul Peet <peetpaul69@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Subject: Re: Buffer corruption when the terminal is resized.
Message-ID: <20170610165803.iyoc4qlsuzxux5tj@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::244
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 16:58:10 -0000

On Sat, Jun 10, 2017 at 06:49:13PM +0200, Paul Peet wrote:
> declare -- PS1="\\[\\e]0;\\u@\\h:
> \\w\\a\\]\${debian_chroot:+(\$debian_chroot)}\\[\\033[01;32m\\]\\u@\\h\\[\\033[00m\\]:\\[\\033[01;34m\\]\\w\\[\\033[00m\\]\\\$
> "
[...]
> > Bash relies on \[ and \] to determine how much space is occupied by the
> > prompt when it is to be redrawn, so in this case it thinks the prompt is 2
> > columns wider than it actually is.

George already said it. There are two types of characters inside the
prompt string, visible and invisible. Color sequences are of the
invisible kind (these have an effect on the terminal, but do not occupy
any space on the line). You must wrap invisible character sequences with
\[ and \], otherwise Readline's calculation to figure out the physical
lenght of your prompt string will be off, and will cause the effect that
you're experiencing.

Try with:

        #  vvvvv- this is an invisible sequence.
    PS1='\[\e]0;\]\u@\h:\w\a\$...'
        # ^      ^

instead.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 10 13:21:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJk4z-0005TY-Qf
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 13:21:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37043)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJk4x-0005T3-Bg
	for bug-bash@gnu.org; Sat, 10 Jun 2017 13:21:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJk4w-0007oC-4O
	for bug-bash@gnu.org; Sat, 10 Jun 2017 13:21:39 -0400
Received: from mail-wr0-x229.google.com ([2a00:1450:400c:c0c::229]:33990)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dJk4v-0007o7-Tr
	for bug-bash@gnu.org; Sat, 10 Jun 2017 13:21:38 -0400
Received: by mail-wr0-x229.google.com with SMTP id g76so59256018wrd.1
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 10:21:37 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=CSDBomic56j72e7WSp4PTSJYVJvYaysPPrO+gemoC5k=;
	b=VHXSP6z+zZfcOmfGI0r9hK7QnQ+TN9zGyF6LAm9Krb8svLrYF2t9r44ttVhuKl5OfX
	VM7v8cuuPKveYGh8nqH7SsKe8OZEQ4RWfGJDixBrPI2pRQwbU+Oe2IUxY0dqNZERktAk
	0lHuCMMn6QPE/3zSmk10BD1Jm/R/UNOAHibK6TnSKZmQCpGgXbz2Ct2YJBvx4NGCPl0x
	OPHfBzNweJbLkcy5M0uP4lK7X3hWN+o702lfIpnYENsrcHsc4BzB7zZFrueSqvqvDNce
	9YRtJBB9Lw/NaZXpnpq8l1o1MbzJ7UUqlyFNYFNRN/2YjbUMCr14JqFbBIGdvYPfaeEd
	XL3w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=CSDBomic56j72e7WSp4PTSJYVJvYaysPPrO+gemoC5k=;
	b=WwGhTmfinQlWIuyifeJq5Kc3ewYN916TEjYtssYGkDn4yWPmDuTRls1pRdhZDJwSHv
	i9rxplz/FopIN5lqQJ/m1Cf6skh1ly1IzsoomCR1dXHLVUpVLVGN1xZYoZLwX3X4kFoq
	taYxDRNHZr3jr1+MUu96xG0WBz5i79GICNhQGse1/CAoh2KjLYjz1Wev1XBmnmcuPZKY
	Sz5cFFtuaSwTxfkZAWthUoD+uyUpI+qnSOXHPxvypcshIv9idoQULraB1oseRNUqJMZj
	VsA4gBT9AX2qRwV4bbKnivMf8hg2WPzI+KiRvwpysxv9gv0+84NpMvBOexBHIBFoGXd2
	Vjkg==
X-Gm-Message-State: AODbwcBgjf8R24aLsRrUsX5vVPAAhD7hMlufwGc9s/eaIy2AFN40PdP7
	qrNvAJRz6r9s664ipgHK/x+pxS9GEQ==
X-Received: by 10.223.130.37 with SMTP id 34mr2755289wrb.44.1497115296900;
	Sat, 10 Jun 2017 10:21:36 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Sat, 10 Jun 2017 10:21:36 -0700 (PDT)
In-Reply-To: <20170610165803.iyoc4qlsuzxux5tj@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
From: Paul Peet <peetpaul69@gmail.com>
Date: Sat, 10 Jun 2017 19:21:36 +0200
Message-ID: <CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: Eduardo Bustamante <dualbus@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 17:21:40 -0000

If I understand this correctly this prompt (see below) shouldn't
contain any invisible sequence, therefore it doesn't require the
wrapping with \[ and \].

PS1="\u@\h\$"

So bash should be able to correctly calculate the prompt size and
such, but by resizing the window it still results in a corrupted
buffer.

I've uploaded another gif which shows this:
https://media.giphy.com/media/xUA7biW8UtwYIU6ggg/giphy.gif


On Sat, Jun 10, 2017 at 6:58 PM, Eduardo Bustamante <dualbus@gmail.com> wrote:
> On Sat, Jun 10, 2017 at 06:49:13PM +0200, Paul Peet wrote:
>> declare -- PS1="\\[\\e]0;\\u@\\h:
>> \\w\\a\\]\${debian_chroot:+(\$debian_chroot)}\\[\\033[01;32m\\]\\u@\\h\\[\\033[00m\\]:\\[\\033[01;34m\\]\\w\\[\\033[00m\\]\\\$
>> "
> [...]
>> > Bash relies on \[ and \] to determine how much space is occupied by the
>> > prompt when it is to be redrawn, so in this case it thinks the prompt is 2
>> > columns wider than it actually is.
>
> George already said it. There are two types of characters inside the
> prompt string, visible and invisible. Color sequences are of the
> invisible kind (these have an effect on the terminal, but do not occupy
> any space on the line). You must wrap invisible character sequences with
> \[ and \], otherwise Readline's calculation to figure out the physical
> lenght of your prompt string will be off, and will cause the effect that
> you're experiencing.
>
> Try with:
>
>         #  vvvvv- this is an invisible sequence.
>     PS1='\[\e]0;\]\u@\h:\w\a\$...'
>         # ^      ^
>
> instead.
>
> --
> Eduardo Bustamante
> https://dualbus.me/


From MAILER-DAEMON Sat Jun 10 17:21:05 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJnoe-00076H-W6
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 17:21:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45322)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJnod-00076A-E5
	for bug-bash@gnu.org; Sat, 10 Jun 2017 17:21:04 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dJnoa-0007Vi-37
	for bug-bash@gnu.org; Sat, 10 Jun 2017 17:21:03 -0400
Received: from mail-ot0-x241.google.com ([2607:f8b0:4003:c0f::241]:34207)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dJnoZ-0007VR-M9
	for bug-bash@gnu.org; Sat, 10 Jun 2017 17:20:59 -0400
Received: by mail-ot0-x241.google.com with SMTP id a2so8424680oth.1
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 14:20:59 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=rIGIVHptDQYOye9piCgoGeN7vlRs/gSqqLd414GmtnM=;
	b=Vz/9jdBJM91rpmwUFdO6V+bQutrp2to5HSGMiPe7E92PZK8X/m3JCI65O5D1YPs7Fs
	x8fwPtuW+drbac+IpUMV/Db+wvw2fjnQMvwdkn8IYNmOGFfuynQnoa6k2Sa5qx4npUzz
	SjTTHfnB7l6bp1w1mRR6pXdw4BMo+ALmZAhsNyl3+DQez5a10fmjiQpriyEAD/HImVE5
	46eyZDVMeOy+BaT6AwrxJYhUEp8uLMSfy6sFp/fECdMhkT3svLgT5KtZOXoihe8OHze1
	TFgfqHKmWFe3CpYB0iFIPnPDF0aK+hJU9QSapL6ejxtnla/RwcXpzFnb0Qkop4HrNm8u
	/tUg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=rIGIVHptDQYOye9piCgoGeN7vlRs/gSqqLd414GmtnM=;
	b=Cfb7P9LOaEKk5CdUtlE9ru6/AkoYgaz2mKszG3sbffhlCQvwXpPb7OtpTn0KO2VfoV
	EdtFQjA9sQvor3b8FBGy4oAtMnYoEy1zA0X669dczPfBBnBJtpDQ3gEXg3slip0Sz2/s
	OfqFprCo8AJM2nieWOaVG4JEj8gFLhg0ts40MLSXP/s7yvzdunXyGPbd6AUNQCSDu3C7
	yBbzZEXVDrEukyu5UBzjvq5As+dmmkGtBce5KMYEVGGlqTG0NnBGX9mAN9HH0yS16MtH
	t+GMNTgecH4uqk2Lw3+/CN1+nMJmzKOkg0XlkvUbIkmAzIOUZX4czWGdbod5lyzktjmh
	rJlw==
X-Gm-Message-State: AODbwcB9YV0DnzK9W7hwnLPBKFGlNf5XSDxzThwYXiOy0yviJ05NIMap
	rgQQ1TRZ9956FQ==
X-Received: by 10.157.22.208 with SMTP id s16mr14407148ots.81.1497129658743;
	Sat, 10 Jun 2017 14:20:58 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	x64sm2539512ota.52.2017.06.10.14.20.57
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 10 Jun 2017 14:20:57 -0700 (PDT)
Date: Sat, 10 Jun 2017 16:20:56 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Paul Peet <peetpaul69@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Subject: Re: Buffer corruption when the terminal is resized.
Message-ID: <20170610212056.iphrgnrccux2cqx3@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::241
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 21:21:04 -0000

On Sat, Jun 10, 2017 at 07:21:36PM +0200, Paul Peet wrote:
> If I understand this correctly this prompt (see below) shouldn't
> contain any invisible sequence, therefore it doesn't require the
> wrapping with \[ and \].
> 
> PS1="\u@\h\$"
> 
> So bash should be able to correctly calculate the prompt size and
> such, but by resizing the window it still results in a corrupted
> buffer.
> 
> I've uploaded another gif which shows this:
> https://media.giphy.com/media/xUA7biW8UtwYIU6ggg/giphy.gif

I can't reproduce this with:


  dualbus@debian:~/src/gnu/bash$ bash --version | head -n1
  GNU bash, version 4.4.12(1)-release (x86_64-pc-linux-gnu)
  
  dualbus@debian:~/src/gnu/bash$ xterm -version
  XTerm(327)
  
  dualbus@debian:~/src/gnu/bash$ lsb_release -d
  Description:    Debian GNU/Linux 9.0 (stretch)


Can you reproduce the problem using a more recent version. Perphaps try
the `devel' branch from git?  <https://savannah.gnu.org/git/?group=bash>

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 10 18:29:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJot0-0003L2-8T
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 18:29:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52178)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJosy-0003Kt-B8
	for bug-bash@gnu.org; Sat, 10 Jun 2017 18:29:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dJosx-00085J-8k
	for bug-bash@gnu.org; Sat, 10 Jun 2017 18:29:36 -0400
Received: from mail-wr0-x230.google.com ([2a00:1450:400c:c0c::230]:33235)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dJosx-00085D-12
	for bug-bash@gnu.org; Sat, 10 Jun 2017 18:29:35 -0400
Received: by mail-wr0-x230.google.com with SMTP id v104so62643384wrb.0
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 15:29:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=hkPWLYpikFJAThGTk6804qt5CeTI2qiAq+a6ik6pEZ8=;
	b=GiDcmcuic6UE5+dOPxA0gkrVQBV9m8KsnpDlE30jHHSo+FX2G7lfwPbR7Yma02oN3O
	royxj+PfDMKWA4NW4XwRrloF7y5Jzu6rFapZ+LnGcK896I6tzg0rSuCN25K3TPAe6dX1
	5M3Pto1ApttaEQey1xEpN5cmsxKhIzTh3qIcLFQLJ2pN5mlFySj/0a9OGB2YlN4rpBJL
	1lgDXOwSc74028lnDHVjxJgPP/BT2JqZA/vjm9NbDJHndivk8Tgsg1VSFOTNsR4Kh6jh
	PlcnX3RRV69a3n4xpcR9yUuSPkyVsKW7ZhJdRDB0HtHuHO51PFDSO6f/QnOK315MLsMX
	NXMg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=hkPWLYpikFJAThGTk6804qt5CeTI2qiAq+a6ik6pEZ8=;
	b=gB6qFTZ21DMBGU61mlhwKaSltXOO/GRURPPVCztNgKSH+++GOwuDCggCgO0n1Iuqkk
	klZl858zGaAhgf7JGZpo4lGSdZIWxwrZ7I1Fg8gA3qGUaojjO7Q/WCTmuwHHuggNwHjn
	48pbjkPmz0aiXdOc4b9EV3VtEyatNzt3anD5pRMITOrikql4SxHftXr9X+1Bu4CHmVWo
	Vks3AF4UQ9jMrYYMqqDVEOYHngov0+ervfQKveDLpluVhqagGXSgOkln17k6h4jBtOqI
	dYmJx9yQzs4kfP6z1TGDwEnyqffCW50ZDQdRBqKKm7iOB86pH6ClmK/xZuYPoFRZ/YD6
	zf3w==
X-Gm-Message-State: AODbwcDbSQJXBBOutp8YHJtuT8EAPCUdDx60B4m5Lsms+uHgaygwmmdp
	JNLWkDempIlyMkcqahkvRvqbQjZBeA==
X-Received: by 10.223.130.37 with SMTP id 34mr3215396wrb.44.1497133773885;
	Sat, 10 Jun 2017 15:29:33 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Sat, 10 Jun 2017 15:29:33 -0700 (PDT)
In-Reply-To: <20170610212056.iphrgnrccux2cqx3@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
From: Paul Peet <peetpaul69@gmail.com>
Date: Sun, 11 Jun 2017 00:29:33 +0200
Message-ID: <CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: Eduardo Bustamante <dualbus@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 10 Jun 2017 22:29:37 -0000

Okay, I did the follwing:

> git clone https://git.savannah.gnu.org/git/bash.git
> cd bash && git checkout devel
> ./configure --prefix=/ --with-curses --enable-readline
> make

I then changed the default shell (in gnome-terminal) to the newly built bash.

> echo $BASH_VERSION
4.4.12(1)-maint

Unfortunately, I am still getting the same behavior as before (This
also happens with xterm for some reason.)

On Sat, Jun 10, 2017 at 11:20 PM, Eduardo Bustamante <dualbus@gmail.com> wrote:
> On Sat, Jun 10, 2017 at 07:21:36PM +0200, Paul Peet wrote:
>> If I understand this correctly this prompt (see below) shouldn't
>> contain any invisible sequence, therefore it doesn't require the
>> wrapping with \[ and \].
>>
>> PS1="\u@\h\$"
>>
>> So bash should be able to correctly calculate the prompt size and
>> such, but by resizing the window it still results in a corrupted
>> buffer.
>>
>> I've uploaded another gif which shows this:
>> https://media.giphy.com/media/xUA7biW8UtwYIU6ggg/giphy.gif
>
> I can't reproduce this with:
>
>
>   dualbus@debian:~/src/gnu/bash$ bash --version | head -n1
>   GNU bash, version 4.4.12(1)-release (x86_64-pc-linux-gnu)
>
>   dualbus@debian:~/src/gnu/bash$ xterm -version
>   XTerm(327)
>
>   dualbus@debian:~/src/gnu/bash$ lsb_release -d
>   Description:    Debian GNU/Linux 9.0 (stretch)
>
>
> Can you reproduce the problem using a more recent version. Perphaps try
> the `devel' branch from git?  <https://savannah.gnu.org/git/?group=bash>
>
> --
> Eduardo Bustamante
> https://dualbus.me/


From MAILER-DAEMON Sat Jun 10 23:45:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJtoX-0007Bt-5o
	for mharc-bug-bash@gnu.org; Sat, 10 Jun 2017 23:45:21 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59864)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dJtoV-0007Bm-1I
	for bug-bash@gnu.org; Sat, 10 Jun 2017 23:45:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dJtoT-0002wa-OK
	for bug-bash@gnu.org; Sat, 10 Jun 2017 23:45:19 -0400
Received: from mail-pg0-x236.google.com ([2607:f8b0:400e:c05::236]:33690)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dJtoT-0002vg-Fx
	for bug-bash@gnu.org; Sat, 10 Jun 2017 23:45:17 -0400
Received: by mail-pg0-x236.google.com with SMTP id f185so36263750pgc.0
	for <bug-bash@gnu.org>; Sat, 10 Jun 2017 20:45:17 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=cE06jM5rn0fQ+imU6vs7cTO4HvS75+Xsr4YIUvwysdM=;
	b=qe3XaWwlwXxVYo7+W6DeLhxWx4XeQ+noze1fahZX7Ut+YoYyhd5DnbhsezTpFsfeU/
	ABJTxUW3i3pE1FtAJAwWXDNySuWG5iNSM4ckAoR38yF5LuJ8H6Zr8kNg4CFtqz4Pfq22
	hTMxL0WLX/7HFLvkDBbzRofKgq6gFPDzBVXkmvdCBFqWADftnq6kJFCiH7uaXbB4u4mf
	4j/smpS16vDadH+meVY/FMVtmh9+SJvTlm/pTcArGRpXEkJ05ykcZBFwScX5V0LV5NAY
	UPOn81VCDyWV7hK6yJaHgsxp9T/RDzzaHzBFAW5rFN0uOU8ojVKK4M0nNCVjtdOPFnHc
	Ma7A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=cE06jM5rn0fQ+imU6vs7cTO4HvS75+Xsr4YIUvwysdM=;
	b=LbfGJ4d3roKtj+oZgnb+nnu3+HEVzc0ifBzneRD0IM7jAb8hXgAxD/pWnK5rBDcdmn
	J0CIj/o+FZQM2R9o82inMQd5Uw9xtGrfD03XNn3nrgYVHLX5XoSuEEmkg5qyy4f2cDcm
	Po3Au6CnxWf7VkhaHQ1UfNEiPQuBFK7WkDtS0ERyU21S/k2ICuznx7wZlk0RdYwSwiLt
	ir/FrC40YPColBReCHgSgHLkAWt5KSdKcxHPYvJcfdY6LY/LgE2IHjKVEynR3BNo/Q4B
	851+nXD3uMbY5dBruEgLmNbf1uvgnbZkDCNP+96o+P1MsFQ6kV1rhl9vjhdXqdDCD05p
	SomQ==
X-Gm-Message-State: AODbwcDhmlrb5dWXrluKpu+bVlZfOPsP4KOjyJHKpXjQ+UbqUTw5AkXO
	6qYud3tX0togrYFSNySRvXRAcJPhQA==
X-Received: by 10.98.74.5 with SMTP id x5mr37278887pfa.149.1497152716442; Sat,
	10 Jun 2017 20:45:16 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.153.219 with HTTP; Sat, 10 Jun 2017 20:44:36 -0700 (PDT)
In-Reply-To: <CAAJSdjg5YBq42q2HBMqTJvcDYoJMAz4xoou7hq_cJe9r=UPG8A@mail.gmail.com>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<CAAJSdjg5YBq42q2HBMqTJvcDYoJMAz4xoou7hq_cJe9r=UPG8A@mail.gmail.com>
From: Clark Wang <dearvoid@gmail.com>
Date: Sun, 11 Jun 2017 11:44:36 +0800
Message-ID: <CADv8-ogxRDxyzVP4WvUEo8CgghFB4EVbwqcfEKhbZ=th=Vccsg@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: John McKown <john.archie.mckown@gmail.com>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::236
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 03:45:20 -0000

On Sat, Jun 10, 2017 at 11:00 PM, John McKown <john.archie.mckown@gmail.com=
>
wrote:

> On Sat, Jun 10, 2017 at 9:19 AM, Clark Wang <dearvoid@gmail.com> wrote:
>
>> (I'm using bash 4.4.12 on Debian 8)
>>
>> Please follow the following steps to reproduce.
>>
>> From tty #1:
>>
>> $ tty
>> /dev/pts/11
>> $ ssh -o ControlMaster=3Dyes -o ControlPath=3D/tmp/socket.tmp -N -f 127.=
0.0.1
>> root@127.0.0.1's password:
>> $ ps -C ssh uw
>> USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
>> root       716  0.0  0.2  44428   692 ?        Ss   22:04   0:00 ssh -o
>> ControlMaster=3Dyes -o ControlPath=3D/tmp/socket.tmp -N -f 127.0
>> $
>> $
>> =E2=80=8B=E2=80=8B
>> ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 sle=
ep
>> 9999 &
>> [1] 725
>> $    <-- Then I cannot input anything except CTRL-C
>>
>> Go to tty #2:
>>
>> $ ps t pts/11 jw
>>  PPID   PID  PGID   SID TTY      TPGID STAT   UID   TIME COMMAND
>> 32714   725   725 32714 pts/11   32714 S        0   0:00 ssh -o
>> ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 sleep 9999
>>   579 32714 32714 32714 pts/11   32714 Ss+      0   0:00 bash
>> $
>>
>> If I kill the "ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tm=
p
>> 127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my
>> input
>> again. Seems like the background "ssh" at tty #1 is consuming all input.=
 I
>> cannot understand this since it should be stopped by SIGTTIN if it tries
>> to
>> read from the tty.
>>
>> Idea?
>>
>> -clark
>>
>
> =E2=80=8BIMO, not a bug in BASH, so this is the wrong forum. But, since I=
'm
> already blathering on, I'd say the problem is that you have invoked "ssh"
> incorrectly.=E2=80=8B In particular, ssh _does_ read from stdin normally.=
 But, from
> the man page:
>
>  -f      Requests ssh to go to background just before command execution.
> This is useful if ssh is going to ask for passwords
>              or passphrases, but the user wants it in the background.
> This implies -n.  The recommended way to start X11 programs
>              at a remote site is with something like ssh -f host xterm.
>
>              If the ExitOnForwardFailure configuration option is set to
> =E2=80=9Cyes=E2=80=9D, then a client started with -f will wait for all
>              remote port forwards to be successfully established before
> placing itself in the background.
>
>
> So instead of:
>
> =E2=80=8B
> ssh -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 slee=
p 9999
> &
>
> Try:
>
> =E2=80=8B
> ssh -f -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.1 s=
leep
> 9999
>

Thanks but I want it to run as a background job in bash.

From MAILER-DAEMON Sun Jun 11 00:11:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dJuDr-00036H-5C
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 00:11:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33777)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJuDn-000363-P3
	for bug-bash@gnu.org; Sun, 11 Jun 2017 00:11:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dJuDk-0002yi-52
	for bug-bash@gnu.org; Sun, 11 Jun 2017 00:11:27 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:51158
	helo=homiemail-a80.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dJuDj-0002w4-MJ
	for bug-bash@gnu.org; Sun, 11 Jun 2017 00:11:24 -0400
Received: from homiemail-a80.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a80.g.dreamhost.com (Postfix) with ESMTP id A95236000B0B; 
	Sat, 10 Jun 2017 21:11:15 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=iaTigpkBe7lcuaYa
	Peogzsj6nrA=; b=GCCiEcN92KkUJnaDfKNt4f5fkUZEu2ZdoYi3dgpJwTODCusB
	SFslTwN6CpZysJYLKoNENF3a68Hx4Bc9QcymjUhFZVYlWvdb9oXu3HEWNZ/zAQrh
	V9ZVUB9ODf26C126ZqDvEwwELo685EgUFYDZjyaIKsLK69HHzzpszQ1zJFM=
Received: from frontier (unknown [76.191.34.78])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a80.g.dreamhost.com (Postfix) with ESMTPSA id 435916000B00;
	Sat, 10 Jun 2017 21:11:15 -0700 (PDT)
Message-ID: <1497154273.17253.480.camel@scope-eye.net>
Subject: Re: Storing NUL in variables
From: George <tetsujin@scope-eye.net>
To: Pierre Gaston <pierre.gaston@gmail.com>
Cc: Peter & Kelly Passchier <peterkelly@passchier.net>, "bug-bash@gnu.org"
	<bug-bash@gnu.org>
Date: Sun, 11 Jun 2017 00:11:13 -0400
In-Reply-To: <CAPSX3sThFtact3nP4jQx_rvAtxh0RXy2xsRkipaAnpGCu59oRw@mail.gmail.com>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<CAPSX3sTQxC3pUVqFFFe9ii9wZTV=TW0Uj3B-mKwaxe8TcnTTEA@mail.gmail.com>
	<1497049577.17253.408.camel@scope-eye.net>
	<CAPSX3sThFtact3nP4jQx_rvAtxh0RXy2xsRkipaAnpGCu59oRw@mail.gmail.com>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 04:11:29 -0000

On Sat, 2017-06-10 at 19:33 +0300, Pierre Gaston wrote:
>=20
>=20
> > >=20
> > One option that might make a feature like this integrate into the she=
ll better would be to store a captured byte stream as an integer array ra=
ther
> > than as an atomic variable. The back-end implementation in this case =
could be very efficient, and the stored data would be manipulable using
> > existing array syntax. The main limitation perhaps would be that one =
could not create an array of these arrays.
> >=20
> Without too much thinking about it, I'd=C2=A0 propose something like th=
is:
>=20
> - extend readarray (or maybe provide another builtin)=C2=A0 to read byt=
es with an interface like the one of dd (block size, offset, skip) and st=
ore the
> bytes in the array. eg:=C2=A0 readarray -b bs=3D1024 cs=3D100 byte_arra=
y=20
>=20
> - provide another builtin to write the array to a fd, eg "write bs=3D10=
24 cs=3D100 byte_array" (I don't really see a good way to extend printf o=
r echo
> for this)=C2=A0
>=20
> -=C2=A0 setting an array directly would store the bytes eg a[0]=3D0 wou=
ld put a null bye at the first index
>=20
> -=C2=A0 conversely ${a[0]} would expend to "0"
>=20
> - I think the current array could even be use, but that would not be ve=
ry efficient, and there is the question of what to do with sparse arrays
>=20
> - I think I would like some efficient way to copy range of bytes from o=
ne array to the other, maybe this could be done reusing the above "write
> builtin" like: write offset=3D100 seek=3D50 -v dest_array -s source arr=
ay=C2=A0
>=20
>=20
> I think that could even been done with loadables builtins, making all t=
he byte arrays "special_variables"
>=20
> My 2 cents....of course I probably should have checked what zsh does as=
 I think it supports nullbytes in variable.
The talk of special variables brings me back to a previous feature reques=
t of mine: the ability to associate a data payload with a dynamic variabl=
e,
and a callback to allow the dynamic variable implementation to clean up t=
hat data when the variable is unset. (I am planning to write a patch to
provide this functionality - though I don't know if it will be accepted.)
The lack of that functionality stands in the way of implementing an effic=
ient byte stream buffer as a dynamic variable using a "loadable builtin"
module. "Dynamic var" implementations have callbacks that may be used to =
get and set variable value, but nowhere to store state data associated wi=
th
the variable. This works fine for the dynamic vars that are defined by th=
e shell, because each variable has its own implementation, and each
implementation is used for just one variable. There's a 1:1 relationship =
between dynamic variables and dynamic variable implementations, so dynami=
c
variable implementations can store their state data in global variables. =
Implementing something like a byte stream buffer as a dynamic would requi=
re
the ability to provide one backing implementation that could be used for =
multiple variables. As it stands, the only place you can store data in a
variable is in its "value" field - which must contain the textual represe=
ntation of the variable's value.
(A compact byte-array type could be stored in a flat buffer, of course, s=
o a dynamic var implementation would require the "dynamic variable data
pointer", but not the "dynamic variable unset callback" if it's assumed t=
hat unsetting a variable would also de-allocate the buffer indicated by t=
he
data pointer: However in more general application of the "dynamic variabl=
e" functionality it would be useful to be able to use other data structur=
es
to store the state of the variable: things like linked data structures. S=
o for those applications an "unset callback" would be useful. An "unset
callback" would also allow things like using variable lifetimes to contro=
l other resources, like file descriptors, temporary files, or child
processes.)
I had initially thought the implementation of a byte-stream array could b=
e similar to the existing implementation of an integer array. But (from w=
hat
I can tell) the implementation of an integer array is just the implementa=
tion of a string array, but with rules added to constrain the array eleme=
nts
to numeric strings. (i.e. when assigning a value to such a variable, firs=
t evaluate the new value as a numeric expression to get an integer value =
for
the variable, then convert the numeric value to a string and store that. =
See make_variable_value() in variables.c, for instance.) So there would b=
e no
value in creating a separate "byte array" type unless it either provided =
a significant performance advantage (by storing data internally as a byte
array, rather than a text-encoded byte array), or significantly more favo=
rable semantics (for instance, expressing the bytes as hex rather than
decimal)
Unfortunately, that may torpedo the whole idea of implementing a type lik=
e this as a dynamic array var in Bash: even with a "dynamic var"
implementation of a byte array, compactly storing the byte stream in a bu=
ffer somewhere, as soon as anyone tries to treat the data structure as a
conventional array, the dynamic variable "get value" function is expected=
 to populate the whole variable array structure with a textual representa=
tion
of the byte values, negating the storage-saving benefit of the compact by=
te-array representation... =C2=A0At best, you could read binary data in a=
nd write
it back out again without triggering the conversion... =C2=A0But as soon =
as the conversion happens, the whole venture becomes somewhat pointless. =
To get
around that one would require changing the dynamic var implementation to =
allow for dynamic vars whose text value is generated on-demand and not st=
ored
(which probably complicates applying other logic down the road - like the=
 different forms of parameter expansion for instance, all of which presen=
tly
could just operate on that variable "value" field and remain blissfully i=
gnorant of the fact that it's a dynamic variable) =C2=A0The only way to r=
etain the
benefits of the compact representation (in the current version of Bash) w=
ould be to make the dynamic variable a "black box", and use built-in comm=
ands
to manipulate the data or extract other representations. (And if it's a b=
lack box, there's no point making it an "array")
As for reading and writing binary data, I think at this point my inclinat=
ion would be to provide new commands to do it rather than further overloa=
ding
"read" and "printf". That would be necessary anyway if the byte stream fu=
nctionality were provided as a loadable "builtin" library.

From MAILER-DAEMON Sun Jun 11 13:43:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dK6tZ-0005tD-1m
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 13:43:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50172)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <seejay.11@gmail.com>) id 1dK6tX-0005s8-6i
	for bug-bash@gnu.org; Sun, 11 Jun 2017 13:43:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <seejay.11@gmail.com>) id 1dK6tT-0002FS-AY
	for bug-bash@gnu.org; Sun, 11 Jun 2017 13:43:23 -0400
Received: from mail-wr0-x241.google.com ([2a00:1450:400c:c0c::241]:36292)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <seejay.11@gmail.com>) id 1dK6tT-0002Cj-2X
	for bug-bash@gnu.org; Sun, 11 Jun 2017 13:43:19 -0400
Received: by mail-wr0-x241.google.com with SMTP id e23so17401657wre.3
	for <bug-bash@gnu.org>; Sun, 11 Jun 2017 10:43:17 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:references:from:message-id:date:user-agent:mime-version
	:in-reply-to; bh=itIolraehBY0v2pwJ5xHXV7f/IGTr6cIyvFHkGMnjU8=;
	b=sopGwuExM/HpP1WGS0Gdz6LWaOpPMmhaBe6T1tgRHOWMzujYNUg1xTm2cWzFNFovyT
	E7UtHcaiUQsXC6hQzUPLLnDMcJ/udZ6NuJKebz0PH9r+umK3zOUl79+gpp+ZuYCgKRC7
	+NICNyUl4lv25vqNqhol5l5CLVcryZ/A4182X/8hKariw9wnXF/jSZBjrulgB2Z3UJkz
	JSSyYYLAupusFq3j0a9MsydSwNCZemIm880NdZhKTx4yZPBLy4rfgOyKE4ZiQzSES+FW
	AZilHusnloqcXFgG9dI6cwS9uNXlPdTcENLzLjg9ZKqGmD+nJUidIoZiZdXXh95xBNK4
	6SVw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:references:from:message-id:date
	:user-agent:mime-version:in-reply-to;
	bh=itIolraehBY0v2pwJ5xHXV7f/IGTr6cIyvFHkGMnjU8=;
	b=idyXmU2F/3+HaFqg5h3oDvNknYHPl/zksXUdMEWNXvpL4TKbgZZFPBQlvp9yiASqvD
	xTeaHdVlmbTtML2lP7c7u7iIOfnWJXITPnKAyxM/pqcrdJ4heMlhY5ezFRejbPUg+JYY
	K7RxTNEJufDu6NQEq1yYj8kO8eFn4bRtek+D1yzYwB2iulfC7ip/2THwIOubaqfdQnNv
	YZiPEl9+N31a9NO6/0aCZWCrRrWhWSsHpE3CLIA9ic3h/qLFheZgxSZWcS/S15b2B4oz
	4srg82+sVP0FrNglq4wKNwogoYdJSoOjHDTWmOQI/AL+uBbBMe+2i3zqBCJ1Fd9calT0
	sNHQ==
X-Gm-Message-State: AODbwcBSrdcgY0t7XNigI+OXpo7wE12yJNdD8TLhOAw8jh3xeTgsYhCX
	n61232P7yvoNll+H+dw=
X-Received: by 10.80.194.25 with SMTP id n25mr39979308edf.153.1497202996362;
	Sun, 11 Jun 2017 10:43:16 -0700 (PDT)
Received: from [192.168.1.2] (94.133.93.209.dyn.plus.net. [209.93.133.94])
	by smtp.gmail.com with ESMTPSA id
	w12sm2675891edd.21.2017.06.11.10.43.15 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Sun, 11 Jun 2017 10:43:15 -0700 (PDT)
Subject: Re: A background ssh can take over the tty from bash?
To: bug-bash@gnu.org
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<CAAJSdjg5YBq42q2HBMqTJvcDYoJMAz4xoou7hq_cJe9r=UPG8A@mail.gmail.com>
	<CADv8-ogxRDxyzVP4WvUEo8CgghFB4EVbwqcfEKhbZ=th=Vccsg@mail.gmail.com>
From: Charles Daffern <seejay.11@gmail.com>
Message-ID: <e80adf69-9f1d-fe54-50ac-974b4250ade6@gmail.com>
Date: Sun, 11 Jun 2017 18:43:06 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
	Thunderbird/45.8.0
MIME-Version: 1.0
In-Reply-To: <CADv8-ogxRDxyzVP4WvUEo8CgghFB4EVbwqcfEKhbZ=th=Vccsg@mail.gmail.com>
Content-Type: multipart/signed; micalg=pgp-sha256;
	protocol="application/pgp-signature";
	boundary="jG6pLtDkcONgS7AOEIOLU3KWHmowTc4wR"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::241
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 17:43:24 -0000

This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--jG6pLtDkcONgS7AOEIOLU3KWHmowTc4wR
From: Charles Daffern <seejay.11@gmail.com>
To: bug-bash@gnu.org
Message-ID: <e80adf69-9f1d-fe54-50ac-974b4250ade6@gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
 <CAAJSdjg5YBq42q2HBMqTJvcDYoJMAz4xoou7hq_cJe9r=UPG8A@mail.gmail.com>
 <CADv8-ogxRDxyzVP4WvUEo8CgghFB4EVbwqcfEKhbZ=th=Vccsg@mail.gmail.com>
In-Reply-To: <CADv8-ogxRDxyzVP4WvUEo8CgghFB4EVbwqcfEKhbZ=th=Vccsg@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

>> But, from the man page:
>>
>>  -f      Requests ssh to go to background just before command executio=
n.
>> This is useful if ssh is going to ask for passwords
>>              or passphrases, but the user wants it in the background.
>> This implies -n.  The recommended way to start X11 programs
>>              at a remote site is with something like ssh -f host xterm=
=2E
>>
>>              If the ExitOnForwardFailure configuration option is set t=
o
>> =E2=80=9Cyes=E2=80=9D, then a client started with -f will wait for all=

>>              remote port forwards to be successfully established befor=
e
>> placing itself in the background.
>>
=2E..
>>
>> Try:
>>
>> =E2=80=8B
>> ssh -f -o ControlMaster=3Dno -o ControlPath=3D/tmp/socket.tmp 127.0.0.=
1 sleep
>> 9999
>>
>=20
> Thanks but I want it to run as a background job in bash.
>=20

That excerpt of the ssh man page provided above mentions the "-n"
option. Since ssh automatically sets that option for -f, you can safely
assume that it is somehow useful for backgrounded processes. Sure enough:=


     -n      Redirects stdin from /dev/null (actually, prevents
             reading from stdin).  This must be used when ssh is run
             in the background.  A common trick is to use this to
             run X11 programs on a remote machine.  For example, ssh
             -n shadows.cs.hut.fi emacs & will start an emacs on
             shadows.cs.hut.fi, and the X11 connection will be auto=E2=80=
=90
             matically forwarded over an encrypted channel.  The ssh
             program will be put in the background.  (This does not
             work if ssh needs to ask for a password or passphrase;
             see also the -f option.)

The -n option mentions that it "must be used when ssh is run in the
background", so I would recommend setting that on your backgrounded proce=
ss.




--jG6pLtDkcONgS7AOEIOLU3KWHmowTc4wR
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQJIBAEBCAAyFiEEr2wXDlnoJ2Vo3VOaKwKpjZm7NoMFAlk9gSsUHHNlZWpheS4x
MUBnbWFpbC5jb20ACgkQKwKpjZm7NoN8ww//bXQcXeVJwknQqsPWTKQ3v4VIte5g
vt+B7rmU3/TQHZZWfXW3OxfJy0t9eOO/2jUaLUGCWqu8tWKTNN79PHn6iyo+hDPe
Hl8vNuVkIpeSQICQS+7eF0u1MgK6aexkPwtXT+3VOqmHxfyQUL+WhyoLgMpxFkdP
tS0GvritUlxUQ3kFS0LJIHb/D/z1XDx+YyzGYlQhZXqVcrAXRd8rWSSEstjSHqeM
9WwNVMnnt8bdUmXOHgEBjIPUOJsvw1Eltq2EwZSPIUH8fPwhWKHDMxrEdmY8aNlU
TtJqWGw3YVrPVA0fcl7WZr2vAM1mAw/I3uCwCtyJmc7IBgHZK3TjXBN8RGBnlOIF
aT1hOrrUfudiKtFaazahSxLzZ2ZyDQWzwDGYqVsBGzpEunwLV3Kl4pLjzZPwYJeK
ap133F7w0gQ5mPcq7d+TndJM4fVecW32K8plzWDwseIw2LRdChnAFB6sUhwVmoJ6
mNrHQiVX32P0vwbbwma1YR1Ky0+L4SQtumpX7zp1+GOXJw/cnfOyeDLB2vWK2mOB
4mnHED50NkdSgPAw6J2y0niIIBS5jaf39Lcao4mckozkGD0hBbPyVz0OEN3F3Yei
WpyUqGd9daAthMkUNIzzWOwqxCz1JFBp77Hf/9iljb1oT9L699LaSuvYXqLlDXOI
i4gBh71IB8KQclk=
=wFMy
-----END PGP SIGNATURE-----

--jG6pLtDkcONgS7AOEIOLU3KWHmowTc4wR--


From MAILER-DAEMON Sun Jun 11 17:41:03 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKAbX-0001yp-67
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 17:41:03 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52707)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKAbV-0001yj-RG
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:41:02 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKAbQ-0004wV-Ta
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:41:01 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:60454
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKAbQ-0004wA-IZ
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:40:56 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5BLebtb061499; Sun, 11 Jun 2017 14:40:39 -0700
Message-ID: <593DB8D5.70901@tlinx.org>
Date: Sun, 11 Jun 2017 14:40:37 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: "Chris F.A. Johnson" <chris@cfajohnson.com>
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
	<593B3D98.4050002@tlinx.org>
	<alpine.DEB.2.10.1706092123080.10104@cfajohnson.ca>
In-Reply-To: <alpine.DEB.2.10.1706092123080.10104@cfajohnson.ca>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 21:41:02 -0000



Chris F.A. Johnson wrote:
>
> A newline IS literal whitespace.
I'm glad you think so.  I tend to agree, but I was clarifying for
those that might have a different definition.




From MAILER-DAEMON Sun Jun 11 17:48:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKAiy-0003O8-RP
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 17:48:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53156)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKAix-0003O1-6Z
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:48:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKAit-00071f-82
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:48:43 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:10150
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKAit-00071H-2B
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:48:39 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH24291; Sun, 11 Jun 2017 17:48:36 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HOW96408 (AUTH cpr);
	Sun, 11 Jun 2017 17:48:36 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: A background ssh can take over the tty from bash?
To: Clark Wang <dearvoid@gmail.com>, "bash.bug list" <bug-bash@gnu.org>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
Date: Sun, 11 Jun 2017 17:48:37 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.11.205717:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_700_799, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 21:48:44 -0000

On 6/10/17 10:19 AM, Clark Wang wrote:

> If I kill the "ssh -o ControlMaster=no -o ControlPath=/tmp/socket.tmp
> 127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my input
> again. Seems like the background "ssh" at tty #1 is consuming all input. I
> cannot understand this since it should be stopped by SIGTTIN if it tries to
> read from the tty.

This has come up before. You need to use `ssh -n' to avoid it reading from
stdin. Processes can ignore SIGTTIN, and ssh does so to avoid being stopped
if it reads from the tty while in the background.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 11 17:51:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKAlt-0003ak-AL
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 17:51:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53452)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKAlr-0003aF-4r
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:51:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKAln-0007cj-5f
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:51:43 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:46682
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKAlm-0007cb-W2
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:51:39 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH06656; Sun, 11 Jun 2017 17:51:32 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HOW98211 (AUTH cpr);
	Sun, 11 Jun 2017 17:51:32 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs w/ 'readonly -f' & 'export -f
To: L A Walsh <bash@tlinx.org>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593ACE9A.4080100@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <2b53b178-eeab-49b3-89ed-726a45e619e0@case.edu>
Date: Sun, 11 Jun 2017 17:51:34 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <593ACE9A.4080100@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.11.211816:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_600_699,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 21:51:44 -0000

On 6/9/17 12:36 PM, L A Walsh wrote:
> Greg Wooledge wrote:
>> I don't know what you mean. A function is not a name=value pair.
> The name is the name of the function, the value is
> what the function does.
>   declare -f hw='() { echo "Hello World\n"; }'

No. The world does not need another way to declare shell functions.
If you want something like that to work, there are ways you can make it
work using shell variables and `eval'.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 11 17:58:10 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKAs6-0004nA-7J
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 17:58:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54362)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKAs4-0004mk-A8
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:58:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKAs0-0000qZ-BK
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:58:08 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:32922
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKArz-0000pP-U3
	for bug-bash@gnu.org; Sun, 11 Jun 2017 17:58:04 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5BLvhl7063598; Sun, 11 Jun 2017 14:57:47 -0700
Message-ID: <593DBCD7.30702@tlinx.org>
Date: Sun, 11 Jun 2017 14:57:43 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: "Chris F.A. Johnson" <chris@cfajohnson.com>
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
In-Reply-To: <alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 21:58:09 -0000



Chris F.A. Johnson wrote:
> On Fri, 9 Jun 2017, L A Walsh wrote:
>> ----
>>   First problem: If you are assigning a string to a variable,
>> you need to put quotes around the string.
>
>    You don't need to quote it unless it contains literal whitespace.
---
    Not true if you want to reproduce the string as output by
"declare".  Since declare doesn't output the literal value in a
variable, but an expanded one, you need to put quotes around any
var that you intend to expand with 'declare'.

Greg's example:

   imadev:~$ x=$'foo\nbar'
   imadev:~$ declare -p x
   declare -- x="foo
   bar"

Shows that "declare" isn't quoting its output such that it can be 
used for assignment to a var, or as 'read' input.

To do that, you can use "printf %q" -- as in:

  x=$'foo\nbar'
  printf -v qx "%q" "$x"
  printf "%s\n" "$qx"
  $'foo\nbar'

I used double quotes around the original:

  x="$'foo\nbar'"

Which gives:

  printf "%s\n" "$x"
  $'foo\nbar'

The exact same output.

I.e. you need to double quote Greg's input for it to be re-usable as input.

 










From MAILER-DAEMON Sun Jun 11 18:06:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKB0S-00065j-Lb
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 18:06:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55814)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKB0Q-00065d-Cr
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:06:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKB0N-0003F9-7L
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:06:46 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:41679
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKB0N-0003F2-1M
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:06:43 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANM30872; Sun, 11 Jun 2017 18:06:27 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HOK28352 (AUTH cpr);
	Sun, 11 Jun 2017 18:06:27 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Greg Wooledge <wooledg@eeg.ccf.org>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
To: L A Walsh <bash@tlinx.org>, "Chris F.A. Johnson" <chris@cfajohnson.com>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>
	<593DBCD7.30702@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <5ba7a522-905a-5670-e587-1f73892a3a31@case.edu>
Date: Sun, 11 Jun 2017 18:06:29 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <593DBCD7.30702@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.11.205717:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1200_1299,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 22:06:47 -0000

On 6/11/17 5:57 PM, L A Walsh wrote:
> 
> 
> Chris F.A. Johnson wrote:
>> On Fri, 9 Jun 2017, L A Walsh wrote:
>>> ----
>>>   First problem: If you are assigning a string to a variable,
>>> you need to put quotes around the string.
>>
>>    You don't need to quote it unless it contains literal whitespace.
> ---
>    Not true if you want to reproduce the string as output by
> "declare".  Since declare doesn't output the literal value in a
> variable, but an expanded one, you need to put quotes around any
> var that you intend to expand with 'declare'.
> 
> Greg's example:
> 
>   imadev:~$ x=$'foo\nbar'
>   imadev:~$ declare -p x
>   declare -- x="foo
>   bar"
> 
> Shows that "declare" isn't quoting its output such that it can be used for
> assignment to a var, or as 'read' input.

You are misunderstanding what that is supposed to do, or ignoring it.
`declare -p' quotes its output in a way that allows it to be reused as
shell input. Executing the output of `declare -p' will recreate the
variable with an identical value.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 11 18:32:04 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKBOu-0002NK-1b
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 18:32:04 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58266)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKBOr-0002MO-Rs
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:32:02 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKBOm-0001FW-T3
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:32:01 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:34266
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKBOm-0001FC-JH
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:31:56 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5BMVbOG066709; Sun, 11 Jun 2017 15:31:39 -0700
Message-ID: <593DC4C9.5070303@tlinx.org>
Date: Sun, 11 Jun 2017 15:31:37 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: "Chris F.A. Johnson" <chris@cfajohnson.com>,
	Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org>
	<5939D435.9050900@tlinx.org>	<20170609122511.GM3691@eeg.ccf.org>
	<593B26C5.6070002@tlinx.org>	<alpine.DEB.2.10.1706091932330.10104@cfajohnson.ca>	<593DBCD7.30702@tlinx.org>
	<5ba7a522-905a-5670-e587-1f73892a3a31@case.edu>
In-Reply-To: <5ba7a522-905a-5670-e587-1f73892a3a31@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 22:32:02 -0000

Chet Ramey wrote:
>
>  You are misunderstanding what that is supposed to do, or ignoring it.
>  `declare -p' quotes its output in a way that allows it to be reused as
>  shell input. Executing the output of `declare -p' will recreate the
>  variable with an identical value.

Re-use as shell input?  That's a bit vague.  As the right-hand
expression for an assignment? or something one reads in?
There are plenty of examples that could qualify as being "shell input"
that don't work:


exec of output:

    > x=$'foo\nbar'
    > exec $(declare -p x)
    bash: exec: declare: not found


Assign & exec w/ quotes:

    > a=$(declare -p x)
    > exec "$a"
    bash: exec: declare -- x="foo
    bar": not found


Assign&exec w/o quotes:

    > exec $a
    bash: exec: declare: not found


Assign & try direct interpretation of value:

    > $a
    bash: declare: `bar"': not a valid identifier

Same w/quoteS:

    > "$a"
    bash: $'declare -- x="foo\nbar"': command not found


Reading output:

    > declare -p x|while read def; do
    > echo "def=$def"
    > done
    def=declare -- x="foo
    def=bar"

Reading it via proc-subst:

    > read a< <(declare -p x)
    Ishtar:law> echo "$a"
    declare -- x="foo

(I'm running out of ideas)...

It's not very easy to discern what you mean.  I'm sure
it is easy for someone who already knows the answer --
trivial even, but what type of bash-input are you referring to?






From MAILER-DAEMON Sun Jun 11 18:51:37 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKBhp-000668-2u
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 18:51:37 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33061)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKBhn-000662-08
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:51:35 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKBhj-0008Jj-VR
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:51:35 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:35044
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKBhj-0008Is-Kg
	for bug-bash@gnu.org; Sun, 11 Jun 2017 18:51:31 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5BMpQ13068006; Sun, 11 Jun 2017 15:51:28 -0700
Message-ID: <593DC96E.101@tlinx.org>
Date: Sun, 11 Jun 2017 15:51:26 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Charles Daffern <seejay.11@gmail.com>
CC: bug-bash@gnu.org
Subject: Re: consistency probs var & function re-use
References: <5939D1AD.9010909@tlinx.org>
	<5939D435.9050900@tlinx.org>	<20170609122511.GM3691@eeg.ccf.org>
	<593B26C5.6070002@tlinx.org>
	<4acada15-9482-e024-d8f6-de431fb8da58@gmail.com>
In-Reply-To: <4acada15-9482-e024-d8f6-de431fb8da58@gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 11 Jun 2017 22:51:35 -0000

Charles Daffern wrote:
>>    First problem: If you are assigning a string to a variable,
>> you need to put quotes around the string.  That shows that "-p"
>> doesn't insert newlines:
>>
>>  > x="$'foo\nbar'"
>>  > declare -p x
>>  declare -- x="\$'foo\\nbar'"
>>     
>
> You do not have any newlines in that string, so of course the
> demonstration with -p will show no newlines.
>   
Right.  you should be addressing your comment to 'Greg Wooledge',
who said:

    Are you allergic to newlines?  declare -p uses raw newlines in its output
    whenever it feels they are appropriate.  Even in ordinary shell variables:

    imadev:~$ x=$'foo\nbar'
    imadev:~$ declare -p x
    declare -- x="foo
    bar"

      

------

I was pointing out that the reason 'declare' used a newline, was that he
had not quoted the input to 'x', which is expanded to a newline
before it is assigned to 'x'.

Or did you miss that post?
>   
>>> What are you trying to do? 
>>>       
>> Read var & func defs via a 'read' of 1 line.
>>     
>
> In your variable "x" above, you have encoded the string in a format
> which contains no raw newlines and which can be "eval"ed to produce the
> original contents.
> Why don't you encode the function the same way?
>   
I didn't encode the newline above, Greg did.

I used a format with NO newlines:

   hh(){ echo "hi"; }
which gets printed out as:

  declare -f hh
  hh ()
  {
      echo "hi"
  }
----

I.e. it wasn't that I wanted to embed newlines in the function, but that
I wanted it to print out the same way it was input.



From MAILER-DAEMON Sun Jun 11 21:00:34 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKDic-0007lb-9y
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 21:00:34 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48925)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dKDiZ-0007l8-Jb
	for bug-bash@gnu.org; Sun, 11 Jun 2017 21:00:32 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dKDiU-0004Wd-QD
	for bug-bash@gnu.org; Sun, 11 Jun 2017 21:00:31 -0400
Received: from out03.mta.xmission.com ([166.70.13.233]:41347)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <gazelle@xmission.com>)
	id 1dKDiU-0004VU-KD
	for bug-bash@gnu.org; Sun, 11 Jun 2017 21:00:26 -0400
Received: from mx02.mta.xmission.com ([166.70.13.212])
	by out03.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>)
	id 1dKDiG-0004qo-7K; Sun, 11 Jun 2017 19:00:12 -0600
Received: from shell.xmission.com ([166.70.8.4])
	by mx02.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>)
	id 1dKDiG-0001Sa-34; Sun, 11 Jun 2017 19:00:12 -0600
Received: from gazelle by shell.xmission.com with local (Exim 4.86_2)
	(envelope-from <gazelle@xmission.com>)
	id 1dKDiF-0005bn-R3; Sun, 11 Jun 2017 19:00:11 -0600
From: gazelle@xmission.com
To: bug-bash@gnu.org,bash@packages.debian.org
Subject: Multiline commands do not survive history -w/-r
Message-Id: <E1dKDiF-0005bn-R3@shell.xmission.com>
Date: Sun, 11 Jun 2017 19:00:11 -0600
X-XM-SPF: eid=1dKDiG-0001Sa-34; ; ; mid=<E1dKDiF-0005bn-R3@shell.xmission.com>;
	; ; hst=mx02.mta.xmission.com; ; ; ip=166.70.8.4; ; ;
	frm=gazelle@xmission.com; ; ; spf=neutral
X-SA-Exim-Connect-IP: 166.70.8.4
X-SA-Exim-Mail-From: gazelle@xmission.com
X-SA-Exim-Scanned: No (on mx02.mta.xmission.com);
	SAEximRunCond expanded to false
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 166.70.13.233
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 01:00:32 -0000

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-pc-linux-gnu' -DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H   -I.  -I../. -I.././include -I.././lib  -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wall
uname output: Linux shell 4.4.0-79-generic #100-Ubuntu SMP Wed May 17 19:58:14 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-pc-linux-gnu

Bash Version: 4.3
Patch Level: 48
Release Status: release

Description:
	Multiline commands (i.e., a command with embedded newlines) do not survive
	intact when written out to the history file and then reloaded.

Repeat-By:
	See attached script file:

Recording to file 'typescript' at: Sun Jun 11 18:51:27 2017.
~s to stop recording, ~r to resume

spawn bash
gazelle@shell:~$ HISTFILE=/tmp/zzz
gazelle@shell:~$ history -c;history -r;history
gazelle@shell:~$ gawk 'BEGIN {
> print "hello, world"
> }'
hello, world
gazelle@shell:~$ history
    1  gawk 'BEGIN {
print "hello, world"
}'
    2  history
gazelle@shell:~$ !1
gawk 'BEGIN {
print "hello, world"
}'
hello, world
gazelle@shell:~$ history -w
gazelle@shell:~$ history -c;history -r;history
    1  gawk 'BEGIN {
    2  print "hello, world"
    3  }'
    4  history
    5  gawk 'BEGIN {
    6  print "hello, world"
    7  }'
    8  history -w
gazelle@shell:~$ !5
gawk 'BEGIN {
> ^C
gazelle@shell:~$ exit


Fix:
	I think there needs to be some kind of "magic character" in the history file
	that represents a newline - which would be handled by the -w and -r options
	of the history command.



From MAILER-DAEMON Sun Jun 11 22:25:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKF2j-00075c-JB
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 22:25:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56078)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKF2h-00075W-9O
	for bug-bash@gnu.org; Sun, 11 Jun 2017 22:25:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKF2g-0003H5-5a
	for bug-bash@gnu.org; Sun, 11 Jun 2017 22:25:23 -0400
Received: from mail-pf0-x22b.google.com ([2607:f8b0:400e:c00::22b]:34158)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dKF2f-0003Gr-UP
	for bug-bash@gnu.org; Sun, 11 Jun 2017 22:25:22 -0400
Received: by mail-pf0-x22b.google.com with SMTP id 15so18687128pfc.1
	for <bug-bash@gnu.org>; Sun, 11 Jun 2017 19:25:19 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=OAWiVsyq7x07KhDUlpmSYIUEZ8qJANyJrxYDmICsfdo=;
	b=SsAJvgtCGlCpLzgmUWk7SWBf6aP8ADECgR1rY0bChkaC1c0KBY7MuP4VMq9z2mSNtR
	Vlu1mx0O72diuPmbtO67X1yaC6v5buqJi+qwYRbE/ZXscaoO3iFs1o8da6/tVR9CFDmO
	rmjBDEd0x2egI2wK4/pu3dmKBXmhy4et/3YYtoBKGLD/95c3np3m90tXJcm24M+GBtkF
	6Q2usbORKYRisI0hMN60MRTRa4zHJuyGEeyPrPf1pyaH2mgHiy4jWlebpFlVEB+UpUY+
	jJPRK8GXKXWIEidFPVeFafi9vFsDymItLHxZBaPHmuxHJ+xa4pmf32Cr3hmWaGEoCS03
	RYGQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=OAWiVsyq7x07KhDUlpmSYIUEZ8qJANyJrxYDmICsfdo=;
	b=mcemqxEIarb3s9+g5lKejFS9Hmfu96r7JQ7GfvBBZj65Z7dK2RwHClrVymzBLSH6Ly
	3adUQ8GDIrUAeQPvbRsRDATL08KXhaipyeR4Y5XKLsM4wwODxtsJ7PMrq8FeWhv9dFVc
	TYk3y69oBM9ty9e0SQBFBfd2aEw3qd9YeJ7JH5g2gkbdak7k6N+WQZoqNMkVuaP+oZFf
	cxlnJOvVwJf94PUgvZoEXQRNBri+SVgiSryK6S0qoh1NFlIseuFKkv8e4RiKnnP3zra7
	4QJgWnchBeIci2kJOCnewZAqRGMCJ1wOsRBqO7//kBUwgGZULJtbcD7zHk8xhGCydCGw
	XThA==
X-Gm-Message-State: AODbwcA0PtK9f5f6+Py1ZcivCaQLuNZHPEVNyCKPEwni9aiGGIQfGJqe
	4IU5fafmACSvsNNw7P91OY4z5MAX8g==
X-Received: by 10.84.224.205 with SMTP id k13mr54409848pln.279.1497234319185; 
	Sun, 11 Jun 2017 19:25:19 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.153.219 with HTTP; Sun, 11 Jun 2017 19:24:38 -0700 (PDT)
In-Reply-To: <b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
From: Clark Wang <dearvoid@gmail.com>
Date: Mon, 12 Jun 2017 10:24:38 +0800
Message-ID: <CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: Chet Ramey <chet.ramey@case.edu>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22b
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 02:25:24 -0000

On Mon, Jun 12, 2017 at 5:48 AM, Chet Ramey <chet.ramey@case.edu> wrote:

> On 6/10/17 10:19 AM, Clark Wang wrote:
>
> > If I kill the "ssh -o ControlMaster=no -o ControlPath=/tmp/socket.tmp
> > 127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my
> input
> > again. Seems like the background "ssh" at tty #1 is consuming all input.
> I
> > cannot understand this since it should be stopped by SIGTTIN if it tries
> to
> > read from the tty.
>
> This has come up before. You need to use `ssh -n' to avoid it reading from
> stdin. Processes can ignore SIGTTIN, and ssh does so to avoid being stopped
> if it reads from the tty while in the background.
>

I've checked the ssh process and it does not catch SIGTTIN and that's why
I'm confused.

$ ps p937
   PID TTY      STAT   TIME COMMAND
   937 pts/2    S      0:00 ssh -o ControlMaster=no -o
ControlPath=/tmp/socket.ssh 127.0.0.1 sleep 9999
$ ps s p937
  UID    PID          PENDING          BLOCKED          IGNORED
CAUGHT STAT TTY        TIME COMMAND
    0    937 0000000000000000 0000000000000000 0000000000001000
0000000188004003 S    pts/2      0:00 ssh -o ControlMaster=no -o
ControlPath=/tmp/socket.ssh 127.0.0.1 sleep 9999
$

The decoded sig masks are:

PENDING (0000000000000000):
BLOCKED (0000000000000000):
IGNORED (0000000000001000):
  13 PIPE
CAUGHT (0000000188004003):
   1 HUP
   2 INT
  15 TERM
  28 WINCH
  32
  33

From MAILER-DAEMON Sun Jun 11 23:33:13 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKG6L-0005Rp-BM
	for mharc-bug-bash@gnu.org; Sun, 11 Jun 2017 23:33:13 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42160)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKG6J-0005Rj-Tl
	for bug-bash@gnu.org; Sun, 11 Jun 2017 23:33:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKG6G-0000iL-R3
	for bug-bash@gnu.org; Sun, 11 Jun 2017 23:33:11 -0400
Received: from mail-ot0-x232.google.com ([2607:f8b0:4003:c0f::232]:33785)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dKG6G-0000hp-LD
	for bug-bash@gnu.org; Sun, 11 Jun 2017 23:33:08 -0400
Received: by mail-ot0-x232.google.com with SMTP id k4so60356508otd.0
	for <bug-bash@gnu.org>; Sun, 11 Jun 2017 20:33:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=f1mmCQ4dW3VUTiK4LkB8mAwVpY79MuPs3tywQPOH9Co=;
	b=B2EZ52thVpEUbvA+zfb0rWsAZ/DcU/yY8Usnoag2/UeOl/rlHa7S8Q+Ph0zUIaxN5J
	+xpQQWJF0Pt4JEm/sNkScMHjpXRrP4spqMxczFqwLdaAlvg1JaIqsShKPzETwjTHkmQq
	2lbSHXO8u/h92USv6fi9F84wrcdZP/iLcDJZOdV4poBTml2jkDL8Tf7vAmiudT/rf6rr
	65y4HoOvO8jmIj95SfnTklNwi/SDYV5SS8rU2M83e4HTfUODckComT1SEtF4thkevcmk
	BDN5aFbeeWB8A89ODTtrqfpwoOqeTHxP+7J3mHe8QyY0RaocjiPxHKfPEx5kLXi9LHFu
	XuAg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=f1mmCQ4dW3VUTiK4LkB8mAwVpY79MuPs3tywQPOH9Co=;
	b=UX8Ntp/oMBV5di2LJZp0CuQtMFiatK72M2OtRxmrN6XhYQK8L/TdoZO4X/dkC7cGan
	0jcp0Ck+TktcDinQadc5HNLSAE70iOJ0DOaX4phvpDv7uerxX601PHaVoT5QG8eVraCN
	qqDQj3vTQamCjXdf9FwgZLIsNvsVm7n9/99jGK3JkdlpPHVL1OKWuLwYfiGiaCMldqgz
	S1rIWwDRFJnKC3MK8l6B1vn5t1cDFoFnvlyYVukN8Efxm0u2TOvnu4yNuvSFPOe/HkPg
	+B1J+uIh5lXSSIb4wgH7VfyXu39boBDWbhW48wy3sX2q/MDJK5MTxkIW7tOQLRbWmW++
	20HA==
X-Gm-Message-State: AKS2vOzJbVn4pXzdZX+rvuwwjclUfl233pNqghYABFt4ZesWXxXRJROr
	ryrG2T55xGcdJA==
X-Received: by 10.157.39.14 with SMTP id r14mr30715559ota.11.1497238386446;
	Sun, 11 Jun 2017 20:33:06 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	a67sm4321127oif.37.2017.06.11.20.33.05
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 11 Jun 2017 20:33:05 -0700 (PDT)
Date: Sun, 11 Jun 2017 22:33:02 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Clark Wang <dearvoid@gmail.com>
Cc: Chet Ramey <chet.ramey@case.edu>, "bash.bug list" <bug-bash@gnu.org>
Subject: Re: A background ssh can take over the tty from bash?
Message-ID: <20170612033302.izffvovienyry5iw@debian>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 03:33:12 -0000

On Mon, Jun 12, 2017 at 10:24:38AM +0800, Clark Wang wrote:
[...]
> I've checked the ssh process and it does not catch SIGTTIN and that's why
> I'm confused.

Even if that were the case, what makes you think this is a bash bug?

Bash is not responsible for misbehaving children.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 12 00:12:01 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKGht-0005Hy-Bz
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 00:12:01 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47218)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKGhr-0005Hn-2h
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:11:59 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKGhn-00036e-Uo
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:11:59 -0400
Received: from mail-ot0-x229.google.com ([2607:f8b0:4003:c0f::229]:33315)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dKGhn-00036X-Ph
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:11:55 -0400
Received: by mail-ot0-x229.google.com with SMTP id k4so60590573otd.0
	for <bug-bash@gnu.org>; Sun, 11 Jun 2017 21:11:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=4ijUoz6k+IcCNHUDD32+Nl9QdniYYuvA9LkaEqj6FoE=;
	b=O1NUga8P2Q/oAW2s9a2LTHSBV1oZI3JlD3Q90M1pK2agjRcUaWyY7hxzjI9Nc6vVXL
	wCds/D3ccULyH1ZYQ9zsTFwVCFEo7Ybv+LTYoUAvFYDK4XEUjmaSIiKA7Saw8fxhM1T2
	Ie7rz0FRD1BkTYEhrKBNUMg6/NnhAnucobicckP4A3H6VIR7KqPwJwyWo6ZgPzX5CPVE
	MAK2HqMQwiXmYrBW6t301v3XDX8uHH2ZtfXCHvBHzqXAV0PkL3qOqWKHo6gUEW9SlDHd
	btKeAfISPMgSKl8KhLNPTt1UHx/8zNMcupGF2gdLUY9J3zsOx9EPssrDeJT4XGksSD48
	VZbg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=4ijUoz6k+IcCNHUDD32+Nl9QdniYYuvA9LkaEqj6FoE=;
	b=VQ+bguquwUKhHCti5cA9rQPm4kzgXqYgw8zJUECBYEmgBHVWIUPguI6YQWoutehqDK
	jWs8q7EwYtpX3dPZ/4d5VrpSHkqJDIoMnIhZraJxYVhPJdGa3vn+KSVkOAU1tL3KE4Fr
	oBuRvEVKmfxjXwCbA/SPy7wMWUUTrsQUy2ZjB7kMis1o57vQQp/jKkPnigbKUqPxudSS
	n54cFZW6cs5r5v/gJeOgCP9ldo1f0WucWnkyRCwF/wv2EkVnpo2OTl5FKBPZ080G6mO7
	6yonSVX1HFrPPRQO/rzLzqRBpbgod4Ai1OyiRIDzNB1NROhFRk5WrrOdxawikmEdj03I
	LBag==
X-Gm-Message-State: AODbwcDCMZCMMCPGnWBLEGOihgpAYXHE9MYxNYHumnlnzfMg1ezEn+W4
	0JtIVDudApHr1w==
X-Received: by 10.157.82.20 with SMTP id e20mr25403632oth.248.1497240714771;
	Sun, 11 Jun 2017 21:11:54 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id u76sm4398880ota.8.2017.06.11.21.11.53
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 11 Jun 2017 21:11:54 -0700 (PDT)
Date: Sun, 11 Jun 2017 23:11:52 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: gazelle@xmission.com
Cc: bug-bash@gnu.org, bash@packages.debian.org
Subject: Re: Multiline commands do not survive history -w/-r
Message-ID: <20170612041152.3szrhpgu3gnkocdn@debian>
References: <E1dKDiF-0005bn-R3@shell.xmission.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <E1dKDiF-0005bn-R3@shell.xmission.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 04:12:00 -0000

On Sun, Jun 11, 2017 at 07:00:11PM -0600, gazelle@xmission.com wrote:
[...]
> Bash Version: 4.3
> Patch Level: 48
> Release Status: release
> 
> Description:
> 	Multiline commands (i.e., a command with embedded newlines) do not survive
> 	intact when written out to the history file and then reloaded.

Have you tried bash 4.4?

See: http://lists.gnu.org/archive/html/bug-bash/2015-12/msg00202.html

  dualbus@debian:~$ history -c
  dualbus@debian:~$ declare -p HISTFILE HISTTIMEFORMAT
  declare -- HISTFILE="/tmp/zzz"
  declare -- HISTTIMEFORMAT="%s"
  dualbus@debian:~$ echo 'a
  > b
  > c'
  a
  b
  c
  dualbus@debian:~$ history -w
  dualbus@debian:~$ history -c; history -r; HISTTIMEFORMAT= history
      1  declare -p HISTFILE HISTTIMEFORMAT
      2  echo 'a
  b
  c'
      3  history -w

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 12 00:35:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKH54-00012C-Iv
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 00:35:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49393)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKH51-00011s-Iw
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:35:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKH4y-0000ra-Ei
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:35:55 -0400
Received: from mail-oi0-x232.google.com ([2607:f8b0:4003:c06::232]:34592)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dKH4y-0000rP-8P
	for bug-bash@gnu.org; Mon, 12 Jun 2017 00:35:52 -0400
Received: by mail-oi0-x232.google.com with SMTP id s64so5702678oif.1
	for <bug-bash@gnu.org>; Sun, 11 Jun 2017 21:35:52 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=qSTm+g52Pqsy7MYPRSH4PgIg2G1HzlgN55IzmXo4X1I=;
	b=oD/fJsUNTzB9m1Uj0NscNmKAT7DLx4IdTIU9ZOdgD+T/8BeAqgAKOzoXJH2qfZyzmT
	3TRbBuDwCwcmEo7DgJXCq1IV2h6cnQx9yJhOK6boVjNlk0imDnpfyHL/2/UUvIvLjrI0
	S11nHOoihC13BocU0Ezz1G4f9+mP5R0uQRZI52yPr+f1saZrIzPE7/aoK6AFkl2Xp4QF
	WG04MBG5kKbXfI/0yN/5fFa0TUN3V+0KN0pykY2HvYNhZwNctPEYuRR0WwjGWO3Bovft
	6Lh/GnecA7L+xvTgsrGIrOZQBi5nd/I1Sip0M4DBb7+dUXDHHc/DNEPITB6Vjjmb0R06
	h29A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=qSTm+g52Pqsy7MYPRSH4PgIg2G1HzlgN55IzmXo4X1I=;
	b=RR+c2USZWI699j1MDBUx8FX1BbIsyxmAyKIAfNSy0OnKn4w5pLtN4Cc1Grcvk7YUtA
	e/xfbNQYP0ScYikW1lkAo0gdQPg+CqIY/2UdDG1YyN8wq0pe20vLjKy8uVDrVy/tK9RK
	gHYeIVCMDbiaZTJIPlxyiTjgxa/v7Cjo7OQdcg7ctOmVwZQj1u9c7Ntb7KtCrxxWqDab
	wJG1H/oU+O7B/TGNEzjVggzWGuHFmZmReC0KxJePjvjr5J5bc9OYKX7zUJChe9ea+nNn
	iAm+i17yUM0vGUCoJn3rezISDVmCzqtJSv/CGTpszIlkvHY06opEIS5GHYLNxfrsHxs5
	hf9A==
X-Gm-Message-State: AODbwcACPQPQgUUQTKSkEkqMKvMumewRuESfCKG+Hpodc7tdhwZXbx7k
	pQTuXMFqZOAXNg==
X-Received: by 10.202.81.145 with SMTP id f139mr12807711oib.81.1497242151539; 
	Sun, 11 Jun 2017 21:35:51 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	q184sm4381783oib.12.2017.06.11.21.35.50
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 11 Jun 2017 21:35:50 -0700 (PDT)
Date: Sun, 11 Jun 2017 23:35:49 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Paul Peet <peetpaul69@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Subject: Re: Buffer corruption when the terminal is resized.
Message-ID: <20170612043549.k25sr26l24ge6so5@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 04:35:56 -0000

On Sun, Jun 11, 2017 at 12:29:33AM +0200, Paul Peet wrote:
[...]
> Unfortunately, I am still getting the same behavior as before (This
> also happens with xterm for some reason.)

Please do consider that Readline has little knowledge about what has
been written to the terminal. That's the terminal's reponsability.

What Readline does is to write your prompt, and place the cursor right
beside the prompt. In both of your animations, the prompt seems to be
rendered fine, I can't really tell because the animation is a bit fast.

Does the same problem happen if you use a different shell? (zsh, mksh,
dash, ksh93).

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 12 10:48:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKQe1-0006wD-6o
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 10:48:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56427)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKQdy-0006w3-6X
	for bug-bash@gnu.org; Mon, 12 Jun 2017 10:48:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKQdt-00072V-6S
	for bug-bash@gnu.org; Mon, 12 Jun 2017 10:48:38 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:46369
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKQdt-00071Y-1d
	for bug-bash@gnu.org; Mon, 12 Jun 2017 10:48:33 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANM50060; Mon, 12 Jun 2017 10:48:27 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFK48037 (AUTH cpr);
	Mon, 12 Jun 2017 10:48:24 -0400 (EDT)
From: Chet Ramey <chet.ramey@case.edu>
Subject: Re: A background ssh can take over the tty from bash?
Reply-To: chet.ramey@case.edu
To: Clark Wang <dearvoid@gmail.com>
Cc: chet.ramey@case.edu, "bash.bug list" <bug-bash@gnu.org>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
Message-ID: <68fa4e59-e3cc-173b-17c3-1af39d6a44f3@case.edu>
Date: Mon, 12 Jun 2017 10:48:24 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.141216:17:8.317, ip=,
	rules=__HAS_FROM, FROM_EDU_TLD, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __HAS_REPLYTO, __TO_MALFORMED_2,
	__TO_NAME, __TO_NAME_DIFF_FROM_ACC, __HAS_CC_HDR,
	__MULTIPLE_RCPTS_CC_X2, __CC_NAME,
	__CC_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1400_1499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 14:48:39 -0000

On 6/11/17 10:24 PM, Clark Wang wrote:
> On Mon, Jun 12, 2017 at 5:48 AM, Chet Ramey <chet.ramey@case.edu
> <mailto:chet.ramey@case.edu>> wrote:
> 
>     On 6/10/17 10:19 AM, Clark Wang wrote:
> 
>     > If I kill the "ssh -o ControlMaster=no -o ControlPath=/tmp/socket.tmp
>     > 127.0.0.1 sleep 9999" then tty #1 (pts/11) would be able to accept my input
>     > again. Seems like the background "ssh" at tty #1 is consuming all input. I
>     > cannot understand this since it should be stopped by SIGTTIN if it tries to
>     > read from the tty.
> 
>     This has come up before. You need to use `ssh -n' to avoid it reading from
>     stdin. Processes can ignore SIGTTIN, and ssh does so to avoid being stopped
>     if it reads from the tty while in the background.
> 
> 
> I've checked the ssh process and it does not catch SIGTTIN and that's why
> I'm confused.

OK. This has gone beyond the realm of a bash bug. I'm pretty sure that
previous versions of ssh ignored or caught SIGTTIN, but it must not do that
now.

Since ssh has a handle on its controlling terminal, it must do something
that allows it to read from it even if it's not in the foreground process
group. In any event, -n is the way to deal with that.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 11:10:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKQym-0002Q2-GF
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 11:10:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33964)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKQyj-0002Ne-L0
	for bug-bash@gnu.org; Mon, 12 Jun 2017 11:10:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKQyg-0005up-BS
	for bug-bash@gnu.org; Mon, 12 Jun 2017 11:10:05 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:16063
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKQyg-0005uV-5Q
	for bug-bash@gnu.org; Mon, 12 Jun 2017 11:10:02 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMC49373; Mon, 12 Jun 2017 11:09:39 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFK52238 (AUTH cpr);
	Mon, 12 Jun 2017 11:09:38 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Multiline commands do not survive history -w/-r
To: gazelle@xmission.com, bug-bash@gnu.org, bash@packages.debian.org
References: <E1dKDiF-0005bn-R3@shell.xmission.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <a214366d-9325-d767-abab-ec444b7ad2c3@case.edu>
Date: Mon, 12 Jun 2017 11:09:38 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <E1dKDiF-0005bn-R3@shell.xmission.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.12.143016:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1000_1099, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	SINGLE_URI_IN_BODY, __PHISH_SPEAR_STRUCTURE_1,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 15:10:06 -0000

On 6/11/17 9:00 PM, gazelle@xmission.com wrote:

> Bash Version: 4.3
> Patch Level: 48
> Release Status: release
> 
> Description:
> 	Multiline commands (i.e., a command with embedded newlines) do not survive
> 	intact when written out to the history file and then reloaded.

Yes, the history file format is explicitly line-oriented.  Bash-4.4
introduced a heuristic that allows multi-line history entries to work
without changing the file format or introducing an additional special
character.  From the NEWS file:

k.  If readline reads a history file that begins with `#' (or the value of
    the history comment character) and has enabled history timestamps, the
    history entries are assumed to be delimited by timestamps.  This allows
    multi-line history entries.

You enable history file timestamp writing by having HISTTIMEFORMAT set. It
can have a null value.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 12:17:19 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKS1m-0001ww-Vz
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 12:17:19 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55542)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKS1j-0001m1-VY
	for bug-bash@gnu.org; Mon, 12 Jun 2017 12:17:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKS1i-0006DD-Og
	for bug-bash@gnu.org; Mon, 12 Jun 2017 12:17:15 -0400
Received: from mail-pf0-x22e.google.com ([2607:f8b0:400e:c00::22e]:34284)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dKS1i-0006D1-IS
	for bug-bash@gnu.org; Mon, 12 Jun 2017 12:17:14 -0400
Received: by mail-pf0-x22e.google.com with SMTP id 15so25591197pfc.1
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 09:17:14 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=hCsmLixDAvuhlksAXDhk41OxPsrSg7V17y8bks3+VP8=;
	b=IWmQ5i1GFBZ54277PrGuZ7syqyKJj97Z5y9Dwmg1PuxLzP0/e62IzTIFtQSnFuJ+bX
	Jl2AaY89q/LXXDzz55EYXYvpF8Lqn9+6Nie8hdOhwky09wHDnQRh7PWQ5zVv6/SFVIOB
	jcUnbd+JfBvIfS2ydSEh7K1QpGBGEvjneTrGmwcIuLR9zITx9BmOJinTAxXVPkCEvw1o
	AsIW2qHAwEZYP9BKqGXo8Icrn6dyjEHu3AYVFw7FESMFtB8f5ipmoXJoRw0OLO/4c561
	i1FBaU/Q8cNBcKh586AIEKfukIQWWK6SGt/E1a7+n1/eSzNeDD6OJsFvcV3J8JnY/6lL
	NH6w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=hCsmLixDAvuhlksAXDhk41OxPsrSg7V17y8bks3+VP8=;
	b=rdl0Qm6p7MdBw0xbaLhl85KSFK8x5EF5LRYDeV0jmxXAiFKtByPlLkKJg3o48LWQpE
	2j5DgVJxE8MZwm16jwd1XIYJ65mjxUaUE15ZdJ+bwS4TXzxHpvkm8+zE3ZAPXGMAQDa1
	G4P5TfYSVDpasZrf7Vwvd3uc8pidczi1/70KACgdhIAhJ0yunovdqYYh/ARJgNVGn2XK
	UqF3HeR14t7xKIf2ZvWZKK1zDX8NCZw8OvJJCCIly+auY3UkQ1sNlKSPZyZke4zrIwsj
	pvLmaDCQgiVsec+u35B6Clg2H9WnLTxzqzS6bgs9F6pFgK3VSGaC9wxmlxzTncc+pOkd
	Ffdg==
X-Gm-Message-State: AODbwcDZ091tlJAYpNRj1oM5JgffvsqB2sUuiUsSLhY4y8K46eR/I6pt
	uzAjdurSeIphe9sWzfMr7qxlJeT9Tw==
X-Received: by 10.84.224.205 with SMTP id k13mr58121516pln.279.1497284233547; 
	Mon, 12 Jun 2017 09:17:13 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.140.23 with HTTP; Mon, 12 Jun 2017 09:16:33 -0700 (PDT)
In-Reply-To: <68fa4e59-e3cc-173b-17c3-1af39d6a44f3@case.edu>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
	<68fa4e59-e3cc-173b-17c3-1af39d6a44f3@case.edu>
From: Clark Wang <dearvoid@gmail.com>
Date: Tue, 13 Jun 2017 00:16:33 +0800
Message-ID: <CADv8-ogtB73xqPqFONM9JtTh2pTpw_s_EFqRYFHvcrtfaN1=AA@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: Chet Ramey <chet.ramey@case.edu>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::22e
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 16:17:17 -0000

On Mon, Jun 12, 2017 at 10:48 PM, Chet Ramey <chet.ramey@case.edu> wrote:

> >
> >     This has come up before. You need to use `ssh -n' to avoid it
> reading from
> >     stdin. Processes can ignore SIGTTIN, and ssh does so to avoid being
> stopped
> >     if it reads from the tty while in the background.
> >
> >
> > I've checked the ssh process and it does not catch SIGTTIN and that's why
> > I'm confused.
>
> OK. This has gone beyond the realm of a bash bug. I'm pretty sure that
> previous versions of ssh ignored or caught SIGTTIN, but it must not do that
> now.
>
> Since ssh has a handle on its controlling terminal, it must do something
> that allows it to read from it even if it's not in the foreground process
> group. In any event, -n is the way to deal with that.
>

Thanks Chet.

I reposted the question to stackoverflow this morning and just managed to
figure out the problem (see https://stackoverflow.com/questions/44492312/ ).

-clark

From MAILER-DAEMON Mon Jun 12 13:19:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKT0C-0002h8-47
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 13:19:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46580)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKT09-0002gk-Du
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:19:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKT04-0001Q8-Hb
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:19:41 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:22227
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKT04-0001Pu-Bh
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:19:36 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH34876; Mon, 12 Jun 2017 13:19:34 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFU77556 (AUTH cpr);
	Mon, 12 Jun 2017 13:19:16 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, "bash.bug list" <bug-bash@gnu.org>
Subject: Re: A background ssh can take over the tty from bash?
To: Clark Wang <dearvoid@gmail.com>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
	<68fa4e59-e3cc-173b-17c3-1af39d6a44f3@case.edu>
	<CADv8-ogtB73xqPqFONM9JtTh2pTpw_s_EFqRYFHvcrtfaN1=AA@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <177531a2-c5b9-8b10-ec6a-c8ff8392851c@case.edu>
Date: Mon, 12 Jun 2017 13:19:16 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CADv8-ogtB73xqPqFONM9JtTh2pTpw_s_EFqRYFHvcrtfaN1=AA@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.161217:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __HTTPS_URI,
	__URI_WITH_PATH, __URI_NO_WWW, __CP_URI_IN_BODY,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_600_699, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 17:19:42 -0000

On 6/12/17 12:16 PM, Clark Wang wrote:

>     Since ssh has a handle on its controlling terminal, it must do something
>     that allows it to read from it even if it's not in the foreground process
>     group. In any event, -n is the way to deal with that.
> 
> 
> Thanks Chet.
> 
> I reposted the question to stackoverflow this morning and just managed to
> figure out the problem (see https://stackoverflow.com/questions/44492312/ ).

That's really nice work figuring it out.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 13:38:26 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKTII-0007YK-4x
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 13:38:26 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51859)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKTIF-0007XE-JL
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:38:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKTIE-0008IP-Hn
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:38:23 -0400
Received: from mail-wr0-x231.google.com ([2a00:1450:400c:c0c::231]:36622)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dKTIE-0008GL-Aw
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:38:22 -0400
Received: by mail-wr0-x231.google.com with SMTP id v111so106138318wrc.3
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 10:38:20 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=07vyO+L2XhMSE82HLf3tiw24ijfOpqdrvk/koSUWBqQ=;
	b=rhmqDGQr3f/QWL1zVH7qEExmF2vLqbneetbRinISR6Q1wfO69QqNky7xfQn2HmqirF
	myURwWr4dHGPwYVdE0pVeLTDmb7j9cRxtm/6ijoTJIj6LyMSb7FPL4yxiGdhxD8dUeq7
	nojyUFPEe5f5n7CpeZWmUjbPhenUQvWH8791atUMc8GaRS2RRcM4qS4YRIo4k11Ra8SP
	ERZYJwJHbFQxJS2H3yLy7j+cpYa581of1jWm38AsN8TAyJJlAjO2ZMQt9QXEqof6nmzz
	dWoiReP1Jp/L+wd/ApQYUEXcgfD78WpnhEx2bSx6snKgg/2V7W0aLHxH7Q+SzCb1MjrX
	L/yA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=07vyO+L2XhMSE82HLf3tiw24ijfOpqdrvk/koSUWBqQ=;
	b=pHw1WDNEY6H371/pfZg8Bh3iEyrVSs8v3A21RIkidKzCMjMS6V/GhDD62/2D/nwgbG
	Hb0bcJcn6tlUG3hkb7OwAe0jAaK3t5Wraln/LTBVxWUJZwAX1qMtShoUq8CNbj4r4j8f
	3L0bYZv/XAL4UEuOxkD39/ZL4jalAuc9KI3RRtmUP/sIb5jgxMWhSNpY2pQ2nIb87zVM
	LfIg0DV2VtcVt75Fxz/soT4gIkLoKMXebVQNlyrdCnt+cFnRXyh6WOif7qLQbI3zsKAi
	jxktBnpSGN2mLSU/6n8T/50CTHQCNImwHgYnJURYTf8ZULHY2T6yK8wNbaxtATTPa+Sl
	IKmw==
X-Gm-Message-State: AKS2vOxjwQ1x5FZVG8awSlYQdrwu+7P+rxW8DD+3b32ocBcdvh5uhb20
	GbXk8vH17ujf16Z4pc6z1Cyu3kV2Og==
X-Received: by 10.28.140.133 with SMTP id o127mr64162wmd.7.1497289099579; Mon,
	12 Jun 2017 10:38:19 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Mon, 12 Jun 2017 10:38:18 -0700 (PDT)
In-Reply-To: <20170612043549.k25sr26l24ge6so5@debian>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
From: Paul Peet <peetpaul69@gmail.com>
Date: Mon, 12 Jun 2017 19:38:18 +0200
Message-ID: <CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: Eduardo Bustamante <dualbus@gmail.com>
Cc: George <tetsujin@scope-eye.net>, bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::231
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 17:38:24 -0000

Uhmm, I am not sure how to interpret these results (All shells or
terminals have been tested with Ubuntu 17.04):

gnome-terminal + bash: Happens
gnome-terminal + zsh: This bug also happens here, lines are getting
removed/repeated...
gnome-terminal + dash: Does not happen. (I changed the
PS1="username@hostname $" to make it longer)
gnome-terminal + mksh: The bug also occured here. Same as bash and zsh.

konsole + bash: Doesn't happen here. I guess this is because konsole
doesn't do text wrapping (The prompt wraps though but not the output
alone.)


On Mon, Jun 12, 2017 at 6:35 AM, Eduardo Bustamante <dualbus@gmail.com> wrote:
> On Sun, Jun 11, 2017 at 12:29:33AM +0200, Paul Peet wrote:
> [...]
>> Unfortunately, I am still getting the same behavior as before (This
>> also happens with xterm for some reason.)
>
> Please do consider that Readline has little knowledge about what has
> been written to the terminal. That's the terminal's reponsability.
>
> What Readline does is to write your prompt, and place the cursor right
> beside the prompt. In both of your animations, the prompt seems to be
> rendered fine, I can't really tell because the animation is a bit fast.
>
> Does the same problem happen if you use a different shell? (zsh, mksh,
> dash, ksh93).
>
> --
> Eduardo Bustamante
> https://dualbus.me/


From MAILER-DAEMON Mon Jun 12 13:55:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKTZ5-0002ri-7D
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 13:55:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55573)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKTZ2-0002rM-Ct
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:55:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKTYx-0005As-I3
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:55:44 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:22037
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKTYx-0005Ak-Bn
	for bug-bash@gnu.org; Mon, 12 Jun 2017 13:55:39 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANM60780; Mon, 12 Jun 2017 13:55:37 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFK85174 (AUTH cpr);
	Mon, 12 Jun 2017 13:55:37 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>, Eduardo Bustamante <dualbus@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
Date: Mon, 12 Jun 2017 13:55:37 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.165116:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1200_1299, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 17:55:45 -0000

On 6/12/17 1:38 PM, Paul Peet wrote:
> Uhmm, I am not sure how to interpret these results (All shells or
> terminals have been tested with Ubuntu 17.04):
> 
> gnome-terminal + bash: Happens
> gnome-terminal + zsh: This bug also happens here, lines are getting
> removed/repeated...
> gnome-terminal + dash: Does not happen. (I changed the
> PS1="username@hostname $" to make it longer)
> gnome-terminal + mksh: The bug also occured here. Same as bash and zsh.

I suspect this happens due to mismatched expectations. The cases with
garbled output seem to occur where the redisplay engine assumes the
terminal maintains the text across resizes (so it can do intelligent
redisplay using what's already on the screen) and the terminal emulator
assumes the foreground process is going to take care of doing all the
redisplay after a SIGWINCH and doesn't bother with the screen contents.

The readline redisplay engine assumes that the only characters on the
screen are those it writes.  If that assumption is violated on a size
change, you'll get indeterminate results.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 14:24:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKU0v-0002k5-0g
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 14:24:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34781)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKU0s-0002jw-KR
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:24:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKU0m-0005Wa-Sy
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:24:26 -0400
Received: from mail-wr0-x22d.google.com ([2a00:1450:400c:c0c::22d]:34639)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dKU0m-0005WG-M4
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:24:24 -0400
Received: by mail-wr0-x22d.google.com with SMTP id g76so105529582wrd.1
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 11:24:24 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=SMUvke+BMb8o2P17siWNIQofX7t9y80Kal0kHLWbZ6U=;
	b=CFjm8NeNLbkwxGnWg1wh3g/ybWKgCz/6TECp+yphsLBoQLL7t8TpD4TKorIKOHSWTc
	tuuAkh4nuJS9wtSs9fTo5PdCPXt0iC/QR2IcVfn3KCQkPA4RBb71MWwZBx1Q+nGX2LiZ
	h0yahYxxwc6oXjEFfKarybg+RtOOfO1YAklxkRoMy5KdDaT9ssHWQDGjq8iMX4rg9JLi
	iAdtzHZzuediIWzwkbbcmGcE1myM06jxRRh+wN1wCLEPtbqSf1HfD0Lele86g3YKHXNz
	SOqPMYWlM4LeP6ejPHA0kCpe0CEPdV+qYvR1vjYoTIHbnlg//xzJSBeBYYgLT0qGaA5P
	vxqw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=SMUvke+BMb8o2P17siWNIQofX7t9y80Kal0kHLWbZ6U=;
	b=qXedAKQd6cski1hrfGQr/eQtKu5B93QBe54pVFY/ITPTXEkjtSScM6vORiB+Pay2rs
	3JkVvobZOxBZc1+EpLIfQXyi7OqZ+SHGzrsxJBykmlX+68HaGqvRCK/8dA0lHHU3Yrf8
	hJ4YvWKMV52HyzDUB7Ku/IF+QWcK9j9frcSUKnVrXNkTDCH5USxIWMK9P/R7GKH/Eyqo
	QS1OXJJFJgg8tFYDgqJZNn9Rb1Nw1+Wb0A/LP77L2TpCacKytyY6xtO2p8bc+sbx0OS8
	ROwpokcMA3sS8x+TBqlGGg6Smt8I+ere8CpdlHA3JHj11fE+2Ng6YJ2/CZGpQFFYZv3R
	IbiA==
X-Gm-Message-State: AKS2vOwIBQHqAmSbAHpKYS3vPdr9eBozAkrAHqUiRI+Zt6dkO21evoPi
	11KWaJskvXpRkdYCFeegUkZ75zakdA==
X-Received: by 10.28.191.155 with SMTP id o27mr5564676wmi.7.1497291861530;
	Mon, 12 Jun 2017 11:24:21 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Mon, 12 Jun 2017 11:24:20 -0700 (PDT)
In-Reply-To: <a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
From: Paul Peet <peetpaul69@gmail.com>
Date: Mon, 12 Jun 2017 20:24:20 +0200
Message-ID: <CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: chet.ramey@case.edu
Cc: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org,
	George <tetsujin@scope-eye.net>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 18:24:31 -0000

I guess this is why I don't get the garbage output with gnome-terminal
and dash. Dash doesn't use readline apparently.

So, what can be done to actually fix this?

On Mon, Jun 12, 2017 at 7:55 PM, Chet Ramey <chet.ramey@case.edu> wrote:
> On 6/12/17 1:38 PM, Paul Peet wrote:
>> Uhmm, I am not sure how to interpret these results (All shells or
>> terminals have been tested with Ubuntu 17.04):
>>
>> gnome-terminal + bash: Happens
>> gnome-terminal + zsh: This bug also happens here, lines are getting
>> removed/repeated...
>> gnome-terminal + dash: Does not happen. (I changed the
>> PS1="username@hostname $" to make it longer)
>> gnome-terminal + mksh: The bug also occured here. Same as bash and zsh.
>
> I suspect this happens due to mismatched expectations. The cases with
> garbled output seem to occur where the redisplay engine assumes the
> terminal maintains the text across resizes (so it can do intelligent
> redisplay using what's already on the screen) and the terminal emulator
> assumes the foreground process is going to take care of doing all the
> redisplay after a SIGWINCH and doesn't bother with the screen contents.
>
> The readline redisplay engine assumes that the only characters on the
> screen are those it writes.  If that assumption is violated on a size
> change, you'll get indeterminate results.
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 14:48:49 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKUOP-0001tM-55
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 14:48:49 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39749)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKUON-0001t3-CP
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:48:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKUOI-0006PU-FP
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:48:47 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:55184
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKUOI-0006O3-4p
	for bug-bash@gnu.org; Mon, 12 Jun 2017 14:48:42 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5CImYU4055295; Mon, 12 Jun 2017 11:48:36 -0700
Message-ID: <593EE202.7070706@tlinx.org>
Date: Mon, 12 Jun 2017 11:48:34 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Clark Wang <dearvoid@gmail.com>
CC: Chet Ramey <chet.ramey@case.edu>, "bash.bug list" <bug-bash@gnu.org>
Subject: Re: A background ssh can take over the tty from bash?
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
In-Reply-To: <CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 18:48:48 -0000

Clark Wang wrote:
>
> I've checked the ssh process and it does not catch SIGTTIN and that's why
> I'm confused.
>   
----
    From what I understand, a background process will automatically
block when it tries to read from STDIN.  By definition, processes
become bg-processes by using '&'.  I haven't looked at the
code, but I'm guessing that the first 'ssh' that you launched
(*without* the '&') is the process swallowing your input as
it was declared to be a some sort of master-multiplexer for
subsequent slave processes, but that's just a guess.  Maybe
putting the master in background @ launch (using '&') will
cause it to auto-block(suspend) as you expect?



From MAILER-DAEMON Mon Jun 12 15:27:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKUzj-0003ng-Te
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 15:27:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50661)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKUzg-0003ki-U9
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:27:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKUzd-0002su-RF
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:27:20 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:6800
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKUzd-0002sJ-Lw
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:27:17 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH58318; Mon, 12 Jun 2017 15:27:15 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFU98301 (AUTH cpr);
	Mon, 12 Jun 2017 15:27:15 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Eduardo Bustamante <dualbus@gmail.com>,
	bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
Date: Mon, 12 Jun 2017 15:27:15 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.185416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 19:27:22 -0000

On 6/12/17 2:24 PM, Paul Peet wrote:
> I guess this is why I don't get the garbage output with gnome-terminal
> and dash. Dash doesn't use readline apparently.

Dash doesn't support line editing at all out of the box, though you can
build it using libedit.

> 
> So, what can be done to actually fix this?

Not a lot, really. If the display engine assumes that the only characters
on the screen are the ones it writes there, and the terminal emulator
violates that on a screen size change, you're basically left with running
^L (with or without a numeric argument to restrict it to the current line)
a lot.

Now, if you force a complete refresh with ^L and the display is still
wrong, we have a redisplay bug.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 15:45:39 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKVHP-0000w7-HC
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 15:45:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55985)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKVHO-0000vz-2U
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:45:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKVHN-0001JP-06
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:45:38 -0400
Received: from mail-wr0-x22f.google.com ([2a00:1450:400c:c0c::22f]:34391)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dKVHM-0001J9-Ps
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:45:36 -0400
Received: by mail-wr0-x22f.google.com with SMTP id g76so108182327wrd.1
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 12:45:36 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=ljOQ6GDUNMx1q74xExN/NlGQDTU1fO1xDH1CwnOGoW4=;
	b=QzfeaMxAmLhnItLzE1kSHbhK8JrA/SB5s+7i6u0KkyfwmiwDKeEPuwJXUHrGdOzqyX
	4GNgkmr2FFOM/LOCpvH7ML5yb0FG0flNYWZ3tujayMUOuX1Pu/2tr9wfYhtImNmigfAk
	SWaJd6h3dR68sBFoNKOTPFy23CWWMIzQ7p15NtrN/Qgsy+OsSvJBGWDd6I68JnTaV+KX
	mIqkKa7xjjY8NiIQkTEDl3ehzP5kolE7ME0PI8OwLCC5jqN/gayCC2LJ7nU4LGLMh3DH
	4JEyxp1ieZWLR/AhaPmv+GtL4sigO+TX+Cj+4xSY2JbWqglqftRaAf8aPmuFRs+4J481
	MWBg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=ljOQ6GDUNMx1q74xExN/NlGQDTU1fO1xDH1CwnOGoW4=;
	b=bPrmg9WfWTwUpE8BYg2aYMMDL1K6FqNJcIQLsn9rp7hV7cxqky4Q2X6ndZiOK1H8aj
	vjGfIOxwNOep2tr2eHpRkX64DyMWB48O7SW8zYt4dqQuemWI2B5yyiGI/FXOs4xP+3BX
	FTlYTZOGVamR6O/FD9aMALLgtLLBD7SqpsL7UQ/Z8NbvVVlIc2Fj08LAA/MeEGc7p0OG
	Iz917bx14XWqFG2RW5sI18CXTBGc40RZObAMo7vHEq+KcPZCcQljoICJ/zY1IZZ4uCPx
	UMhIR7pHg9IScVmmwdtsuvnb89DOovRnx6ZfflaMF1uBu/b734HepnGY7v9eMYpBBE8k
	0UqQ==
X-Gm-Message-State: AKS2vOzNzD6oOeNPclnUqdFvn/lT81kzWV+iW2OLWt6tvzuSaK7sO+jW
	TWP4Nd7aO22O5Ksd7tNrumoCfEiwlg==
X-Received: by 10.28.147.202 with SMTP id v193mr346616wmd.37.1497296734870;
	Mon, 12 Jun 2017 12:45:34 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Mon, 12 Jun 2017 12:45:34 -0700 (PDT)
In-Reply-To: <6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
From: Paul Peet <peetpaul69@gmail.com>
Date: Mon, 12 Jun 2017 21:45:34 +0200
Message-ID: <CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: chet.ramey@case.edu
Cc: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org,
	George <tetsujin@scope-eye.net>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 19:45:39 -0000

Well, I can try to re-open this issue on the gnome-terminal/vte3 side.
Perhaps I can convince them to take an approach where the terminal
isn't violating the assumptions of the display engine by introducing a
new flag or something like that.

On Mon, Jun 12, 2017 at 9:27 PM, Chet Ramey <chet.ramey@case.edu> wrote:
> On 6/12/17 2:24 PM, Paul Peet wrote:
>> I guess this is why I don't get the garbage output with gnome-terminal
>> and dash. Dash doesn't use readline apparently.
>
> Dash doesn't support line editing at all out of the box, though you can
> build it using libedit.
>
>>
>> So, what can be done to actually fix this?
>
> Not a lot, really. If the display engine assumes that the only characters
> on the screen are the ones it writes there, and the terminal emulator
> violates that on a screen size change, you're basically left with running
> ^L (with or without a numeric argument to restrict it to the current line)
> a lot.
>
> Now, if you force a complete refresh with ^L and the display is still
> wrong, we have a redisplay bug.
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 15:47:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKVJX-0001qL-Tn
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 15:47:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56504)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVJW-0001qE-1N
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:47:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVJR-0001pB-4Z
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:47:50 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:45118
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKVJQ-0001p7-Ud
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:47:45 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH41404; Mon, 12 Jun 2017 15:47:43 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFL02724 (AUTH cpr);
	Mon, 12 Jun 2017 15:47:43 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Eduardo Bustamante <dualbus@gmail.com>,
	bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
Date: Mon, 12 Jun 2017 15:47:42 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.191516:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 19:47:51 -0000

On 6/12/17 3:45 PM, Paul Peet wrote:
> Well, I can try to re-open this issue on the gnome-terminal/vte3 side.
> Perhaps I can convince them to take an approach where the terminal
> isn't violating the assumptions of the display engine by introducing a
> new flag or something like that.

Maybe. I know Mac OS X Terminal manages to do it.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 15:54:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKVPp-0004Bp-PZ
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 15:54:21 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57684)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVPn-0004Ab-Hg
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:54:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVPk-0003s9-Er
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:54:19 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:6671
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKVPk-0003rl-6K
	for bug-bash@gnu.org; Mon, 12 Jun 2017 15:54:16 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMC63966; Mon, 12 Jun 2017 15:54:10 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFV02532 (AUTH cpr);
	Mon, 12 Jun 2017 15:54:10 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
To: Peter & Kelly Passchier <peterkelly@passchier.net>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <d3c28d1d-4245-4597-bbdf-f50a53184dca@case.edu>
Date: Mon, 12 Jun 2017 15:54:09 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.193315:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_700_799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 19:54:20 -0000

On 6/9/17 1:40 PM, Peter & Kelly Passchier wrote:
> On 09/06/2560 23:38, L A Walsh wrote:
>> Chet Ramey wrote:
>>>
>>>  Should mapfile silently drop the NULs?
>>
>> Maybe add a flag to ignore NUL bytes that could be used in the 'read'
>> statement as well?  If not specified, keep same behavior?
> 
> That sounds like it might be useful.
> It might be more desirable to change it to a newline instead of dropping
> it? (Or both, with different flags??)

If you want to effectively change it to a newline, specify NUL as the
line delimiter using the -d option (new in bash-4.4).

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 16:09:00 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKVe0-0000m2-Rf
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 16:09:00 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60487)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKVdz-0000lm-5U
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:09:00 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKVdy-0007gp-AB
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:08:59 -0400
Received: from mail-wr0-x22d.google.com ([2a00:1450:400c:c0c::22d]:35765)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dKVdy-0007gT-2d
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:08:58 -0400
Received: by mail-wr0-x22d.google.com with SMTP id q97so112286755wrb.2
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 13:08:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=gKzWbnNwWFZt+AmQ6PBsmTJ3mzYW408BlqGhrl8JasI=;
	b=JSg8MhseJmdObSXJALyn6Fq+znLuMzbP2g4z1eyAAbeBxlIgI0ibEbVd45peAh0Det
	ad3eaGUeFw7aY0AzNEg3IKmQOY6sRaNEoa0DHAX0CTKnk1X/fWYskVGXnLFzxksVB2+O
	cLJqJdkpuVC7NG9CSzQVPgxc3tzOqy4ic4KQfLU2dGNJ+cPwzPb/iQR9wxM9Io3xSKR+
	SILY6X4fIeLwIyE+BIkFtMYM1yKrPPULfceAuH9yiL5zlGKYdqOFAaF7d1I1/OfrF24D
	22hqD4LzpPgZgrhVbiLSLlr444UeVoBDEhEl547UYqVuZoPAAP0doSAxtM3+e4KWZ0UL
	2dCA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=gKzWbnNwWFZt+AmQ6PBsmTJ3mzYW408BlqGhrl8JasI=;
	b=msqXz7Ur6jlMGsfGF5R7a6W4vAnflFAkveD950vlevCdIY82vzMXl4/NieoUJGcCDb
	2C85vT9ut4VNybSgnNUpHjUKIjr5il7+je0mjEesycYwxhLYhr7hLLC0YhM9wj5dgFVT
	cWLr5sgs/2HARePEiURy0Bmf39/0ed1EivV+UptpA6yCJ0dSMCc/jnuTzQziYHaqvBVY
	sgWFXs+sZhqgirk3iSOmyGr/hjcA5JXhgOQMmzNZ7/ZMvM4UAXA90X45YUlknVcNu5t8
	OsP0yqEuc8TrV1taoupDL4tL1FyhLhLE//tDeckWIiiqdj9mBFaHQo5tOUtUEZqdWo38
	PFhA==
X-Gm-Message-State: AKS2vOyG5NHp5L5XvEofQow4Hf9VhMAao+oLjctPWGwAtLjAbS3kbeSL
	DlOgFbj414EzFQfD7bPrZCzMJFdUQQ==
X-Received: by 10.223.131.66 with SMTP id 60mr410666wrd.169.1497298137169;
	Mon, 12 Jun 2017 13:08:57 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Mon, 12 Jun 2017 13:08:56 -0700 (PDT)
In-Reply-To: <aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
	<aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
From: Paul Peet <peetpaul69@gmail.com>
Date: Mon, 12 Jun 2017 22:08:56 +0200
Message-ID: <CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: Chester Ramey <chet.ramey@case.edu>
Cc: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org,
	George <tetsujin@scope-eye.net>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 20:09:00 -0000

Is there a flag in macOS's Terminal? It's because I am also
experiencing this bug on macOS's Terminal :) (with bash).

On Mon, Jun 12, 2017 at 9:47 PM, Chet Ramey <chet.ramey@case.edu> wrote:
> On 6/12/17 3:45 PM, Paul Peet wrote:
>> Well, I can try to re-open this issue on the gnome-terminal/vte3 side.
>> Perhaps I can convince them to take an approach where the terminal
>> isn't violating the assumptions of the display engine by introducing a
>> new flag or something like that.
>
> Maybe. I know Mac OS X Terminal manages to do it.
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 16:25:06 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKVtZ-0004Dd-Ts
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 16:25:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35791)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVtX-0004DJ-Ha
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:25:04 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKVtS-0005bC-Kr
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:25:03 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:50105
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKVtS-0005ay-Eq
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:24:58 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH42896; Mon, 12 Jun 2017 16:24:56 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFV08003 (AUTH cpr);
	Mon, 12 Jun 2017 16:24:56 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Eduardo Bustamante <dualbus@gmail.com>,
	bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
	<aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
	<CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <5d26ea59-2047-fd94-0f06-fb64755c22a3@case.edu>
Date: Mon, 12 Jun 2017 16:24:55 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.191516:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __NO_HTML_TAG_RAW, BODY_SIZE_1300_1399,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 20:25:04 -0000

On 6/12/17 4:08 PM, Paul Peet wrote:
> Is there a flag in macOS's Terminal? It's because I am also
> experiencing this bug on macOS's Terminal :) (with bash).

I doubt it. My testing wasn't very scientific. I just opened up a new
Terminal, ran bash-4.4, typed a bunch of characters, and constantly resized
the terminal while watching the display.  xterm didn't do too badly at
this, either.

The thing that Terminal does that other terminal emulators (e.g., xterm)
don't seem to do is rewrap all the text on the screen as the screen gets
resized.  For instance, if I make an xterm very narrow, so that the text on
previous lines gets `squeezed' and not displayed, that text isn't restored
when I widen it again. xterm also leaves text on the screen below the
current line if the screen is narrowed so the current line wraps and
consumes all of the vertical area, then widened again. This argues for the
conjecture that other terminal emulators expect the foreground process to
manage the entire display, not just the current line.

There's probably some work that can be done with streams of SIGWINCH,
though.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 16:45:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKWDV-0000oL-Nj
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 16:45:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39853)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKWDT-0000nt-6M
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:45:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKWDQ-0003Wy-3Q
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:45:39 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:16530
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKWDP-0003Wh-Tn
	for bug-bash@gnu.org; Mon, 12 Jun 2017 16:45:36 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH61210; Mon, 12 Jun 2017 16:45:33 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFV10633 (AUTH cpr);
	Mon, 12 Jun 2017 16:45:29 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Eduardo Bustamante <dualbus@gmail.com>,
	bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
	<aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
	<CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
	<5d26ea59-2047-fd94-0f06-fb64755c22a3@case.edu>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <70fb6400-d848-d3e7-99cd-d83b41ef073a@case.edu>
Date: Mon, 12 Jun 2017 16:45:29 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5d26ea59-2047-fd94-0f06-fb64755c22a3@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.12.195416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_2000_2999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 12 Jun 2017 20:45:40 -0000

On 6/12/17 4:24 PM, Chet Ramey wrote:
> On 6/12/17 4:08 PM, Paul Peet wrote:
>> Is there a flag in macOS's Terminal? It's because I am also
>> experiencing this bug on macOS's Terminal :) (with bash).
> 
> I doubt it. My testing wasn't very scientific. I just opened up a new
> Terminal, ran bash-4.4, typed a bunch of characters, and constantly resized
> the terminal while watching the display.  xterm didn't do too badly at
> this, either.
> 
> The thing that Terminal does that other terminal emulators (e.g., xterm)
> don't seem to do is rewrap all the text on the screen as the screen gets
> resized.  For instance, if I make an xterm very narrow, so that the text on
> previous lines gets `squeezed' and not displayed, that text isn't restored
> when I widen it again. xterm also leaves text on the screen below the
> current line if the screen is narrowed so the current line wraps and
> consumes all of the vertical area, then widened again. This argues for the
> conjecture that other terminal emulators expect the foreground process to
> manage the entire display, not just the current line.

Now, one thing I didn't mention is that this auto-wrapping of all text can
cause its own problems. Consider the case where the cursor is at the right
side of the screen, and you narrow the screen one or two columns -- just
enough to cause the text to require, say, three lines instead of two.  In
this instance, Terminal wraps the text on its own -- meaning the cursor is
now on the third `physical' line -- before sending bash a SIGWINCH. At this
point, readline tries to perform redisplay assuming the cursor is still on
the second line and that the terminal emulator hasn't done anything, so its
position calculations are off from the start.  This can easily leave stray
lines of text on the screen that readline doesn't (and can't) know about.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 12 20:55:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKa7I-0008G8-89
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 20:55:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40980)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dKa7F-0008Fa-Pt
	for bug-bash@gnu.org; Mon, 12 Jun 2017 20:55:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dKa7A-00016Y-Vs
	for bug-bash@gnu.org; Mon, 12 Jun 2017 20:55:29 -0400
Received: from mail-pg0-x22f.google.com ([2607:f8b0:400e:c05::22f]:35388)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dKa7A-00016A-P6
	for bug-bash@gnu.org; Mon, 12 Jun 2017 20:55:24 -0400
Received: by mail-pg0-x22f.google.com with SMTP id k71so52254624pgd.2
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 17:55:22 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:to:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=lLlFMCsVVU+Xc1C6n4cIG9PSzweMhC/NMlJzSnvlBI4=;
	b=NGj6V6mCJis3UM8lKqX34QeLOSW6561X5pUo0HYi64xBFejP+xZQ2svwC/kwDzTt7b
	NQQR4YYMQzBIINm/kgZHSnX9+q6ipKaBAt6MxpYR0s6fsgRCFGzSMsqWq0u99CaihecU
	KVcxmjmxyRkvkBpJBt97Vcee+KZKW/c27MOzL1fZAocb7Vd/C1GRLpXD5CjFHPLbwLfj
	R8V/kSBrP6JXarTT6W3wSRmqbOVA9zERhAA3SG/ds+qJUzR8J+78FDbsPd78YAjoUxpN
	gmdS4KjtWpTF57Qu+QAQAj9QVmbibBsiCmBYxq1HeKUosefxxc/dMdgTZAtuUoXfTHVq
	dQaA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:to:cc:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=lLlFMCsVVU+Xc1C6n4cIG9PSzweMhC/NMlJzSnvlBI4=;
	b=EYnJeFu8UXIPAFeTXWcxqfPYJ9b7ju5a31yEfkOc02HO7/VlYKSB8DJPkbGPMbZPXN
	C9tC1/6KDmRhyYY3E6K1fyMsLknKuq+nqfgF+/s2cQQ/Cndsu1ChvXSrygoctAJuRhi1
	qCv7TjcJmvuLw3ET+qTkD4y0yb/dD9qpKQCBvyscFZ2rsDWHwswAaSyupJtUl9zuoztv
	ooD+oxcqNd7Jf+ueVMWlzKahDmB/Bbv5mAyTduvk0LJTh+9yrseiI18myX9d2JqI/rIo
	i37PzPbX7m/3buijRd2uX8UfcANsheiiocEf0pPLIoKEBDpZDNw/yPq9lR5bn4L+WsCf
	d7hw==
X-Gm-Message-State: AODbwcC3HxvLA0/ymVWha/a6pjqrhU/ESDlPaQBH2+YhtW+ACLZVApJw
	fmYpJCUFwwLiDJG3
X-Received: by 10.84.218.136 with SMTP id r8mr59534161pli.265.1497315321902;
	Mon, 12 Jun 2017 17:55:21 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.48.146])
	by smtp.gmail.com with ESMTPSA id
	t20sm21803716pgo.29.2017.06.12.17.55.17
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Mon, 12 Jun 2017 17:55:19 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: Trailing newlines disappear
To: chet.ramey@case.edu
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<d3c28d1d-4245-4597-bbdf-f50a53184dca@case.edu>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <d9b0b7e9-1aaa-b80b-e167-9587c68a82d7@passchier.net>
Date: Tue, 13 Jun 2017 07:55:15 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <d3c28d1d-4245-4597-bbdf-f50a53184dca@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 00:55:30 -0000

On 13/06/2560 02:54, Chet Ramey wrote:
> If you want to effectively change it to a newline, specify NUL as the
> line delimiter using the -d option (new in bash-4.4).

Thanks, that sounds like a clean solution!
I only reverted to mapfile because $(...) command substitution could not
be made to work. (I still have to 'convert' the array to a normal
variable in the next step...). Would a shell option for command
substitution using NUL be a desirable feature to bash users??

Peter


From MAILER-DAEMON Mon Jun 12 21:49:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKaxl-0001dR-7V
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 21:49:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49137)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKaxj-0001dJ-8v
	for bug-bash@gnu.org; Mon, 12 Jun 2017 21:49:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peetpaul69@gmail.com>) id 1dKaxh-00054x-MH
	for bug-bash@gnu.org; Mon, 12 Jun 2017 21:49:43 -0400
Received: from mail-wr0-x22a.google.com ([2a00:1450:400c:c0c::22a]:35610)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peetpaul69@gmail.com>)
	id 1dKaxh-00054p-Cf
	for bug-bash@gnu.org; Mon, 12 Jun 2017 21:49:41 -0400
Received: by mail-wr0-x22a.google.com with SMTP id q97so120652036wrb.2
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 18:49:41 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc:content-transfer-encoding;
	bh=2OJ/dWYK7qD8AD8uSyX9vbNO7cD4N2D/zSXWuru/K00=;
	b=bUgmrQpDOtacfRA+9FdxdpKMzj4D5JQTtLHMyaOk6ZoAyzaIkNmtqsO6KtZO5NpeWW
	1Yg1j4ygYuP6q9w9+3KiwhdaNNIkydIwKcCwc92rGoWEfBOAZxphtfriUt/yBiyOxkRZ
	X8mJ/XP+nPxrL3HS8a1UaDPVP+ZiT9qgG52swbtHjHaI2M6FGk01i+BG8K7mFsEIedpd
	p9xU6oh2KI9qDuNwXFzkeqp0MfigUtv914LdjOgWy9/rVGYQHRkLlzRnLf8IkWDIK4BD
	DTfQEZJATzYCrJuAXrumWHBMinH4oSLU74YMSEoYhCfigYfF9cNeMuBUby4p5WWbnIvb
	2+Ng==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc:content-transfer-encoding;
	bh=2OJ/dWYK7qD8AD8uSyX9vbNO7cD4N2D/zSXWuru/K00=;
	b=gDSPwWPiSPFbjXucDWk2Le1HtBwHNz8lI4fYAwCzx/cCQqBm3haN6tvUocUaFhPhb1
	JqOqozafHFNc0Hhf/fKPcoNZla6wdf40IPvF7ktOhrT88aExsIePLA6kxFfaDIMZfFyf
	mwZd1LFZqHkF1QyXkQLcPt8r6r/x0OAdQqbMTjlp8bojXR6Huqa8YfihOPI64R6Ibmr3
	wYrogRvtd0cmR7p3Zv8xPxNjFaIAh2+LO2rs/T6flEGF8273qiNmwIqacb7a/AmgbALa
	nVVNMWEMeOR6QQ1c5W1kG1pk8NpcYEUa1FgtHEp0SRiiX7MiYjx5uREnuQbrVZWoOJSL
	CifA==
X-Gm-Message-State: AKS2vOxl0qzXd6zNO9+oN+fbV5ZSSwwnK8yMyow4deXlUe5O1cLoTwGl
	deKrCsvDPid6ahkvBYsSU0Y11toKBA==
X-Received: by 10.28.140.133 with SMTP id o127mr870194wmd.7.1497318580158;
	Mon, 12 Jun 2017 18:49:40 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.223.155.158 with HTTP; Mon, 12 Jun 2017 18:49:39 -0700 (PDT)
In-Reply-To: <70fb6400-d848-d3e7-99cd-d83b41ef073a@case.edu>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<20170610162016.lcc2r2eggqd2qd4w@debian>
	<1497113241.17253.415.camel@scope-eye.net>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
	<aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
	<CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
	<5d26ea59-2047-fd94-0f06-fb64755c22a3@case.edu>
	<70fb6400-d848-d3e7-99cd-d83b41ef073a@case.edu>
From: Paul Peet <peetpaul69@gmail.com>
Date: Tue, 13 Jun 2017 03:49:39 +0200
Message-ID: <CALfJGG_7b8BMJ-ZT-NrWbcRYDEW-7naRg-GDB1C3BWeiKYHGFQ@mail.gmail.com>
Subject: Re: Buffer corruption when the terminal is resized.
To: Chester Ramey <chet.ramey@case.edu>
Cc: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org,
	George <tetsujin@scope-eye.net>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22a
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 01:49:44 -0000

Well, I seriously have no idea what approach would be the right one to
fix this but I've responded on the other side and this was Egmont
Koblinger (vte developer) response:

----
Yes, indeed, rewrapping the contents on resize breaks this assumption.

Given that in a(n obviously non-representative) poll about 1.5 years
ago at https://opensource.com/life/15/11/top-open-source-terminal-emulators=
,
terminal emulators that now (not at the time of the poll) rewrap on
resize got around 50-60% of the votes, maybe it's time for
readline/bash to reconsider their assumptions.

You can easily disable rewrapping in the profile preferences. You
will, however, lose one of the coolest features that received by far
the most positive feedback in recent years of vte/gnome-terminal. The
one that made me join the project. The one that resulted in the
biggest productivity boost for me and probably for many other folks.
The one that I'm still the proudest of till this day :-) Your call.

Could VTE rewrap the entire scrollback, just not the last prompt?
Well, that would certainly require tons of future development and
cooperation with bash and other shells, because then we would need to
know where the prompt is, which we currently don't know and don't care
about. It might become handy or even necessary for command completion
notification anyway (a stalled feature request), depending on what
approach we take there, but there we saw an utter lack of interest
from bash devs in cooperating and addressing that request. As such, I
have doubts that they'd be open for a cooperation here. Also I
personally wouldn't care about such cooperation if it aimed to address
this prompt-resize issue only and not the notification one. I'd
personally be happy to cooperate with them (time permitting) if we aim
to address both this issue and the notification story.

Until then, you have a couple of choices. You can disable rewrap on
resize. You can disable and then restore wraparound in your prompt, as
shown above. Or you can live with this issue.

I really don't think it's a serious issue. You need to stress-resize
the window for this to occur, which you probably won't do normally.
And even if you hit the bug, the consequences are not severe at all.
Just a bit of display corruption; you can press ^L to clear/repair the
screen, or ^C to cancel the command and start over, or anything alike.
It's sure a bit annoying, but IMO nothing big deal.

In the mean time I'm wondering... does the workaround of disabling
wraparound while the prompt is printed (that is,
PS1=3D'\[\e[?7l\].....\[\e[?7h\]') have any drawbacks at all?
----
https://bugzilla.gnome.org/show_bug.cgi?id=3D780995


> Yes, indeed, rewrapping the contents on resize breaks this assumption.
>
> Given that in a(n obviously non-representative) poll about 1.5 years ago =
at https://opensource.com/life/15/11/top-open-source-terminal-emulators, te=
rminal emulators that now (not at the time of the poll) rewrap on resize go=
t around 50-60% of the votes, maybe it's time for readline/bash to reconsid=
er their assumptions.
>
> You can easily disable rewrapping in the profile preferences. You will, h=
owever, lose one of the coolest features that received by far the most posi=
tive feedback in recent years of vte/gnome-terminal. The one that made me j=
oin the project. The one that resulted in the biggest productivity boost fo=
r me and probably for many other folks. The one that I'm still the proudest=
 of till this day :-) Your call.
>
> Could VTE rewrap the entire scrollback, just not the last prompt? Well, t=
hat would certainly require tons of future development and cooperation with=
 bash and other shells, because then we would need to know where the prompt=
 is, which we currently don't know and don't care about. It might become ha=
ndy or even necessary for command completion notification anyway (a stalled=
 feature request), depending on what approach we take there, but there we s=
aw an utter lack of interest from bash devs in cooperating and addressing t=
hat request. As such, I have doubts that they'd be open for a cooperation h=
ere. Also I personally wouldn't care about such cooperation if it aimed to =
address this prompt-resize issue only and not the notification one. I'd per=
sonally be happy to cooperate with them (time permitting) if we aim to addr=
ess both this issue and the notification story.
>
> Until then, you have a couple of choices. You can disable rewrap on resiz=
e. You can disable and then restore wraparound in your prompt, as shown abo=
ve. Or you can live with this issue.
>
> I really don't think it's a serious issue. You need to stress-resize the =
window for this to occur, which you probably won't do normally. And even if=
 you hit the bug, the consequences are not severe at all. Just a bit of dis=
play corruption; you can press ^L to clear/repair the screen, or ^C to canc=
el the command and start over, or anything alike. It's sure a bit annoying,=
 but IMO nothing big deal.
>
> In the mean time I'm wondering... does the workaround of disabling wrapar=
ound while the prompt is printed (that is, PS1=3D'\[\e[?7l\].....\[\e[?7h\]=
') have any drawbacks at all?
> [reply] [=E2=88=92] Comment 15

On Mon, Jun 12, 2017 at 10:45 PM, Chet Ramey <chet.ramey@case.edu> wrote:
> On 6/12/17 4:24 PM, Chet Ramey wrote:
>> On 6/12/17 4:08 PM, Paul Peet wrote:
>>> Is there a flag in macOS's Terminal? It's because I am also
>>> experiencing this bug on macOS's Terminal :) (with bash).
>>
>> I doubt it. My testing wasn't very scientific. I just opened up a new
>> Terminal, ran bash-4.4, typed a bunch of characters, and constantly resi=
zed
>> the terminal while watching the display.  xterm didn't do too badly at
>> this, either.
>>
>> The thing that Terminal does that other terminal emulators (e.g., xterm)
>> don't seem to do is rewrap all the text on the screen as the screen gets
>> resized.  For instance, if I make an xterm very narrow, so that the text=
 on
>> previous lines gets `squeezed' and not displayed, that text isn't restor=
ed
>> when I widen it again. xterm also leaves text on the screen below the
>> current line if the screen is narrowed so the current line wraps and
>> consumes all of the vertical area, then widened again. This argues for t=
he
>> conjecture that other terminal emulators expect the foreground process t=
o
>> manage the entire display, not just the current line.
>
> Now, one thing I didn't mention is that this auto-wrapping of all text ca=
n
> cause its own problems. Consider the case where the cursor is at the righ=
t
> side of the screen, and you narrow the screen one or two columns -- just
> enough to cause the text to require, say, three lines instead of two.  In
> this instance, Terminal wraps the text on its own -- meaning the cursor i=
s
> now on the third `physical' line -- before sending bash a SIGWINCH. At th=
is
> point, readline tries to perform redisplay assuming the cursor is still o=
n
> the second line and that the terminal emulator hasn't done anything, so i=
ts
> position calculations are off from the start.  This can easily leave stra=
y
> lines of text on the screen that readline doesn't (and can't) know about.
>
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~c=
het/


From MAILER-DAEMON Mon Jun 12 22:17:34 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKbOg-0006d2-NH
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 22:17:34 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52254)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKbOe-0006ce-Mk
	for bug-bash@gnu.org; Mon, 12 Jun 2017 22:17:33 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKbOd-0003sR-E8
	for bug-bash@gnu.org; Mon, 12 Jun 2017 22:17:32 -0400
Received: from mail-pg0-x236.google.com ([2607:f8b0:400e:c05::236]:34415)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dKbOd-0003s9-8O
	for bug-bash@gnu.org; Mon, 12 Jun 2017 22:17:31 -0400
Received: by mail-pg0-x236.google.com with SMTP id v18so53067919pgb.1
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 19:17:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=rdX4exXbI7Gf56o+6scF/Mwr4gxYDgcc0f10E6c+7go=;
	b=FUpN61MtqtVayGgM/5rgHNw5Py1871eH7PvavkLdVqIfis49bBWYsbD3keFgVccGhK
	pOJPiz1J1qXNTuJz1ErdMOjTKIkL6tFJi7AHJeVpj6KZQJHrJBXe8fhklPhDPOkf5Jcv
	P/0U+QHpckKxbbVcntSBUumzCCoA90vLYN9UMsUd7OOyoFkqBK62zJ+Zfab2P7LnFsGk
	aXbNKNZ7++PH2sYT+5mF210hn/Nh20r0jCuYUjSSvTe34JeQFxnTNntIKxi3aqhTtpF3
	4JhxEe9L+/OxqITAsq8mrPiKZ3CX/+pS2PdImeBMLamlHGzVaev4OAfqWsOXLlnbbeEd
	S9HQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=rdX4exXbI7Gf56o+6scF/Mwr4gxYDgcc0f10E6c+7go=;
	b=U+1A7m95ysapTcZhEMM6vltoQaL3t830GdMGyC9fAypwzYkcIqZgbAUzDqMYE3DIZ4
	2XOL9C7/c+ni87pABII/fVNQKiwI3CFKJGRnaB4xHB2MxOBFJuUmvdAsv5Uyr2OV6rHl
	JWLvtsReVVkIgsW/X/oTczxBPZDyb1P/yjK3bPCJezuexNbBrYW3RHZIUH4lhIYos3/n
	EOL9KE5Xb78VEtSl2vv0hCkFKwcVdsf0hvrLUJYhw84gd79TO2AOrFN0775wH784zKFR
	oZPAtzVDyha1GehvsyzpaNH/AmoHunaWP3LeJmBRE5z+wjCHoGpymCxPHlZY5t6oFXpv
	tFhg==
X-Gm-Message-State: AODbwcC4BB/72xOnjTVfRpqXf7dPvB+swyp7GbTexcVmTovJ10gLw18i
	zE+DA2PH8PN3x5H5ZSRbmglXfWfx12JSkP4=
X-Received: by 10.84.193.36 with SMTP id e33mr48684663pld.293.1497320250240;
	Mon, 12 Jun 2017 19:17:30 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.140.23 with HTTP; Mon, 12 Jun 2017 19:16:49 -0700 (PDT)
In-Reply-To: <593EE202.7070706@tlinx.org>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
	<593EE202.7070706@tlinx.org>
From: Clark Wang <dearvoid@gmail.com>
Date: Tue, 13 Jun 2017 10:16:49 +0800
Message-ID: <CADv8-oh7XhMNAcqkfmcc4fNJQEBrwwrpukdJhZn4bhoivqa9Xg@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: L A Walsh <bash@tlinx.org>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::236
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 02:17:33 -0000

On Tue, Jun 13, 2017 at 2:48 AM, L A Walsh <bash@tlinx.org> wrote:

> Clark Wang wrote:
>
>>
>> I've checked the ssh process and it does not catch SIGTTIN and that's why
>> I'm confused.
>>
>>
> ----
>    From what I understand, a background process will automatically
> block when it tries to read from STDIN.  By definition, processes
> become bg-processes by using '&'.  I haven't looked at the
> code, but I'm guessing that the first 'ssh' that you launched
> (*without* the '&') is the process swallowing your input as
> it was declared to be a some sort of master-multiplexer for
> subsequent slave processes, but that's just a guess.  Maybe
> putting the master in background @ launch (using '&') will
> cause it to auto-block(suspend) as you expect?
>

The first ssh (with `-f`) would fork another ssh running as a daemon which
would detach from the current tty. It makes no difference whether to use
`&` or not. Please see my explanation @stackoverflow:
https://stackoverflow.com/questions/44492312/ .

-clark

From MAILER-DAEMON Mon Jun 12 23:00:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKc4h-0006vl-ST
	for mharc-bug-bash@gnu.org; Mon, 12 Jun 2017 23:00:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57704)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKc4f-0006ve-VZ
	for bug-bash@gnu.org; Mon, 12 Jun 2017 23:00:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKc4b-0007IM-I6
	for bug-bash@gnu.org; Mon, 12 Jun 2017 23:00:58 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:48206
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKc4a-0007Go-9h
	for bug-bash@gnu.org; Mon, 12 Jun 2017 23:00:52 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5D30fPw000678; Mon, 12 Jun 2017 20:00:44 -0700
Message-ID: <593F5559.3050402@tlinx.org>
Date: Mon, 12 Jun 2017 20:00:41 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Clark Wang <dearvoid@gmail.com>
CC: "bash.bug list" <bug-bash@gnu.org>
Subject: Re: A background ssh can take over the tty from bash?
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>	<593EE202.7070706@tlinx.org>
	<CADv8-oh7XhMNAcqkfmcc4fNJQEBrwwrpukdJhZn4bhoivqa9Xg@mail.gmail.com>
In-Reply-To: <CADv8-oh7XhMNAcqkfmcc4fNJQEBrwwrpukdJhZn4bhoivqa9Xg@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 03:00:59 -0000



Clark Wang wrote:
> On Tue, Jun 13, 2017 at 2:48 AM, L A Walsh <bash@tlinx.org> wrote:
>
>   
>> Clark Wang wrote:
>>
>>     
>>> I've checked the ssh process and it does not catch SIGTTIN and that's why
>>> I'm confused.
>>>
>>>
>>>       
>> ----
>>    From what I understand, a background process will automatically
>> block when it tries to read from STDIN.  By definition, processes
>> become bg-processes by using '&'.  I haven't looked at the
>> code, but I'm guessing that the first 'ssh' that you launched
>> (*without* the '&') is the process swallowing your input as
>> it was declared to be a some sort of master-multiplexer for
>> subsequent slave processes, but that's just a guess.  Maybe
>> putting the master in background @ launch (using '&') will
>> cause it to auto-block(suspend) as you expect?
>>
>>     
>
> The first ssh (with `-f`) would fork another ssh running as a daemon which
> would detach from the current tty. 
---
    Which means from the shell's standpoint, it was no longer a normal
background process that would be prevented from reading input by being
sent a SIGTTIN. 


being suspended
> It makes no difference whether to use
> `&` or not. 
----
    By disconnecting from the controlling terminal (which
it would do regardless of whether '&' was used because it demonized),
you removed it from normal job-control where it might get a SIGTTIN.
Since you didn't disconnect it's input from your foreground terminal
it conflicted.  I.e. if you want SIGTTIN to function, you need to
have the background process remain in the TTY group -- not become a daemon.

   The most common way to put a process
in background and keep it in the same TTY group is using '&'.  If you
tell a process to background itself (not using '&'), many (though not
all) will disconnect from the controlling terminal and not stay
in your process group.

    In this case you need to use "-n" with "-f" OR not use
either if you wish it to be suspended. 

    If I launch ssh without "-f" but put it in background, it doesn't
grab the foreground terminal (and the DOES get suspended when it
tries to do input).

> Please see my explanation @stackoverflow:
> https://stackoverflow.com/questions/44492312/ .
>   
Seems to be saying similar -- that the demonizing process needs
to be disconnected from stdin. 

It doesn't mention that you can have it be suspended
(as you seemed to expect), by not having it daemonize.





From MAILER-DAEMON Tue Jun 13 00:45:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKdiJ-0007l2-IT
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 00:45:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45984)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKdiG-0007kq-Vr
	for bug-bash@gnu.org; Tue, 13 Jun 2017 00:45:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dearvoid@gmail.com>) id 1dKdiF-0003qh-Nq
	for bug-bash@gnu.org; Tue, 13 Jun 2017 00:45:56 -0400
Received: from mail-pg0-x235.google.com ([2607:f8b0:400e:c05::235]:35683)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dearvoid@gmail.com>) id 1dKdiF-0003pn-DU
	for bug-bash@gnu.org; Tue, 13 Jun 2017 00:45:55 -0400
Received: by mail-pg0-x235.google.com with SMTP id k71so54588495pgd.2
	for <bug-bash@gnu.org>; Mon, 12 Jun 2017 21:45:52 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=V7yyB4Oz5FRRGPUlC8k5Lumahr0h0a+gnxtnz9+TjUc=;
	b=m2AL4zrlpl5xoRA9k1f9SI8zw/Yt/LMg9suvsTZ0uNxbvC0glFFJwq6DofGkDSkHXn
	sw8uiypdsMkMIJUlVh432MhrE9muhEkPltQaz+is4MmtResV38j9JS/qBO57nVuCNEv+
	42KAOmn8GF4UI6lOGmBoUus4oB3Yll7SCrbl6QBOLG2q+uBrqAnh7WrlO5RuOAa3MsWr
	I9LxK6OR7ZbCaYrBBVRcRz0HLFRYZSih9QJ3uyDXqyIu4gIJsRwxaAq/WQ30yMYETJp4
	co6dJQu0/hrOGhdCo+2ZijuUGldCwt4u+1+y1mLHVvUqUryXqHPM30SohT3BYSOgKfeM
	gXdA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=V7yyB4Oz5FRRGPUlC8k5Lumahr0h0a+gnxtnz9+TjUc=;
	b=BG7YcLKacsoQj/HuPoYCLqw5ZSNB3IT/ftDxBTJtuwGC3MNE0Su0IvIbGX8NeyvhEz
	92p0G+r5SAPSH5Y4VLRCPCXHp7HVjij5hHXW7RLyWteKmAiVLTtwuxD6lchkdC12+opG
	LwuV9Tq+l8iOnr5otpZuRA9V6d/9wg1XR0VFBXeOcTK8pZVNy2D3B7kPWoe+OBZEHIVh
	u0gU5Nw8gXkSndaTKzw+tIYgJw/8Q7B0DbJx7XkgXC3eKc70ccDfEKsaG4vii+wFXzSA
	W0WA4nZqrx0yoTNtrJ+cVh/uyF9ykNl6KO9GikrH3EMhYV56s9MxpM7onapIthj3U+wg
	9UnA==
X-Gm-Message-State: AODbwcBNAQgqWMxfVlMV0MMMDqR0ItSAf+aL2od2I9Y4m4KRcO6JCpoN
	FKz3i2JwICHYl6M7I8KNSWlKF5rFsHQM
X-Received: by 10.98.28.74 with SMTP id c71mr34382483pfc.154.1497329151693;
	Mon, 12 Jun 2017 21:45:51 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.100.140.23 with HTTP; Mon, 12 Jun 2017 21:45:11 -0700 (PDT)
In-Reply-To: <593F5559.3050402@tlinx.org>
References: <CADv8-ojQbt1JtO59rihkPS0Du3+usr_w=EOgQ5zGUsHSkQ8QXw@mail.gmail.com>
	<b9c6e8ba-95e3-13d0-4e93-b5814f6866b7@case.edu>
	<CADv8-oh-d6g3dg2pTC5ap+a5f4twTiDAwM9cY4vbWQ8Bb=oYQQ@mail.gmail.com>
	<593EE202.7070706@tlinx.org>
	<CADv8-oh7XhMNAcqkfmcc4fNJQEBrwwrpukdJhZn4bhoivqa9Xg@mail.gmail.com>
	<593F5559.3050402@tlinx.org>
From: Clark Wang <dearvoid@gmail.com>
Date: Tue, 13 Jun 2017 12:45:11 +0800
Message-ID: <CADv8-ogVX7fiHg+Sr+-XQ8jLYHhq0k8Y67nASBoPfOvohhyRsg@mail.gmail.com>
Subject: Re: A background ssh can take over the tty from bash?
To: L A Walsh <bash@tlinx.org>
Cc: "bash.bug list" <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::235
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 04:45:58 -0000

On Tue, Jun 13, 2017 at 11:00 AM, L A Walsh <bash@tlinx.org> wrote:

>
>    In this case you need to use "-n" with "-f" OR not use
> either if you wish it to be suspended.
>

I did want the `ssh -o ControlMaster=yes` to run as a daemon.


>    If I launch ssh without "-f" but put it in background, it doesn't
> grab the foreground terminal (and the DOES get suspended when it
> tries to do input).
>
> Please see my explanation @stackoverflow:
>> https://stackoverflow.com/questions/44492312/ .
>>
>>
> Seems to be saying similar -- that the demonizing process needs
> to be disconnected from stdin.
>

`-f` implies `-n` so it is effectively disconnected from the tty (though
it's still opening the tty device with FDs 0, 1, 2 but it would never read
from FD 0). The magic part here is it's the 2nd `ssh ... sleep` that asks
the 1st `ssh -o ControlMaster=yes` to open (by passing the FDs to it) the
tty again (with new FDs) and read from it.


> It doesn't mention that you can have it be suspended
> (as you seemed to expect), by not having it daemonize.
>

As I mentioned ealier, I don't want the `ssh -o ControlMaster=yes` to be
suspended.

-clark

From MAILER-DAEMON Tue Jun 13 08:08:19 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKkcM-0006YB-Vq
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 08:08:19 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58758)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKkcL-0006Y2-4P
	for bug-bash@gnu.org; Tue, 13 Jun 2017 08:08:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKkcB-00033Z-Kq
	for bug-bash@gnu.org; Tue, 13 Jun 2017 08:08:17 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:35815 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKkcB-0002nh-E5
	for bug-bash@gnu.org; Tue, 13 Jun 2017 08:08:07 -0400
Received: (qmail 871 invoked from network); 13 Jun 2017 12:07:37 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Tue, 13 Jun 2017 08:07:37 -0400
Received: (qmail 21088 invoked by uid 563); 13 Jun 2017 12:07:37 -0000
Date: Tue, 13 Jun 2017 08:07:37 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash@gnu.org
Subject: Re: consistency probs var & function re-use
Message-ID: <20170613120737.GR3691@eeg.ccf.org>
References: <5939D1AD.9010909@tlinx.org> <5939D435.9050900@tlinx.org>
	<20170609122511.GM3691@eeg.ccf.org> <593B26C5.6070002@tlinx.org>
	<4acada15-9482-e024-d8f6-de431fb8da58@gmail.com>
	<593DC96E.101@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <593DC96E.101@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 12:08:18 -0000

On Sun, Jun 11, 2017 at 03:51:26PM -0700, L A Walsh wrote:
> I was pointing out that the reason 'declare' used a newline, was that he
> had not quoted the input to 'x', which is expanded to a newline
> before it is assigned to 'x'.

You are completely wrong here.  My variable 'x' had a newline in its
content.  I used the $'...' quoting syntax to enter it as such.

Your variable did not have a newline in it, because you used "..."
quoting.

The result of declare -p x is a bash command that you can eval (or
source) to recreate the variable x with the same content and attributes.
(But not scope, of course.  It doesn't encode scope information.)

Bash is free to use a different kind of quoting around the variable
content in declare -p's output.  I don't care that bash chooses a
different formatting than I used.  The end result is the same variable,
so it simply doesn't matter.

>   hh(){ echo "hi"; }
> which gets printed out as:
> 
>  declare -f hh
>  hh ()
>  {
>      echo "hi"
>  }

But it's the *same function*.  It's just got different formatting.
Given the same arguments, both of them execute the same commands.
This is the definition of reusability that we're working with.

Does it reproduce your exact formatting?  No.  It's not intended to.
In fact, some people *like* it this way.  It's a pretty-printer for
functions.

> I.e. it wasn't that I wanted to embed newlines in the function, but that
> I wanted it to print out the same way it was input.

Then store it in a file and source that file every time you want to use
it.  If you want to see your gorgeous whitespace formatting, cat the file.

declare -fp is not a guarantee of whitespace preservation.  It's merely
a guarantee that the resulting function works the same way.


From MAILER-DAEMON Tue Jun 13 11:14:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKnWp-0001PA-HU
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 11:14:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53042)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKnWm-0001NP-Al
	for bug-bash@gnu.org; Tue, 13 Jun 2017 11:14:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKnWf-00068V-Ib
	for bug-bash@gnu.org; Tue, 13 Jun 2017 11:14:44 -0400
Received: from mail-oi0-x231.google.com ([2607:f8b0:4003:c06::231]:35914)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dKnWf-00067i-CW
	for bug-bash@gnu.org; Tue, 13 Jun 2017 11:14:37 -0400
Received: by mail-oi0-x231.google.com with SMTP id k145so62766273oih.3
	for <bug-bash@gnu.org>; Tue, 13 Jun 2017 08:14:35 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:content-transfer-encoding:user-agent;
	bh=RNdwZ9hslrPbByYe84XvK83vKrCYvDAL5FkGxbYFsGw=;
	b=mIig+1glRX+JcPBAeoagvGT9PPavdOJoIHzBGDaJuh2CHCCkXWwzJs4Nd335AyXEMU
	KWVjWdH9XTaUlt/FsvFIvNgXFmbRFdldxMvWHn2p9YMaIRmpsw3SBcbX3D9SvK1OljUJ
	anSgmYJ1i/RcL9Ju5Z0oF2aGgnDZHN+cxK8XFujAqbNgAEsMGvHvhVNKk+ybhqOJaplF
	4ezWYZJnCBL5ofWn5mLe5GaIOSzco2gELF0TMW1aOgfhpa/B2K8koXwbKrKqbzruSkO/
	+UYhwl1kpa9qrV/cQiEE2j0VIheL5yfw3MVjPxpMb47Hqw7uICvpXNQGL6FVDhn2N5G4
	WNQw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:content-transfer-encoding:user-agent;
	bh=RNdwZ9hslrPbByYe84XvK83vKrCYvDAL5FkGxbYFsGw=;
	b=DWGRUvH9s3YnSK2Co6S6/KeVeTQz6EZskdKWM3IGn09hn/lOIelWucellU0ONPqXZR
	s2oH30OYmGeT7TjFq/erPm1YkYZDJN6rsWhrzLqaTLur/e5RTuD49naYGFapIGVGt5M5
	D04BmNf8keZwZn8LthuA4e2qJSUu0FInoCXSAFaiStcYHPYU8Vg2A4bbV1ttFyYYbWf3
	Jlrgp9pieHNRSmR6Doxq8AO92N5IIxRd0KhycPhJUF5lc+HlYRWS9ljtoWi0bTEtbPa1
	5b5kTz0GJuySLHcJN/qgkhrxB+O1DjET1p2zYYezREyXIbgpXJYsjYH9SPoUKhaAcR+w
	80Cg==
X-Gm-Message-State: AKS2vOy9sacWdzw+ltFzD1VFXNv9M3CUGVOeLM4M391QwGhRis2t2AWL
	6XiOCyQnqWWCsrFh
X-Received: by 10.202.253.73 with SMTP id b70mr240255oii.54.1497366874776;
	Tue, 13 Jun 2017 08:14:34 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	f68sm6535615otb.32.2017.06.13.08.14.33
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Tue, 13 Jun 2017 08:14:34 -0700 (PDT)
Date: Tue, 13 Jun 2017 10:14:31 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow _rl_find_prev_mbchar_internal
	/ expand_prompt
Message-ID: <20170613151431.ka6rw6tnjaavtyco@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::231
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 15:14:46 -0000

It seems like this is another case of strlen reading too much.


dualbus@debian:~/src/gnu/bash-build$ base64 < /home/dualbus/bash-fuzzing/read-readline/output/10/crashes/id:000011,sig:06,src:001239+003201,op:splice,rep:2
GwMWF/zuFQAXCxcXFwAD6FNTALwAABAAgCkZGRkZ/zpQFxkZGRkZGRcXIH/6AAD6jlxchDP8GQAB
AFhLYEpLZ0tKOEsQSz0aGgIZGSEZAID/GRkZGRkZS0tXS0tLAAAAAEtLHBMZWmBKS0tLSjhLEEtL
S0tKS0tLSj0+EEtLHBkZGRkZGbS8Ehn/OlAXGRkZGRkZFxcgLA==


dualbus@debian:~/src/gnu/bash-build$ ASAN_OPTIONS=disable_coredump=0:unmap_shadow_on_exit=1:abort_on_error=1 ./bash -c 'read -e' < /home/dualbus/bash-fuzzing/read-readline/output/10/crashes/id:000011,sig:06,src:001239+003201,op:splice,rep:2 > /dev/null 2>&1
Aborted (core dumped)


dualbus@debian:~/src/gnu/bash-build$ cat stacktrace 
=================================================================
==26129==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60d00000c159 at pc 0x7f40f3b2a063 bp 0x7ffed8a00070 sp 0x7ffed89ff820
READ of size 138 at 0x60d00000c159 thread T0
    #0 0x7f40f3b2a062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x558a2174188b in _rl_find_prev_mbchar_internal ../../../bash/lib/readline/mbutil.c:162
    #2 0x558a2174235c in _rl_find_prev_mbchar ../../../bash/lib/readline/mbutil.c:369
    #3 0x558a21710ca1 in expand_prompt ../../../bash/lib/readline/display.c:471
    #4 0x558a2171c190 in rl_message ../../../bash/lib/readline/display.c:2642
    #5 0x558a2170a986 in rl_display_search ../../../bash/lib/readline/isearch.c:196
    #6 0x558a2170fab7 in _rl_isearch_dispatch ../../../bash/lib/readline/isearch.c:718
    #7 0x558a2170fcae in rl_search_history ../../../bash/lib/readline/isearch.c:762
    #8 0x558a2170a7ac in rl_reverse_search_history ../../../bash/lib/readline/isearch.c:136
    #9 0x558a216e030d in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
    #10 0x558a216dfee8 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
    #11 0x558a216df727 in readline_internal_char ../../../bash/lib/readline/readline.c:629
    #12 0x558a216df7b9 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
    #13 0x558a216df7dd in readline_internal ../../../bash/lib/readline/readline.c:670
    #14 0x558a216dee93 in readline ../../../bash/lib/readline/readline.c:374
    #15 0x558a2169a136 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1095
    #16 0x558a21697aa4 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:559
    #17 0x558a215adc89 in execute_builtin ../bash/execute_cmd.c:4609
    #18 0x558a215af89f in execute_builtin_or_function ../bash/execute_cmd.c:5107
    #19 0x558a215ad11f in execute_simple_command ../bash/execute_cmd.c:4395
    #20 0x558a2159af42 in execute_command_internal ../bash/execute_cmd.c:811
    #21 0x558a216850f4 in parse_and_execute ../../bash/builtins/evalstring.c:430
    #22 0x558a21566401 in run_one_command ../bash/shell.c:1405
    #23 0x558a215648da in main ../bash/shell.c:718
    #24 0x7f40f33422b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x558a21563749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)

0x60d00000c159 is located 0 bytes to the right of 137-byte region [0x60d00000c0d0,0x60d00000c159)
allocated by thread T0 here:
    #0 0x7f40f3bafd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x558a21673d95 in xmalloc ../bash/xmalloc.c:112
    #2 0x558a21710574 in expand_prompt ../../../bash/lib/readline/display.c:389
    #3 0x558a2171c190 in rl_message ../../../bash/lib/readline/display.c:2642
    #4 0x558a2170a986 in rl_display_search ../../../bash/lib/readline/isearch.c:196
    #5 0x558a2170fab7 in _rl_isearch_dispatch ../../../bash/lib/readline/isearch.c:718
    #6 0x558a2170fcae in rl_search_history ../../../bash/lib/readline/isearch.c:762
    #7 0x558a2170a7ac in rl_reverse_search_history ../../../bash/lib/readline/isearch.c:136
    #8 0x558a216e030d in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
    #9 0x558a216dfee8 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
    #10 0x558a216df727 in readline_internal_char ../../../bash/lib/readline/readline.c:629
    #11 0x558a216df7b9 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
    #12 0x558a216df7dd in readline_internal ../../../bash/lib/readline/readline.c:670
    #13 0x558a216dee93 in readline ../../../bash/lib/readline/readline.c:374
    #14 0x558a2169a136 in edit_line ../../bash/builtins/../../bash/builtins/read.def:1095
    #15 0x558a21697aa4 in read_builtin ../../bash/builtins/../../bash/builtins/read.def:559
    #16 0x558a215adc89 in execute_builtin ../bash/execute_cmd.c:4609
    #17 0x558a215af89f in execute_builtin_or_function ../bash/execute_cmd.c:5107
    #18 0x558a215ad11f in execute_simple_command ../bash/execute_cmd.c:4395
    #19 0x558a2159af42 in execute_command_internal ../bash/execute_cmd.c:811
    #20 0x558a216850f4 in parse_and_execute ../../bash/builtins/evalstring.c:430
    #21 0x558a21566401 in run_one_command ../bash/shell.c:1405
    #22 0x558a215648da in main ../bash/shell.c:718
    #23 0x7f40f33422b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)

SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c1a7fff97d0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff97e0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff97f0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9800: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9810: fa fa fa fa fa fa fa fa fa fa 00 00 00 00 00 00
=>0x0c1a7fff9820: 00 00 00 00 00 00 00 00 00 00 00[01]fa fa fa fa
  0x0c1a7fff9830: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff9840: fd fd fd fd fd fd fa fa fa fa fa fa fa fa fd fd
  0x0c1a7fff9850: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff9860: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c1a7fff9870: fd fd fd fd fd fd fd fd fd fd fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==26129==ABORTING


(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007f40f33563fa in __GI_abort () at abort.c:89
#2  0x00007f40f3bc9329 in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#3  0x00007f40f3bbe9ab in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#4  0x00007f40f3bb8b57 in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#5  0x00007f40f3b2a07e in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#6  0x0000558a2174188c in _rl_find_prev_mbchar_internal (
    string=0x60d00000c0d0 "(reverse-i-search)`=\372\\\\3\372\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀", '\276' <repeats 52 times>, seed=85, 
    find_non_zero=0) at ../../../bash/lib/readline/mbutil.c:162
#7  0x0000558a2174235d in _rl_find_prev_mbchar (
    string=0x60d00000c0d0 "(reverse-i-search)`=\372\\\\3\372\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀", '\276' <repeats 52 times>, seed=85, flags=0)
    at ../../../bash/lib/readline/mbutil.c:369
#8  0x0000558a21710ca2 in expand_prompt (
    pmt=0x60e00000df60 "(reverse-i-search)`=\372\\\\3\372\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P': ", flags=0, 
    lp=0x558a21a06040 <prompt_visible_length>, lip=0x558a21a06100 <prompt_last_invisible>, 
    niflp=0x558a21a06180 <prompt_invis_chars_first_line>, vlp=0x558a21a06200 <prompt_physical_chars>)
    at ../../../bash/lib/readline/display.c:471
#9  0x0000558a2171c191 in rl_message (format=0x558a2178dc80 "%s") at ../../../bash/lib/readline/display.c:2642
#10 0x0000558a2170a987 in rl_display_search (
    search_string=0x60c00000bb00 "=\372\\\\3\372\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P", flags=3, where=-1) at ../../../bash/lib/readline/isearch.c:196
#11 0x0000558a2170fab8 in _rl_isearch_dispatch (cxt=0x60f00000ed70, c=25) at ../../../bash/lib/readline/isearch.c:718
#12 0x0000558a2170fcaf in rl_search_history (direction=-1, invoking_key=18) at ../../../bash/lib/readline/isearch.c:762
#13 0x0000558a2170a7ad in rl_reverse_search_history (sign=1, key=18) at ../../../bash/lib/readline/isearch.c:136
#14 0x0000558a216e030e in _rl_dispatch_subseq (key=18, map=0x558a219e9da0 <emacs_standard_keymap>, got_subseq=0)
    at ../../../bash/lib/readline/readline.c:851
#15 0x0000558a216dfee9 in _rl_dispatch (key=-214609969, map=0x558a219e9da0 <emacs_standard_keymap>)
    at ../../../bash/lib/readline/readline.c:797
#16 0x0000558a216df728 in readline_internal_char () at ../../../bash/lib/readline/readline.c:629
#17 0x0000558a216df7ba in readline_internal_charloop () at ../../../bash/lib/readline/readline.c:656
#18 0x0000558a216df7de in readline_internal () at ../../../bash/lib/readline/readline.c:670
#19 0x0000558a216dee94 in readline (prompt=0x558a2177a000 "") at ../../../bash/lib/readline/readline.c:374
#20 0x0000558a2169a137 in edit_line (p=0x558a2177a000 "", itext=0x0) at ../../bash/builtins/../../bash/builtins/read.def:1095
---Type <return> to continue, or q <return> to quit---
#21 0x0000558a21697aa5 in read_builtin (list=0x0) at ../../bash/builtins/../../bash/builtins/read.def:559
#22 0x0000558a215adc8a in execute_builtin (builtin=0x558a21696013 <read_builtin>, words=0x60200000c630, flags=64, subshell=0)
    at ../bash/execute_cmd.c:4609
#23 0x0000558a215af8a0 in execute_builtin_or_function (words=0x60200000c630, builtin=0x558a21696013 <read_builtin>, var=0x0, 
    redirects=0x0, fds_to_close=0x60200000c7d0, flags=64) at ../bash/execute_cmd.c:5107
#24 0x0000558a215ad120 in execute_simple_command (simple_command=0x60300000c4f0, pipe_in=-1, pipe_out=-1, async=0, 
    fds_to_close=0x60200000c7d0) at ../bash/execute_cmd.c:4395
#25 0x0000558a2159af43 in execute_command_internal (command=0x60300000c520, asynchronous=0, pipe_in=-1, pipe_out=-1, 
    fds_to_close=0x60200000c7d0) at ../bash/execute_cmd.c:811
#26 0x0000558a216850f5 in parse_and_execute (string=0x60200000c910 "read -e", from_file=0x558a21746120 "-c", flags=4)
    at ../../bash/builtins/evalstring.c:430
#27 0x0000558a21566402 in run_one_command (command=0x7ffed8a03718 "read -e") at ../bash/shell.c:1405
#28 0x0000558a215648db in main (argc=3, argv=0x7ffed8a018e8, env=0x7ffed8a01908) at ../bash/shell.c:718


(gdb) frame 6
#6  0x0000558a2174188c in _rl_find_prev_mbchar_internal (
    string=0x60d00000c0d0 "(reverse-i-search)`=\372\\\\3\372\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀)\027\374\027\374\027\374\027\374\377:P\356SS輀", '\276' <repeats 52 times>, seed=85, 
    find_non_zero=0) at ../../../bash/lib/readline/mbutil.c:162
162       length = strlen(string);


-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 13 14:08:49 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKqFF-0007Ue-CL
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 14:08:49 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40088)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqFD-0007UT-8a
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:08:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqFA-0008Jb-2t
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:08:47 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:41637
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqF9-0008JL-TC
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:08:44 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN04337; Tue, 13 Jun 2017 14:08:40 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM19131 (AUTH cpr);
	Tue, 13 Jun 2017 14:08:39 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>, bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <69cd1147-3b26-6436-c211-1156e464e647@case.edu>
Date: Tue, 13 Jun 2017 14:08:39 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5930B488.7020605@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.13.170616:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __C230066_P5, __SUBJ_ALPHA_NEGATE,
	__MULTIPLE_URI_TEXT, __URI_IN_BODY, __URI_NOT_IMG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_800_899, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 18:08:48 -0000

On 6/1/17 8:42 PM, L A Walsh wrote:
> It would be a useful upgrade besides being a "good world citizen" ;-).

The only way this makes sense is to extend the allowable set of
characters from the portable character set to the current locale.

> I'm guessing that if POSIX was set, then they'd be limited
> to the ASCII (American Standard Code for Information Interchange)
> set.  ;^)

Not quite; it's a subset of characters from the Portable Character Set.
That's the set of characters that Posix requires to be present in all
locales supported by Posix systems.

http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_235
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 14:14:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKqKN-0001uY-Sv
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 14:14:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41037)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqKL-0001uQ-E3
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:14:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqKG-0001U3-Fn
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:14:05 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:42359
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqKG-0001T7-AR
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:14:00 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN04563; Tue, 13 Jun 2017 14:13:56 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM20230 (AUTH cpr);
	Tue, 13 Jun 2017 14:13:56 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: dualbus <dualbus@gmail.com>, L A Walsh <bash@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <5d777cd9-e61a-e293-3c85-7bb39231247d@case.edu>
Date: Tue, 13 Jun 2017 14:13:55 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170602045255.4uqtbnsxryrfc432@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.170616:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __STOCK_PHRASE_24, __CP_URI_IN_BODY,
	__FRAUD_CONTACT_NAME, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_1100_1199, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 18:14:06 -0000

On 6/2/17 12:52 AM, dualbus wrote:

> - There are some questions that must be answered first:
> 
>   * How do you how to decode multibyte character sequences into Unicode? 
>     Should UTF-8 be assumed?

It has to be the current locale.

>   * Will the parsing of a script depend upon the user locale?

Only in the sense that identifiers will depend on the current locale.

>   * Should this special parsing code be disabled if POSIX mode is
>     enabled?

Yes. Posix requires that variables be names, as defined below.  However,
it should be possible to enable it while in Posix mode as an extension.

>   * Right now `name' or `identifier' is defined as:
> 
>       name: A word consisting only of alphanumeric characters and
>       underscores, and beginning with an alphabetic character or an
>       underscore. Also referred to as an identifier.
> 
>     How will the definition look like with Unicode identifiers?

Add 'from the current locale's character set'.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 14:18:36 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKqOi-0004U3-PJ
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 14:18:36 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42046)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqOg-0004SU-NS
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:18:35 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqOb-0003BF-Oj
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:18:34 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:17095
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKqOb-0003B9-Iu
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:18:29 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH98451; Tue, 13 Jun 2017 14:18:25 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFW20169 (AUTH cpr);
	Tue, 13 Jun 2017 14:18:25 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>, dualbus <dualbus@gmail.com>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <79df3981-3bba-0d4a-b3f4-5c3644b2bbdd@case.edu>
Date: Tue, 13 Jun 2017 14:18:24 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5930F4AE.1050308@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.175116:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1200_1299, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 18:18:35 -0000

On 6/2/17 1:16 AM, L A Walsh wrote:
> 
> 
> dualbus wrote:
>>
>> - People then have to test the new implementation, to ensure that there
>>   are no regressions, and no new bugs introduced. I'm happy to volunteer
>>   once there's a working implementation.
>>
>> - There are some questions that must be answered first:
>>
>>   * How do you how to decode multibyte character sequences into Unicode?
>>     Should UTF-8 be assumed?
>>   
> You realize bash already allows UTF-8 input?

Sure. The difference is that it depends on the current locale.



>> What prevents you from using?
>>   phi='...'
>>   
> ---
> Again, you are changing the requirement. 

He's not actually changing the requirement here.

> I don't suppose we wanted something more expressive or symbolic?

That's the essential question: is the cost of such a change worth the
improvement in the expressive power of the language? Will enough people
take advantange of the new feature to justify the implementation and
support effort?

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 14:30:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKqa2-0000LE-08
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 14:30:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43978)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKqZz-0000Ji-7Z
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:30:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKqZv-0006GE-9H
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:30:15 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:56846
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKqZu-0006EG-V8
	for bug-bash@gnu.org; Tue, 13 Jun 2017 14:30:11 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5DIU3xk075494; Tue, 13 Jun 2017 11:30:05 -0700
Message-ID: <59402F2B.7090103@tlinx.org>
Date: Tue, 13 Jun 2017 11:30:03 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<69cd1147-3b26-6436-c211-1156e464e647@case.edu>
In-Reply-To: <69cd1147-3b26-6436-c211-1156e464e647@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 18:30:16 -0000



Chet Ramey wrote:
> On 6/1/17 8:42 PM, L A Walsh wrote:
>   
>> It would be a useful upgrade besides being a "good world citizen" ;-).
>>     
>
> The only way this makes sense is to extend the allowable set of
> characters from the portable character set to the current locale.
>
>   
>> I'm guessing that if POSIX was set, then they'd be limited
>> to the ASCII (American Standard Code for Information Interchange)
>> set.  ;^)
>>     
>
> Not quite; it's a subset of characters from the Portable Character Set.
> That's the set of characters that Posix requires to be present in all
> locales supported by Posix systems.
>
> http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_235
>   
Aren't all of those characters in ASCII?  I.e. wouldn't
ASCII be a limiting set?  It may not be the minimal set, since
many characters in ASCII aren't usable in varnames, but I
thought the allowed chars in vars were some set <= ASCII?

FWIW, though, in this case, since function names seem to
allow chars beyond ASCII, it seems consistent to, allow
a similar extension in varnames as is allowed in function
names.

It seems like it would be a greater support burden to
allow one set for functions while restricting the allowed
characters for variables to some smaller set, no?






From MAILER-DAEMON Tue Jun 13 15:04:39 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKr7H-0005lK-OD
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:04:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50904)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKr7F-0005l9-3r
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:04:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKr7A-0001wN-2B
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:04:37 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:24357
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKr79-0001wC-Qm
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:04:31 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI00642; Tue, 13 Jun 2017 15:04:25 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM28849 (AUTH cpr);
	Tue, 13 Jun 2017 15:04:25 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: tetsujin@scope-eye.net, dualbus <dualbus@gmail.com>,
	L A Walsh <bash@tlinx.org>
References: <f55d69ca52bedb84388602da18dbac4ef7d0b269@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <9ebad712-87bc-3dcf-82a2-0415a3ef0146@case.edu>
Date: Tue, 13 Jun 2017 15:04:24 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <f55d69ca52bedb84388602da18dbac4ef7d0b269@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.184815:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __HIGHBITS,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__INT_PROD_LOC, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW, BODY_SIZE_6000_6999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:04:38 -0000

On 6/2/17 12:54 PM, tetsujin@scope-eye.net wrote:


> I agree that allowing Unicode in parameter names is problematic:
> - there are characters that should be equivalent in principle, but
> aren't (For instance, the Greek letter pi (π) and the mathematical
> symbol pi (𝛑) - in some fonts they may render the same, but they
> are distinct code points) Some of these characters will look like Bash
> syntax, but be encoded differently.

That problem boils down to how they are encoded in the current locale.

> - there are characters that are equivalent, but can be encoded
> multiple ways (For instance, 'é' may be encoded as $'u00E9' or as
> $'eu0309') - broadly speaking this falls under the scope of "Unicode
> Normalization" - it's a well-explored problem but not a trivial one.
> (And it gets much worse with Asian languages, for instance)

None of the locale functions tackle normalization.  It all comes down
to how characters are encoded in locale description files.

> - Unicode introduces more whitespace characters - to allow Unicode
> glyphs in parameter names, one must also decide whether to interpret
> Unicode whitespace as whitespace (complicating parsing rules, word
> splitting rules, etc.) - or to treat only ASCII whitespace as
> whitespace (in which case Unicode whitespace can form part of a "word"
> without quoting - which could make such code visually confusing)

Sure, but if shell programmers are responsible, they'll avoid these
kinds of confusing constructs.

> - As you pointed out, this requires the shell to somehow establish a
> convention governing the character set used to interpret shell scripts

It's actually the same one that is currently used: the current locale.


> I think the value is that it allows the programmer to express
> themselves in their native language. 

Sure. The question is whether the expressive power gained, and how widely
it's used, compensates for the cost of implementation, support, and
performance.  There are always tradeoffs.




> Greg raises a fair point: Some platforms will simply be unable to view
> scripts written with Unicode symbols...
> ...Likewise, some platforms will be unable to view scripts written
> with other features that are already present, such as Unicode string
> literals, or Unicode command names.

Introducing locale dependencies is dangerous: a variable name that contains
valid alphabetic characters in the writer's locale may not be valid in the
user's locale.  It's up to the writer to set the locale appropriately.

> 
> But, on the other hand:
> - Even if your editor or terminal can't display the UTF-8 code, that
> doesn't mean the shell process can't RUN it.

As long as the locale is set appropriately.


> Frankly, making shell scripts broadly compatible (let alone
> "universally" compatible) is very, very difficult. Can you believe
> someone wrote a shell script that used the colon character as part of
> a "tar" archive name? They clearly didn't have GNU tar in mind when
> they wrote that...  This would be just another case of something
> useful-but-not-universally-compatible. (In other words, if the feature
> is added, it becomes one of those things you don't use if you want
> your script to be portable. Frankly if it were added to Bash now, most
> of us would have to wait 5-10 years for today's version of Bash to
> become "the oldest version our project must still support" before we
> could use the feature...  This is part of why I tend to be rather
> forward-looking when it comes to the question of what should be in the
> shell.)
> 
> To address your questions on related design decisions that would have
> to be made for this to work, here's how I'd approach it for a
> pre-existing language like Bash with a long legacy:
> 
> 1: For an interactive session, the character encoding of commands is
> taken from the locale.

It depends on what you mean by `commands'. If you mean shell reserved
words and builtins, no: those use the existing portable character set.
If you mean shell functions, those already use a superset of the current
locale: the permitted character set for function names is that for
filenames, except when the shell is in posix mode. If you mean commands
read from the file system, these inherit any restrictions placed on them
by the file system.

But that's not really what we're talking about here.

> 2: For a script, the character encoding of commands must be explicitly
> specified, probably via a shell option. 

You can already do this by setting the various locale environment
variables.

> (Ideally I think it should be
> specified per-file, but I don't know if Bash supports any kind of
> per-file shell options. This is so, for instance, a non-Unicode
> session that sources a Unicode shell script does not become a Unicode
> session, or a Unicode script that sources a non-Unicode script does
> not interpret that script as Unicode.)

It does if it sets the locale.

> 3: If a script does not specify its character encoding, then the
> behavior is like current versions of Bash: multi-byte characters are
> supported in some contexts (quoted strings, command names, words) but
> not others (parameter names)

The current behavior does depend on the character encoding defined by
the current locale.

> 4: Sub-shell invocation, command/process substitution, etc. inherit
> the character encoding of the parent shell.

As it does now.

> 5: Enabling Unicode parsing of the script doesn't add Unicode
> whitespace characters to IFS - it affects how the script is
> interpreted, not how the parsed code operates.

No, we're staying away from locale-specific reserved words and builtin
commands. That has real negative security implications.

> 6: If POSIX mode is active, I think all of this gets disabled and
> Unicode characters are disallowed as parameter names.

As I said in another message, you should be able to enable an option to
allow locale-specific alphabetic chartacters even when you're in Posix
mode. It's just disabled by default.

> I think another angle worth considering is that most of what I
> outlined above is only important if you want to take advantage of it
> for other features. For instance:
> - In order to support transcoding, to allow (for instance) a Latin-1
> script to source a Unicode script and for equivalently-named entities
> in the two to connect.

This is very hard to do without some hint from the user about the locale
to use.

> - In order to support Unicode whitespace as part of the language
> syntax

This is a really bad idea in general; you don't want the same script to
parse differently in different locales.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:22:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrOj-0003I0-3t
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:22:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54840)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrOh-0003H1-6h
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:22:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrOd-00089Q-4Y
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:22:39 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:34225
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrOc-00089F-V1
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:22:35 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI04766; Tue, 13 Jun 2017 15:22:27 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM34749 (AUTH cpr);
	Tue, 13 Jun 2017 15:22:27 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
Date: Tue, 13 Jun 2017 15:22:26 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5931E57E.8090801@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.184815:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_500_599, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:22:40 -0000

On 6/2/17 6:23 PM, L A Walsh wrote:

> As for unsupported systems, there is a reason they are no longer
> supported.  The world is already using UTF-8.  It's only a few
> luddites clinging to ascii as a last refuge. ;-)
> 
> What display/OS do you have that you can't run UTF-8 on?

This is a red herring. de_DE.UTF-8 and zh_KH.UTF-8 don't use the same
character set.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:24:09 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrQ9-00041x-HK
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:24:09 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55154)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrQ7-00041h-5F
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:24:08 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrQ3-0000JV-3z
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:24:07 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:34379
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrQ2-0000JH-Uk
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:24:03 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI04811; Tue, 13 Jun 2017 15:23:58 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM34920 (AUTH cpr);
	Tue, 13 Jun 2017 15:23:58 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, dualbus <dualbus@gmail.com>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: George <tetsujin@scope-eye.net>, L A Walsh <bash@tlinx.org>,
	bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <8e1b848a-2649-0dd0-001c-4599f04fd384@case.edu>
Date: Tue, 13 Jun 2017 15:23:58 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496512817.17253.69.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.184815:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_400_LESS, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_300_399, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:24:08 -0000

On 6/3/17 2:00 PM, George wrote:

> As it is, Bash bug reports and
> feature requests are neglected for years on end, 

If you have a bug report that's been neglected for that long, let me know.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:30:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrWZ-0005KI-0e
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:30:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56349)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrWX-0005KC-2L
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:30:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrWT-0002m7-QZ
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:30:45 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:6315
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKrWT-0002le-KY
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:30:41 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH88163; Tue, 13 Jun 2017 15:30:37 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFW35020 (AUTH cpr);
	Tue, 13 Jun 2017 15:30:37 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: dualbus <dualbus@gmail.com>, PePa <peterkelly@passchier.net>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <b3512918-a24e-f3ce-437b-9de99841ce8f@case.edu>
Date: Tue, 13 Jun 2017 15:30:36 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170604074538.36cmislgervrqiqw@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_800_899,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:30:46 -0000

On 6/4/17 3:45 AM, dualbus wrote:

> I know I said I wasn't going to reply, but this changed my mind :-)
> 
> I hadn't realized that bash already supports Unicode in function names!

When not in Posix mode, bash doesn't really have any restrictions on
characters that can be used in function names.  It's basically the same
namespace as external commands, with a few exceptions (no dollar signs,
no quoted strings, no all-digit names). You can even name a function
`/bin/true' and call it, as long as you quote the slashes.  With so few
restrictions, there's nothing to supporting locale-specific function
names -- they're just a string of bytes.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:33:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrZB-0005yF-KR
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:33:29 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56892)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrZ9-0005y8-DB
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:33:28 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrZ6-0003d1-Al
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:33:27 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:62106
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrZ6-0003cs-4s
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:33:24 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN11787; Tue, 13 Jun 2017 15:33:20 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM36587 (AUTH cpr);
	Tue, 13 Jun 2017 15:33:20 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>,
	PePa <peterkelly@passchier.net>
Subject: Re: Patch for unicode in varnames...
To: L A Walsh <bash@tlinx.org>, dualbus <dualbus@gmail.com>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <5158492c-b16f-d294-409a-c671f6dc731f@case.edu>
Date: Tue, 13 Jun 2017 15:33:19 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <593455D1.9050706@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_700_799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:33:28 -0000

On 6/4/17 2:47 PM, L A Walsh wrote:

> ----
>    Clarification, please, but it looks like with your
> patch below, Unicode in variable names might be fairly close
> to being achieved?  Seeing how it was done for functions,
> gave you insight into how variables could be done, yes?

No. It's not `done' for functions at all.

>    Why do you call it "terrible"?

Because it's a quick and dirty implementation that may not work in all
cases and has several obvious problems (memory leaks, etc.).


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:34:55 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKraZ-0006CI-6i
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:34:55 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57293)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKraX-0006CB-DZ
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:34:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKraU-0004RF-BL
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:34:53 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:62391
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKraU-0004R7-5c
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:34:50 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN11878; Tue, 13 Jun 2017 15:34:45 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM36867 (AUTH cpr);
	Tue, 13 Jun 2017 15:34:45 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>,
	PePa <peterkelly@passchier.net>
Subject: Re: Patch for unicode in varnames...
To: George <tetsujin@scope-eye.net>, L A Walsh <bash@tlinx.org>,
	dualbus <dualbus@gmail.com>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <b1284079-e7d0-6d5c-776c-c55298bf1db8@case.edu>
Date: Tue, 13 Jun 2017 15:34:44 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496652739.17253.82.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:34:54 -0000

On 6/5/17 4:52 AM, George wrote:
> the character type for the character conversion is derived from the user's locale
> (which means there's not a reliable mechanism in place to run a script in a locale whose character encoding doesn't match that of the script.)

There isn't today. The burden is on the script writer to specify the locale
appropriately, and always has been.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:40:37 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrg5-0007iR-Ow
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:40:37 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58378)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrg3-0007i8-Ae
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:40:36 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrg0-0006U9-7s
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:40:35 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:29148
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKrg0-0006Tu-1f
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:40:32 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMD09425; Tue, 13 Jun 2017 15:40:26 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM37899 (AUTH cpr);
	Tue, 13 Jun 2017 15:40:26 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
To: George <tetsujin@scope-eye.net>,
	Peter & Kelly Passchier <peterkelly@passchier.net>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <8c9337e4-6489-c7f5-0c12-c1756d9007ec@case.edu>
Date: Tue, 13 Jun 2017 15:40:26 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496702373.17253.179.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.183016:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1000_1099,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:40:36 -0000

On 6/5/17 6:39 PM, George wrote:

> If Bash did go the route of using the locale to set the character encoding of a script, I think it would be best to have a mechanism a script can use
> to define the character encoding for the whole script file up front, rather than setting LC_CTYPE to procedurally change the behavior of the shell.

A script can use an assignment to LC_CTYPE (or LC_ALL, or LANG) at the
beginning of a script to "define the character encoding for the whole
script file up front."

Doing this with "source" is a little more problematic, because
fundamentally shell variable names are simply strings of bytes. If you
change the locale between defining a shell variable and referencing it,
possibly multiple times, you're going to have a character set problem.
There are tools like iconv that can help you with that, but that's a
clumsy solution.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:46:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrlu-0000f0-41
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:46:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59438)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrls-0000eu-OL
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:46:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrlp-0008Mq-Lh
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:46:36 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:63801
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKrlp-0008Ml-G1
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:46:33 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN12308; Tue, 13 Jun 2017 15:46:29 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM38947 (AUTH cpr);
	Tue, 13 Jun 2017 15:46:25 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
To: Peter & Kelly Passchier <peterkelly@passchier.net>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net>
	<18501171-7633-752e-1abd-d82a9f247796@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <6b2793c8-f3fe-b700-791b-64491e6fbaf8@case.edu>
Date: Tue, 13 Jun 2017 15:46:25 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <18501171-7633-752e-1abd-d82a9f247796@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1200_1299, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:46:37 -0000

On 6/5/17 8:40 PM, Peter & Kelly Passchier wrote:
> On 06/06/2560 05:39, George wrote:
>> So if you had "Pokémon" as an identifier in a Latin-1-encoded script (byte value 0xE9 between the "k" and "m") and then tried running that script in a
>> UTF-8 locale, that byte sequence (0xE9 0x6D) would actually be invalid in UTF-8, so Eduardo's patch would indicate that the identifier is invalid and
>> fail to run the script.
> 
> I often work with a locale that has a UTF-8 encoding and an
> different/older encoding that are incompatible. I haven't tried the
> patch, but if I use unicode characters in function names, if I write a
> script in one encoding, and run it in an environment in the other
> encoding, it still runs correctly, but it won't render correctly. 

This can lead to subtle failures. If a variable name uses a character that
is an alphanumeric in the writer's locale, but not the default locale
where it's executed, the writer has to set the locale explicitly to avoid
the variable causing a `not a valid identifier' error.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:48:14 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrnS-0000zU-D0
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:48:14 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59701)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrnP-0000yo-Dr
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:48:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrnM-0000NZ-DT
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:48:11 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:37615
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrnM-0000NF-6n
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:48:08 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI05816; Tue, 13 Jun 2017 15:48:03 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM39141 (AUTH cpr);
	Tue, 13 Jun 2017 15:48:03 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>,
	Peter & Kelly Passchier <peterkelly@passchier.net>
Subject: Re: Patch for unicode in varnames...
To: George <tetsujin@scope-eye.net>, L A Walsh <bash@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <68506d9e-9f0d-d742-728e-bc1fa264e0c1@case.edu>
Date: Tue, 13 Jun 2017 15:48:03 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1496734633.17253.275.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.184815:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:48:13 -0000

On 6/6/17 3:37 AM, George wrote:
> that approach only works if you know the
> correct character encoding to use when processing the script. The information has to be provided in the script somehow.

It can be provided in the usual way: by specifying the appropriate locale
via assignments to the right environment variables.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:49:50 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrp0-0001wB-RF
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:49:50 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60155)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKroy-0001uu-IE
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:49:49 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrou-0000lY-9w
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:49:47 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:37839
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKrou-0000lT-43
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:49:44 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI05889; Tue, 13 Jun 2017 15:49:40 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFW37426 (AUTH cpr);
	Tue, 13 Jun 2017 15:49:40 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
To: Peter & Kelly Passchier <peterkelly@passchier.net>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org> <20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org> <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net>
	<2b440105-75dc-5979-8105-b480d48752fd@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <d1081838-1999-68fe-04a8-8535c51607fd@case.edu>
Date: Tue, 13 Jun 2017 15:49:39 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <2b440105-75dc-5979-8105-b480d48752fd@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.184815:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1000_1099, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:49:49 -0000

On 6/6/17 4:08 AM, Peter & Kelly Passchier wrote:
> 
> 
> On 06/06/2560 14:37, George wrote:
>> Broadly speaking I think the approach taken in Eduardo's patch
>> (interpreting the byte sequence according to the rules of its character
>> encoding) is better than the approach taken in current versions of Bash
>> (letting 0x80-0xFF slide through the parser) - but that approach only
>> works if you know the correct character encoding to use when processing
>> the script. The information has to be provided in the script somehow.
> 
> I think only supporting UTF-8 would be the easiest, it allows all glyphs
> to be used. And no extra declaration needs to be added to bash.

"Only supporting UTF-8" doesn't resolve the issue, which is not encoding-
related. And of course there needs to be additional code in bash no
matter what approach is used.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:55:10 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKruA-0004CG-IK
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:55:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60968)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKru8-000451-Jj
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:55:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKru5-0002IA-Ih
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:55:08 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:38696
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKru5-0002Hu-CY
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:55:05 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI06136; Tue, 13 Jun 2017 15:55:01 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM40160 (AUTH cpr);
	Tue, 13 Jun 2017 15:55:00 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Patch for unicode in varnames...
To: PePa <peterkelly@passchier.net>, bug-bash <bug-bash@gnu.org>
References: <1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian> <593455D1.9050706@tlinx.org>
	<1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net> <5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org>
	<66e75c6a-4c20-d86e-5574-ebc2c8be0fa8@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <1d5bb16b-c244-24b1-303e-1a6cd654d672@case.edu>
Date: Tue, 13 Jun 2017 15:55:00 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <66e75c6a-4c20-d86e-5574-ebc2c8be0fa8@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.13.184815:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:55:09 -0000

On 6/6/17 10:40 AM, PePa wrote:
> On 06/06/2560 21:20, Greg Wooledge wrote:
>> Scripts that can only *run* in a UTF-8 encoding-locale are a bad idea.
> 
> Even currently, when functions in a bash script are beyond ASCII, they
> can still be run anywhere. I would imagine it would be the same when
> variable names are also allowed to be in some unicode encoding.

No. We're not talking about a free-for-all like function names, which are
essentially uninterpreted byte streams, but using alphanumerics from the
current locale as an extension to the Posix portable character set.  In
this case, the encoding doesn't matter -- it's how the character properties
are assigned in the character set.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 15:57:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKrwt-0005gC-3X
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 15:57:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33335)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrwq-0005g6-RC
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:57:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrwl-0003aM-MF
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:57:56 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:10035
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKrwl-0003ZX-H3
	for bug-bash@gnu.org; Tue, 13 Jun 2017 15:57:51 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH89293; Tue, 13 Jun 2017 15:57:46 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFW38859 (AUTH cpr);
	Tue, 13 Jun 2017 15:57:46 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
To: L A Walsh <bash@tlinx.org>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org> <1496652739.17253.82.camel@scope-eye.net>
	<5fcb172a-f3d4-6698-6933-117cdf4a8e77@passchier.net>
	<1496702373.17253.179.camel@scope-eye.net> <5935E659.9040308@tlinx.org>
	<1496734633.17253.275.camel@scope-eye.net> <5936B5B3.3000006@tlinx.org>
	<20170606142003.GF3691@eeg.ccf.org> <5936FC51.9060204@tlinx.org>
	<20170606191223.GL3691@eeg.ccf.org> <59370BB0.8020008@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <f00e741e-7807-d5f2-b016-ee30cfaf47cc@case.edu>
Date: Tue, 13 Jun 2017 15:57:46 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <59370BB0.8020008@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 19:57:57 -0000

On 6/6/17 4:08 PM, L A Walsh wrote:

>    Thanks for the history lesson (for those of us who were too lazy to
> goog it ;-)).
> Still, on what OS has it shown the most growth or popularity?

The entire set of Linux machines is up there, but Mac OS X (and its
descendents like iOS and tvOS) has many millions of users.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 16:02:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKs1A-0007GZ-FF
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 16:02:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34406)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKs16-0007FR-Vg
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:02:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKs12-0004wG-6v
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:02:21 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:10657
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKs12-0004wA-1a
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:02:16 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH89466; Tue, 13 Jun 2017 16:02:13 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM41423 (AUTH cpr);
	Tue, 13 Jun 2017 16:02:12 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<69cd1147-3b26-6436-c211-1156e464e647@case.edu>
	<59402F2B.7090103@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <2028f8ff-0945-972a-bf90-a84b856bdf69@case.edu>
Date: Tue, 13 Jun 2017 16:02:12 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <59402F2B.7090103@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.190915:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __C230066_P5,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1600_1699,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 20:02:23 -0000

On 6/13/17 2:30 PM, L A Walsh wrote:
> 
> 
> Chet Ramey wrote:
>> On 6/1/17 8:42 PM, L A Walsh wrote:
>>  
>>> It would be a useful upgrade besides being a "good world citizen" ;-).
>>>     
>>
>> The only way this makes sense is to extend the allowable set of
>> characters from the portable character set to the current locale.
>>
>>  
>>> I'm guessing that if POSIX was set, then they'd be limited
>>> to the ASCII (American Standard Code for Information Interchange)
>>> set.  ;^)
>>>     
>>
>> Not quite; it's a subset of characters from the Portable Character Set.
>> That's the set of characters that Posix requires to be present in all
>> locales supported by Posix systems.
>>
>> http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_235
>>
>>   
> Aren't all of those characters in ASCII?  I.e. wouldn't
> ASCII be a limiting set?  It may not be the minimal set, since
> many characters in ASCII aren't usable in varnames, but I
> thought the allowed chars in vars were some set <= ASCII?

This is correct.  The portable character set is a subset of ASCII.

> 
> It seems like it would be a greater support burden to
> allow one set for functions while restricting the allowed
> characters for variables to some smaller set, no?

No, of course not.  The code has to exist, and it exists, to support Posix
standard identifiers. It's a greater support burden to add locale-specific
code to what already is there.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 16:30:36 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKsSS-0006Qg-22
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 16:30:36 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40747)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKsSP-0006MZ-NH
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:30:34 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKsSI-0004q2-7i
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:30:29 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:6657
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKsSI-0004pq-1y
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:30:26 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN14683; Tue, 13 Jun 2017 16:30:23 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM46568 (AUTH cpr);
	Tue, 13 Jun 2017 16:30:23 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: heap-buffer-overflow
	_rl_find_prev_mbchar_internal / expand_prompt
To: Eduardo Bustamante <dualbus@gmail.com>, bug-bash@gnu.org
References: <20170613151431.ka6rw6tnjaavtyco@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
Date: Tue, 13 Jun 2017 16:30:23 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170613151431.ka6rw6tnjaavtyco@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.13.200916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_400_499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	SINGLE_URI_IN_BODY, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 20:30:34 -0000

On 6/13/17 11:14 AM, Eduardo Bustamante wrote:
> It seems like this is another case of strlen reading too much.

I can't reproduce it with asan or without on Mac OS X. I'll look around
for a Linux system with asan to run it on.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 16:44:20 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKsfk-0001NO-5k
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 16:44:20 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44534)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKsfi-0001Lt-7U
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:44:19 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKsff-0001P7-2J
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:44:18 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:59217
	helo=homiemail-a68.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dKsfe-0001No-MD
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:44:14 -0400
Received: from homiemail-a68.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a68.g.dreamhost.com (Postfix) with ESMTP id 1041448004086; 
	Tue, 13 Jun 2017 13:44:09 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=KhfiyAmL7o8VC0XWWpp10/hrQHU=; b=
	a891EYhC+cEbBCWcbvnS//aTqzCPaXHcboPVT7HLPVKHTCZtzAOVk29yqUBQnOdB
	qnvAlB6JQxhT/yZxYxK1MytcXGWTKR16m0gyREKCKgzCWOGVCV/emp/uw9DA7FVO
	OmTZ2gbQuK9MlXx0VfyIeC45L/7tCfVhJWfemenhud4=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a68.g.dreamhost.com (Postfix) with ESMTPSA id
	E8AA948004083; Tue, 13 Jun 2017 13:44:08 -0700 (PDT)
Message-Id: <829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu, tetsujin@scope-eye.net, "dualbus" <dualbus@gmail.com>,
	"L A Walsh" <bash@tlinx.org>
Cc: chet.ramey@case.edu,
 "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <9ebad712-87bc-3dcf-82a2-0415a3ef0146@case.edu>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Date: Tue, 13 Jun 2017 16:44:08 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 20:44:19 -0000

=0A=0APlease excuse the top-posting, this mail client isn't very good...=
=0A=0ATo some extent, tying the shell script language to the locale is=
=0Aunavoidable. However, one of the points I was trying to make is that,=
=0Ain principle, at least, this shouldn't be the case. If a script is=0A=
written in a particular character encoding (and uses characters from=0At=
hat encoding in its function names or parameter names, for instance)=0Ai=
t should still run correctly even if it's run in a different locale,=0Aj=
ust as a compiled program should be able to run in a locale other=0Athan=
 the one in which its source code was authored.=0A=0AFor that to work, b=
asically the character encoding used to interpret=0Athe script should be=
 (potentially) distinct from the one used to=0Ainteract with the rest of=
 the system.=0A=0A...But that gets complicated: the shell would need to=
 interpret the=0Ascript in its locale of origin, but still respect the l=
ocale for other=0Amatters of I/O. But since data in the shell intermingl=
es with=0Aprogramming constructs in the shell (Variables get passed by n=
ame,=0Acommand and function names get stored in (and invoked from) shell=
=0Avariables, variable values and "here" docs come from the script, etc.=
)=0Ait gets into questions like, do we have to track character encoding=
=0Afor each variable in the script? When do we transcode between=0Aencod=
ings? And what happens when a transcoding isn't possible?=0A=0ASo maybe=
 the whole thing is just reaching too far... But that's how=0AI'd want t=
o approach it: I'd want people to be able to use their=0Acharacter set i=
n their scripts, but I'd want it to work in a way that=0Aa script, once=
 written, can work regardless of the active locale.=0A=0A----- Original=
 Message -----=0AFrom: chet.ramey@case.edu=0ATo:<tetsujin@scope-eye.net>=
, "dualbus" <dualbus@gmail.com>, "L A=0AWalsh" <bash@tlinx.org>=0ACc:<ch=
et.ramey@case.edu>, "bug-bash" <bug-bash@gnu.org>=0ASent:Tue, 13 Jun 201=
7 15:04:24 -0400=0ASubject:Re: RFE: Please allow unicode ID chars in ide=
ntifiers=0A=0A On 6/2/17 12:54 PM, tetsujin@scope-eye.net wrote:=0A=0A >=
 - As you pointed out, this requires the shell to somehow establish=0Aa=
=0A > convention governing the character set used to interpret shell=0As=
cripts=0A=0A It's actually the same one that is currently used: the curr=
ent=0Alocale.=0A=0A > =0A > But, on the other hand:=0A > - Even if your=
 editor or terminal can't display the UTF-8 code,=0Athat=0A > doesn't me=
an the shell process can't RUN it.=0A=0A As long as the locale is set ap=
propriately.=0A=0A> 2: For a script, the character encoding of commands=
 must be=0Aexplicitly=0A > specified, probably via a shell option. =0A=
=0A You can already do this by setting the various locale environment=0A=
 variables.=0A=0A

From MAILER-DAEMON Tue Jun 13 16:52:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKsnp-0003ML-4S
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 16:52:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46481)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKsnm-0003Lu-FX
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:52:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKsnj-0003oq-Dd
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:52:38 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:9450
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKsnj-0003o4-7o
	for bug-bash@gnu.org; Tue, 13 Jun 2017 16:52:35 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN15567; Tue, 13 Jun 2017 16:52:30 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFM50201 (AUTH cpr);
	Tue, 13 Jun 2017 16:52:30 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: Trailing newlines disappear
To: Peter & Kelly Passchier <peterkelly@passchier.net>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<d3c28d1d-4245-4597-bbdf-f50a53184dca@case.edu>
	<d9b0b7e9-1aaa-b80b-e167-9587c68a82d7@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <88028197-5c95-c784-9c5e-018c530d643b@case.edu>
Date: Tue, 13 Jun 2017 16:52:30 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <d9b0b7e9-1aaa-b80b-e167-9587c68a82d7@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.200916:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_800_899, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 20:52:39 -0000

On 6/12/17 8:55 PM, Peter & Kelly Passchier wrote:
> On 13/06/2560 02:54, Chet Ramey wrote:
>> If you want to effectively change it to a newline, specify NUL as the
>> line delimiter using the -d option (new in bash-4.4).
> 
> Thanks, that sounds like a clean solution!
> I only reverted to mapfile because $(...) command substitution could not
> be made to work. (I still have to 'convert' the array to a normal
> variable in the next step...). Would a shell option for command
> substitution using NUL be a desirable feature to bash users??

You mean command substitution cutting off the input it reads at the
occurrence of a NUL?

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 17:00:20 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKsvE-0006QP-5V
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:20 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47960)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKsvB-0006Pd-ME
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:19 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKsv6-0006Mq-PX
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:17 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:36015 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dKsv6-0006Le-I6
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:12 -0400
Received: (qmail 4860 invoked from network); 13 Jun 2017 21:00:10 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Tue, 13 Jun 2017 17:00:10 -0400
Received: (qmail 22414 invoked by uid 563); 13 Jun 2017 21:00:10 -0000
Date: Tue, 13 Jun 2017 17:00:10 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: tetsujin@scope-eye.net
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170613210010.GD3691@eeg.ccf.org>
References: <9ebad712-87bc-3dcf-82a2-0415a3ef0146@case.edu>
	<829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 21:00:19 -0000

On Tue, Jun 13, 2017 at 04:44:08PM -0400, tetsujin@scope-eye.net wrote:
> For that to work, basically the character encoding used to interpret
> the script should be (potentially) distinct from the one used to
> interact with the rest of the system.
> 
> ...But that gets complicated: the shell would need to interpret the
> script in its locale of origin, but still respect the locale for other
> matters of I/O. [...]

The main issue here is that the author's locale may not *exist* on the
user's machine.  There may not be any way for bash to determine which
non-ASCII characters constitute "letters" in the author's locale.


From MAILER-DAEMON Tue Jun 13 17:01:01 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKsvt-0006iZ-Bz
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 17:01:01 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49288)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKsvr-0006iG-4X
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:59 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dKsvq-0006wN-82
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:59 -0400
Received: from mail-qk0-x235.google.com ([2607:f8b0:400d:c09::235]:35421)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dKsvq-0006wG-3A
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:00:58 -0400
Received: by mail-qk0-x235.google.com with SMTP id a199so21257770qkb.2
	for <bug-bash@gnu.org>; Tue, 13 Jun 2017 14:00:57 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=4njISDw8BQYQ3Iva3rjXhjbdiuhVPu4Vs4H8bqL2egg=;
	b=RJaG9mTWNPXxMfMhVwPzWTIimKnTNpmyT1SgScKQkJ7HGNEa1QLg6cQg+xizGwQEiK
	Mx3qjS7V90Vc4dH+rgqOXbYMgytezHBM9ANfvt+abb81nW3toEg7z80K1yqPiMBPoMuD
	koz3S02Sgn3ICDMxv3RBjExLAE+/8SpJtz6srnPJY1ZQFgWJSjCmRYO75+J9JdNA/Vbg
	imf27bWH1K4VlSjwrVbxbDWPl5YHkbejCrMHTQ1Rc9UMQzeOGzGsCDn/jR8dRS9s/Vwf
	7A8bQ/UDmnhqNLXSPNeXOWHbfMtWFPXAPAWxPC771ru5yhrBXh3jj+AaXaaoA4scaFEt
	3pow==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=4njISDw8BQYQ3Iva3rjXhjbdiuhVPu4Vs4H8bqL2egg=;
	b=HcnPDk+eagGwuyVMeQspfRcODV//40lNtzLGFHKhQSIuKsKx7CtOxpO/U690K3C4Wi
	UNLSZc5Ph4oMHzDxgx4y9Aia+GUclTTD9gbgO3KJMrG1yD+VA3zMAI0XBqFC7bGWAo3W
	Y/KTLWBSKFDtooQ4Ljb6IsyIToY4/ROWfPjEc42qGjKHweTVWBzAFRyje7USfee4kX40
	6wSbyStl29Bad5eXyWAUWZQxD+Xg2vAubYog08Gslwrsc9QWw6aDY8W5AojzsZti9uW4
	csJOLsjUKEq95V7sYYl2JQHjHnnaSUuLUOHcjnWngu2R0m8VNtlQfEqoJW9qVnWfe6oF
	HbFA==
X-Gm-Message-State: AKS2vOzZuqZiK5vBxC59KlQg670Eo0C5ckXu80uteccRqvyD5RdfMo5M
	Xxr/ynQmtLrhRhvqWNwc8nsUOuxo+w==
X-Received: by 10.55.215.130 with SMTP id t2mr2463355qkt.188.1497387656387;
	Tue, 13 Jun 2017 14:00:56 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Tue, 13 Jun 2017 14:00:36 -0700 (PDT)
In-Reply-To: <ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
References: <20170613151431.ka6rw6tnjaavtyco@debian>
	<ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Tue, 13 Jun 2017 16:00:36 -0500
Message-ID: <CAOSMAuthpF9L8GNXHMyv9-KXO5hwJGLcGZ9Qkmp82Khcd5h_OQ@mail.gmail.com>
Subject: Re: AddressSanitizer: heap-buffer-overflow
	_rl_find_prev_mbchar_internal / expand_prompt
To: Chet Ramey <chet.ramey@case.edu>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 21:01:00 -0000

On Tue, Jun 13, 2017 at 3:30 PM, Chet Ramey <chet.ramey@case.edu> wrote:
[...]
> I can't reproduce it with asan or without on Mac OS X. I'll look around
> for a Linux system with asan to run it on.

I had to use these exact same environment variables, otherwise the out
of bounds read wouldn't happen. I'm not sure if it might depend on the
terminal size or another variable that might make this hard to
reproduce.

I'll try with a few more crashing inputs to see if I can find a better
test case. I should probably also start writing down my locale, glibc
version, TERM, compiler flags and other variables that might help in
the reproduction.


From MAILER-DAEMON Tue Jun 13 17:04:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKszR-00085y-1I
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 17:04:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50065)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKszO-00085r-Tt
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:04:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKszK-0007xB-B5
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:04:38 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:39706
	helo=homiemail-a122.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dKszJ-0007vT-VH
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:04:34 -0400
Received: from homiemail-a122.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a122.g.dreamhost.com (Postfix) with ESMTP id 02B7960001117;
	Tue, 13 Jun 2017 14:04:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=i9i8O8E/jHFIVbjLTRQZg7W1Yvk=; b=
	capVNL+Rk7l1Ke8e6IcIS9rABA7+RTxiBwrnc0Ienp+2wPi8f+3zCjH9JUVL6Vfm
	nSa5rK9aZ9IE6vsS4ye5SdxH8sau6bqoFuib9lOgTEmMKXMmkgb3OlZaLy4DTl3T
	4vltq3mfVTfSDUgY5p5ZsOXBVp5O/ZUW4lzZkynwaDs=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a122.g.dreamhost.com (Postfix) with ESMTPSA id
	DC93860001116; Tue, 13 Jun 2017 14:04:30 -0700 (PDT)
Message-Id: <470e34d72bfb5ec78def6f4e1b14dd7dd2152379@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu,
 "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <8e1b848a-2649-0dd0-001c-4599f04fd384@case.edu>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Date: Tue, 13 Jun 2017 17:04:30 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 21:04:40 -0000

=0AWell, my own reports have been to the mailing list (and just over the=
=0Alast year) - to be fair, while I haven't necessarily gotten the=0Aans=
wers I wanted to hear, I did get answers. :)=0A=0AThe "Support" and "Pat=
ches" pages on Savannah seem a bit neglected,=0Ahowever. Items from 2011=
-2015 with no status and no responses. That's=0Amainly what I was referr=
ing to.=0A=0A----- Original Message -----=0AFrom: chet.ramey@case.edu=0A=
To:"George" <tetsujin@scope-eye.net>, "L A Walsh" <bash@tlinx.org>,=0A"b=
ug-bash" <bug-bash@gnu.org>=0ACc:"dualbus" <dualbus@gmail.com>, <chet.ra=
mey@case.edu>=0ASent:Tue, 13 Jun 2017 15:23:58 -0400=0ASubject:Re: RFE:=
 Please allow unicode ID chars in identifiers=0A=0A On 6/3/17 2:00 PM, G=
eorge wrote:=0A=0A > As it is, Bash bug reports and=0A > feature request=
s are neglected for years on end, =0A=0A If you have a bug report that's=
 been neglected for that long, let me=0Aknow.=0A=0A -- =0A ``The lyf so=
 short, the craft so long to lerne.'' - Chaucer=0A ``Ars longa, vita bre=
vis'' - Hippocrates=0A Chet Ramey, UTech, CWRU chet@case.edu=0Ahttp://cn=
swww.cns.cwru.edu/~chet/=0A=0A

From MAILER-DAEMON Tue Jun 13 17:19:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKtE4-0005Sy-80
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 17:19:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53162)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKtE1-0005ST-NB
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:19:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKtDy-0003or-J0
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:19:45 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:41735
	helo=homiemail-a50.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dKtDy-0003o1-6p
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:19:42 -0400
Received: from homiemail-a50.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a50.g.dreamhost.com (Postfix) with ESMTP id BD6CE801E434; 
	Tue, 13 Jun 2017 14:19:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=k5yQ4TgADtqLER+vIOXujiBtdqg=; b=
	fOR3if4pYOUFYw+p7G+oxcpjKvoXGKWWBaqOdOBNRZ6ZaS+hqsU9c7EWhv5iR4d6
	kLRf0H0ZngItucL/bThbMCYEQM+sxLg1HdzoCU5GiwEXBhGy3X/DK6Cyjd0xLkM6
	ZPsQ7azT+Mh8g2K+E0Y/bDNwWWaNGBV8QpS5PiVjo0M=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a50.g.dreamhost.com (Postfix) with ESMTPSA id AAE9B801E433;
	Tue, 13 Jun 2017 14:19:40 -0700 (PDT)
Message-Id: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Greg Wooledge" <wooledg@eeg.ccf.org>,
 tetsujin@scope-eye.net
Cc: "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <20170613210010.GD3691@eeg.ccf.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Date: Tue, 13 Jun 2017 17:19:40 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 21:19:47 -0000

=0AIn that case, the answer is simple:=0A=0AThe shell swiftly rejects th=
e script, and provides a clear reason why=0Ait cannot be run. ("bash: Sc=
ript requires the en_US.utf8 locale which=0Ais not installed on this sys=
tem. Sorry, dude.")=0A=0AThis, in my opinion, is certainly preferable ov=
er the current=0Asituation, in which the script runs, and=0A- MAYBE fail=
s at an UNKNOWN time with an unhelpful message like "bash:=0A$'351211204=
344272272': command not found"=0A- MAYBE fails in a more subtle, unfores=
een way (i.e. word-splitting=0Athe middle of a command name or identifie=
r, then running the wrong=0Acommand with a garbage argument)=0A=0AThis i=
s also why I think this should be an optional "encoding marker"=0Aat a f=
airly fixed location in the file, rather than an option setting=0Athat c=
ould occur anywhere in the script: It allows an incompatible=0Ascript to=
 be immediately identified and rejected before it does=0Aanything.=0A=0A=
----- Original Message -----=0AFrom: "Greg Wooledge" <wooledg@eeg.ccf.or=
g>=0ATo:<tetsujin@scope-eye.net>=0ACc:"bug-bash" <bug-bash@gnu.org>=0ASe=
nt:Tue, 13 Jun 2017 17:00:10 -0400=0ASubject:Re: RFE: Please allow unico=
de ID chars in identifiers=0A=0A On Tue, Jun 13, 2017 at 04:44:08PM -040=
0, tetsujin@scope-eye.net=0Awrote:=0A > For that to work, basically the=
 character encoding used to=0Ainterpret=0A > the script should be (poten=
tially) distinct from the one used to=0A > interact with the rest of the=
 system.=0A > =0A > ...But that gets complicated: the shell would need t=
o interpret the=0A > script in its locale of origin, but still respect t=
he locale for=0Aother=0A > matters of I/O. [...]=0A=0A The main issue he=
re is that the author's locale may not *exist* on=0Athe=0A user's machin=
e. There may not be any way for bash to determine which=0A non-ASCII cha=
racters constitute "letters" in the author's locale.=0A

From MAILER-DAEMON Tue Jun 13 17:55:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKtms-0002dB-T9
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 17:55:46 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59658)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKtmp-0002bM-P7
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:55:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKtmm-0006GE-MR
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:55:43 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:37119
	helo=homiemail-a83.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dKtmm-0006Fy-Ck
	for bug-bash@gnu.org; Tue, 13 Jun 2017 17:55:40 -0400
Received: from homiemail-a83.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a83.g.dreamhost.com (Postfix) with ESMTP id 5F5F48018C37; 
	Tue, 13 Jun 2017 14:55:36 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=Nb91YPQP/6IXjZgnPVXf8sK/62Y=; b=
	BEoisjt2aMqtcUxeZAIXbYSRyXKT2xrJdlf9iKZbaDkWBZ2LclZZcLQYxBII7+cM
	yJ9jtJvtxFlpn4HR38dAG7TPyR5BI7BWP8qkS8jXKsa0bsZhTwM74bJM4MIuSYu9
	GRK5EsZryuChzTEKkA7ylHj+iFgWMTztHUu6Nqytq8k=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a83.g.dreamhost.com (Postfix) with ESMTPSA id 4D31C8018C2D;
	Tue, 13 Jun 2017 14:55:36 -0700 (PDT)
Message-Id: <873a0a6fdff48f7f618f95f481a3de3bbd527830@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu
Cc: "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <f00e741e-7807-d5f2-b016-ee30cfaf47cc@case.edu>
Subject: Re: Patch for unicode in varnames...
Date: Tue, 13 Jun 2017 17:55:36 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 21:55:44 -0000

=0A...Though Apple now sticks to Bash 3.2 to avoid GPL v3 right? Makes=
=0A'em kind of an odd use-case, and maybe a bit irrelevant with respect=
=0Ato the future direction of Bash.=0A=0A----- Original Message -----=0A=
From: chet.ramey@case.edu=0ATo:"L A Walsh" <bash@tlinx.org>, "Greg Woole=
dge" <wooledg@eeg.ccf.org>=0ACc:"bug-bash" <bug-bash@gnu.org>, <chet.ram=
ey@case.edu>=0ASent:Tue, 13 Jun 2017 15:57:46 -0400=0ASubject:Re: Patch=
 for unicode in varnames...=0A=0A On 6/6/17 4:08 PM, L A Walsh wrote:=0A=
=0A > Thanks for the history lesson (for those of us who were too lazy t=
o=0A > goog it ;-)).=0A > Still, on what OS has it shown the most growth=
 or popularity?=0A=0A The entire set of Linux machines is up there, but=
 Mac OS X (and its=0A descendents like iOS and tvOS) has many millions o=
f users.=0A

From MAILER-DAEMON Tue Jun 13 19:59:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKviV-0005OR-9k
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51337)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKviS-0005OK-LS
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKviN-0007Bb-OR
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:20 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:42228
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKviN-0007At-Fc
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:15 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5DNwxpo003385; Tue, 13 Jun 2017 16:59:01 -0700
Message-ID: <59407C43.8010503@tlinx.org>
Date: Tue, 13 Jun 2017 16:58:59 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
In-Reply-To: <da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 23:59:22 -0000



Chet Ramey wrote:
> On 6/2/17 6:23 PM, L A Walsh wrote:
>
>   
>> As for unsupported systems, there is a reason they are no longer
>> supported.  The world is already using UTF-8.  It's only a few
>> luddites clinging to ascii as a last refuge. ;-)
>>
>> What display/OS do you have that you can't run UTF-8 on?
>>     
>
> This is a red herring. de_DE.UTF-8 and zh_KH.UTF-8 don't use the same
> character set.
>   
---
    The use the same encoding.  Whether or not they use
the same character set is up to someone's preference.  Looking at my
local fonts, it looks like 'Code2000' covers both of those ranges:
Germany and Khmer ?  But using 1 font for both isn't necessary.

    Even MS allows for different character sets
to be used for different parts of unicode.  Linux also has this
with its current font support.  So it's not that critical whether or
not different ranges need different character sets.  If someone
*wants* to display characters in a different language, they can
get fonts that support them.  They aren't that hard to find online
(goog).

If you want to check if you have coverage for a range online, you can
visit http://www.babelstone.co.uk/Unicode/babelmap.html

If you have a windows machine, you can run the local application from
http://www.babelstone.co.uk/Software/BabelMap.html
It will tell you what ranges you have fonts for and what percent
coverage you have.  Example:

With Unicode 8.0 (1 version behind current), I have
203 out of 256 blocks with full coverage,
with 112,637 out of 120,737 characters (93.3%).

(oh poo, just loaded 9.0)...
only 200 out of 267 blocks w/full coverage and
only 112,676 out of 128,172 (87.9%) of the chars. 

Just goes to show how you get more behind just sitting still.  ;-)



But if I want to write a script for public consumption, I'd
likely use a common subset of characters.

Forgive me if I'm misremembering, but hasn't Greg argued against
the ability to supply "libraries" of re-usable scripts due to
the ease with which names could conflict with each other and cause
script incompatibilities?

So how much are script libraries widely used across sites now?

If it is the case that script libraries had access to unicode
var & func names (and used it), wouldn't that significantly
decrease the the chances of conflict?  Right now, what, ...
maybe A-Za-z_0-9 + maybe a few others == that's about 64 chars?

If even half the unicode letters were alphabetic / classified as ID
type chars, wouldn't that add over 60K new possibilities?

Even if a character doesn't display in your locality, doesn't
mean it wouldn't work -- i.e. if I don't have a Cryllic font
installed, that doesn't mean the script wouldn't work -- as
the characters would still be encoded as their Unicode values.


Please note -- the subject -- it doesn't say allow any
locality in scripts -- but unicode.  More to the point, I'd
only suggest UTF-8 encoding.  That means all of todays scripts
would run "as is", (as the bottom 127 chars of unicode are
identical to ASCII).  It also solves issues of what encoding
is used.  If it's non-ASCII, it could (or would) default to UTF-8.








From MAILER-DAEMON Tue Jun 13 19:59:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvil-0005WA-DD
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51374)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvig-0005U5-Sa
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:36 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvic-0007Cl-1G
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:34 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:29249
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvib-0007Cf-QU
	for bug-bash@gnu.org; Tue, 13 Jun 2017 19:59:29 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN20764; Tue, 13 Jun 2017 19:59:24 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPP05929 (AUTH cpr);
	Tue, 13 Jun 2017 19:59:23 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: tetsujin@scope-eye.net, dualbus <dualbus@gmail.com>,
	L A Walsh <bash@tlinx.org>
References: <829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <d6119550-db2a-f386-5b43-5a3144e900ba@case.edu>
Date: Tue, 13 Jun 2017 19:59:22 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.225416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_2000_2999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jun 2017 23:59:36 -0000

On 6/13/17 4:44 PM, tetsujin@scope-eye.net wrote:
> 
> 
> Please excuse the top-posting, this mail client isn't very good...
> 
> To some extent, tying the shell script language to the locale is
> unavoidable. However, one of the points I was trying to make is that, in
> principle, at least, this shouldn't be the case. If a script is written in
> a particular character encoding (and uses characters from that encoding in
> its function names or parameter names, for instance) it should still run
> correctly even if it's run in a different locale, just as a compiled
> program should be able to run in a locale other than the one in which its
> source code was authored.

This isn't a good comparison. Even a compiled program that calls one of
the ctype.h functions is dependent on the locale in which it's run.  A
script, since it's text and interpreted, has the same dependency, to an
even greater extent.  If C source code contains character strings that are
encoded in the author's locale, you're going to get indeterminate results
if you try to display them in an environment using a different locale.

You can mitigate this somewhat by using the mechanisms available to
control the locale: for a C program it's setlocale(), and for a script
it's the LC_ and LANG variables.


> For that to work, basically the character encoding used to interpret the
> script should be (potentially) distinct from the one used to interact with
> the rest of the system.

What "rest of the system"? What "matters of I/O"?

> 
> ...But that gets complicated: the shell would need to interpret the script
> in its locale of origin, but still respect the locale for other matters of
> I/O. But since data in the shell intermingles with programming constructs
> in the shell (Variables get passed by name, command and function names get
> stored in (and invoked from) shell variables, variable values and "here"
> docs come from the script, etc.) it gets into questions like, do we have to
> track character encoding for each variable in the script? When do we
> transcode between encodings? And what happens when a transcoding isn't
> possible?
> 
> So maybe the whole thing is just reaching too far... But that's how I'd
> want to approach it: I'd want people to be able to use their character set
> in their scripts, but I'd want it to work in a way that a script, once
> written, can work regardless of the active locale.

I assume that by this you mean the user's locale. You can still force a
different one.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:06:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvpQ-0007aN-8O
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:06:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52374)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKvpM-0007ZS-D8
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:06:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKvpH-0000ne-Uv
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:06:28 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:42516
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKvpH-0000n2-G8
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:06:23 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5E06GId004235; Tue, 13 Jun 2017 17:06:18 -0700
Message-ID: <59407DF8.1080209@tlinx.org>
Date: Tue, 13 Jun 2017 17:06:16 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: tetsujin@scope-eye.net
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
In-Reply-To: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:06:31 -0000

tetsujin@scope-eye.net wrote:
> This is also why I think this should be an optional "encoding marker"
>   
---
    Why?  If it was the current encoding, it wouldn't have high-bits
set.  If it had any high bits set, it's fairly simple to
either presume or validate the script as UTF-8, as it is
self-synchronizing.

    Please note, the RFE was for UTF-8.  That's 1 encoding.
I'm not proposing, suggesting nor wanting a general "locale"
support for arbitrary encodings in bash.  That would be
entirely chaotic and its own "Tower of Babel" incident on
its own.  This suggestion was to allow 1 global/extra character
encoding: UTF-8. 

Regarding what Greg said:
> From: "Greg Wooledge" <wooledg@eeg.ccf.org>
>  The main issue here is that the author's locale may not *exist* on
> the
>  user's machine. There may not be any way for bash to determine which
>  non-ASCII characters constitute "letters" in the author's locale.
>   
---
    If we use UTF-8, that won't be an issue.  It's an internationalized
encoding that can support all languages and locales.  If a script
uses high-bit encoding(s), it can automatically be assumed to be UTF-8.

    In a related way, the program "file" already is able to tell
you what encoding a file is in.







From MAILER-DAEMON Tue Jun 13 20:10:26 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvtC-0008Iw-Oc
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:10:26 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52886)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvtA-0008If-23
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:10:25 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvt5-00022O-3A
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:10:24 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:3579
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKvt4-00022G-TM
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:10:19 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI13924; Tue, 13 Jun 2017 20:06:53 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPC39491 (AUTH cpr);
	Tue, 13 Jun 2017 20:06:51 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: Greg Wooledge <wooledg@eeg.ccf.org>, tetsujin@scope-eye.net
References: <9ebad712-87bc-3dcf-82a2-0415a3ef0146@case.edu>
	<829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
	<20170613210010.GD3691@eeg.ccf.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <cfd45e31-e1d7-06e5-e7a2-cb0bbf760213@case.edu>
Date: Tue, 13 Jun 2017 20:06:50 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170613210010.GD3691@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.235416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __STOCK_PHRASE_7,
	__OEM_PRICE, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1400_1499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS,
	__SXL_FUR_ERROR_SERVFAIL[242.103.22.129.fur.jap2.sophosxl.com],
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:10:25 -0000

On 6/13/17 5:00 PM, Greg Wooledge wrote:
> On Tue, Jun 13, 2017 at 04:44:08PM -0400, tetsujin@scope-eye.net wrote:
>> For that to work, basically the character encoding used to interpret
>> the script should be (potentially) distinct from the one used to
>> interact with the rest of the system.
>>
>> ...But that gets complicated: the shell would need to interpret the
>> script in its locale of origin, but still respect the locale for other
>> matters of I/O. [...]
> 
> The main issue here is that the author's locale may not *exist* on the
> user's machine.  There may not be any way for bash to determine which
> non-ASCII characters constitute "letters" in the author's locale.

That's quite true. If that's important to the author, he can use a shell
function like this to ensure that the script can set the locale
appropriately.

cklocale()
{
        local lc_ctype=$(locale | grep ^LC_CTYPE=)
        eval local ct=${lc_ctype#*=}

        case $ct in
        $1)     return 0 ;;
        *)      return 1 ;;
        esac
}

That works with Mac OS X, where the output of locale(1) is a series of
shell assignment statements with quoted values; your mileage may vary, of
course.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:13:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvvn-0000BP-J4
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:13:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53122)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvvl-0000BF-Ot
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:13:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvvi-0002LJ-K3
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:13:05 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:59846
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKvvi-0002LF-Ew
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:13:02 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMD18007; Tue, 13 Jun 2017 20:12:40 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPC46980 (AUTH cpr);
	Tue, 13 Jun 2017 20:12:39 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: tetsujin@scope-eye.net, bug-bash <bug-bash@gnu.org>
References: <470e34d72bfb5ec78def6f4e1b14dd7dd2152379@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <1674b3b6-2016-1240-726a-c6fa76ef71bf@case.edu>
Date: Tue, 13 Jun 2017 20:12:39 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <470e34d72bfb5ec78def6f4e1b14dd7dd2152379@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.13.233316:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_900_999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS,
	__SINGLE_URI_TEXT, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:13:06 -0000

On 6/13/17 5:04 PM, tetsujin@scope-eye.net wrote:
> 
> Well, my own reports have been to the mailing list (and just over the last
> year) - to be fair, while I haven't necessarily gotten the answers I wanted
> to hear, I did get answers. :)
> 
> The "Support" and "Patches" pages on Savannah seem a bit neglected,
> however. Items from 2011-2015 with no status and no responses. That's
> mainly what I was referring to.

They're all marked as either "Done", "Invalid", "Won't Do", or similar.
The ones that aren't discussed on bug-bash, and aren't marked marked as
"Done" generally get a short comment explaining why.

I've said many times that I prefer to get bug reports on this mailing list.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:15:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvxt-0000h0-TW
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:15:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53293)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvxr-0000gI-9T
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:15:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvxo-0002bm-52
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:15:15 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:30282
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKvxn-0002bX-Vd
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:15:12 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN21021; Tue, 13 Jun 2017 20:14:53 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPC47883 (AUTH cpr);
	Tue, 13 Jun 2017 20:14:53 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: tetsujin@scope-eye.net, Greg Wooledge <wooledg@eeg.ccf.org>
References: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <9f6fba01-4b23-8b75-b887-735fce2a18d3@case.edu>
Date: Tue, 13 Jun 2017 20:14:52 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.225416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1000_1099,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:15:16 -0000

On 6/13/17 5:19 PM, tetsujin@scope-eye.net wrote:
> 
> In that case, the answer is simple:
> 
> The shell swiftly rejects the script, and provides a clear reason why
> it cannot be run. ("bash: Script requires the en_US.utf8 locale which
> is not installed on this system. Sorry, dude.")

The shell has no business doing this. If a script requires a certain
locale, and won't run correctly without it, the author can ensure that
an assignment to LC_CTYPE produces the desired results.

> This is also why I think this should be an optional "encoding marker"
> at a fairly fixed location in the file, rather than an option setting
> that could occur anywhere in the script: It allows an incompatible
> script to be immediately identified and rejected before it does
> anything.

This is relatively trivial to do with a shell function.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:17:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKvzi-00018U-Jp
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:17:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53515)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvzf-00016a-8o
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:17:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKvzc-0002q8-4r
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:17:07 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:40786
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKvzb-0002pq-Ut
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:17:04 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH97533; Tue, 13 Jun 2017 20:17:01 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPC49347 (AUTH cpr);
	Tue, 13 Jun 2017 20:17:01 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
To: tetsujin@scope-eye.net
References: <873a0a6fdff48f7f618f95f481a3de3bbd527830@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <a9695dc0-2aff-5103-62d3-506f705d315b@case.edu>
Date: Tue, 13 Jun 2017 20:17:00 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <873a0a6fdff48f7f618f95f481a3de3bbd527830@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.231215:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_600_699, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:17:09 -0000

On 6/13/17 5:55 PM, tetsujin@scope-eye.net wrote:
> 
> ...Though Apple now sticks to Bash 3.2 to avoid GPL v3 right? Makes 'em
> kind of an odd use-case, and maybe a bit irrelevant with respect to the
> future direction of Bash.

Maybe, but that wasn't the question.  Mac OS X arguably has the largest
bash user base. I do have to admit that I don't get nearly as many bug
reports from Mac OS X users as other OSs.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:26:39 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKw8s-0004Gc-VU
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:26:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54676)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKw8q-0004GV-99
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:26:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKw8n-0005ZU-3h
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:26:36 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:41324
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKw8m-0005ZQ-U1
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:26:33 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH97657; Tue, 13 Jun 2017 20:26:29 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPC54037 (AUTH cpr);
	Tue, 13 Jun 2017 20:26:26 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Greg Wooledge <wooledg@eeg.ccf.org>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
	<59407C43.8010503@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <c137d3f8-6d3b-fb7e-6053-f0e81b46d165@case.edu>
Date: Tue, 13 Jun 2017 20:26:25 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <59407C43.8010503@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.231215:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_2000_2999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, __CC_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:26:37 -0000

On 6/13/17 7:58 PM, L A Walsh wrote:
> 
> 
> Chet Ramey wrote:
>> On 6/2/17 6:23 PM, L A Walsh wrote:
>>
>>  
>>> As for unsupported systems, there is a reason they are no longer
>>> supported.  The world is already using UTF-8.  It's only a few
>>> luddites clinging to ascii as a last refuge. ;-)
>>>
>>> What display/OS do you have that you can't run UTF-8 on?
>>>     
>>
>> This is a red herring. de_DE.UTF-8 and zh_KH.UTF-8 don't use the same
>> character set.
>>   
> ---
>    The use the same encoding.  Whether or not they use
> the same character set is up to someone's preference.  Looking at my
> local fonts, it looks like 'Code2000' covers both of those ranges:
> Germany and Khmer ?  But using 1 font for both isn't necessary.

That's not relevant to the issue of whether or not a particular character
is classified as alphabetic in one locale and not another. That is the
largest issue with locale-specific identifiers.  I'm not as concerned
with how a particular character displays; that's not important to
interpreting the script.


> Forgive me if I'm misremembering, but hasn't Greg argued against
> the ability to supply "libraries" of re-usable scripts due to
> the ease with which names could conflict with each other and cause
> script incompatibilities?

I'm sure he has. It's a genuine problem without namespaces, so you have
to adopt some naming convention that provides pseudo-namespace
functionality.


> If it is the case that script libraries had access to unicode
> var & func names (and used it), wouldn't that significantly
> decrease the the chances of conflict?  Right now, what, ...
> maybe A-Za-z_0-9 + maybe a few others == that's about 64 chars?

63 x as many characters are in your identifier. You can easily choose
some prefix (like readline uses _rl_ and rl_) and reduce the potential
for clashes.

> Even if a character doesn't display in your locality, doesn't
> mean it wouldn't work -- i.e. if I don't have a Cryllic font
> installed, that doesn't mean the script wouldn't work -- as
> the characters would still be encoded as their Unicode values.

A character that is classified as being a valid alphabetic in one
locale may not be such in another, regardless of its encoding.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 20:35:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKwHk-0006Ei-2A
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:35:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56449)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKwHi-0006EX-3Z
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:35:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKwHf-0008EB-0b
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:35:46 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:43734
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKwHe-0008Dz-Gd
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:35:42 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5E0ZWCU006891; Tue, 13 Jun 2017 17:35:34 -0700
Message-ID: <594084D4.1000402@tlinx.org>
Date: Tue, 13 Jun 2017 17:35:32 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
	<59407C43.8010503@tlinx.org>
	<c137d3f8-6d3b-fb7e-6053-f0e81b46d165@case.edu>
In-Reply-To: <c137d3f8-6d3b-fb7e-6053-f0e81b46d165@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:35:47 -0000



Chet Ramey wrote:
> That's not relevant to the issue of whether or not a particular character
> is classified as alphabetic in one locale and not another.
That isn't relevant either.  Unicode declares the categories
that characters are in -- GLOBALLY.  It doesn't vary by locale.


>
>
>   
>> Even if a character doesn't display in your locality, doesn't
>> mean it wouldn't work -- i.e. if I don't have a Cryllic font
>> installed, that doesn't mean the script wouldn't work -- as
>> the characters would still be encoded as their Unicode values.
>>     
>
> A character that is classified as being a valid alphabetic in one
> locale may not be such in another, regardless of its encoding.
>   
---
    Doesn't happen in Unicode -- which is why I specified
to use Unicode rules.  Look at the unicode utils I mentioned.
They can show you (the info from the unicode tables) what
class each letter is in.  Perl did this years ago.
They only allow the types of unicode char associated with
ID's in identifiers.  The unicode properties don't vary by
locale.






From MAILER-DAEMON Tue Jun 13 20:50:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKwWD-0001Zv-Ea
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 20:50:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59517)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKwWB-0001Zj-Dn
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:50:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKwW6-0003f2-Is
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:50:43 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:32652
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKwW6-0003ey-CY
	for bug-bash@gnu.org; Tue, 13 Jun 2017 20:50:38 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN21604; Tue, 13 Jun 2017 20:50:34 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPP37881 (AUTH cpr);
	Tue, 13 Jun 2017 20:50:34 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Greg Wooledge <wooledg@eeg.ccf.org>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: L A Walsh <bash@tlinx.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
	<59407C43.8010503@tlinx.org>
	<c137d3f8-6d3b-fb7e-6053-f0e81b46d165@case.edu>
	<594084D4.1000402@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <5ce52418-a206-c54b-09c9-675ed4484c43@case.edu>
Date: Tue, 13 Jun 2017 20:50:31 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <594084D4.1000402@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.13.235416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_700_799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 00:50:44 -0000

On 6/13/17 8:35 PM, L A Walsh wrote:
> 
> 
> Chet Ramey wrote:
>> That's not relevant to the issue of whether or not a particular character
>> is classified as alphabetic in one locale and not another.
> That isn't relevant either.  Unicode declares the categories
> that characters are in -- GLOBALLY.  It doesn't vary by locale.

But people don't work in Unicode. They work in their own locale.
That locale may be consistent with Unicode, and it may not.  Adding
something that doesn't respect a user's locale isn't useful.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 21:27:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKx5m-0000b7-W7
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 21:27:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36088)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKx5k-0000b1-LQ
	for bug-bash@gnu.org; Tue, 13 Jun 2017 21:27:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dKx5g-0004wm-Qu
	for bug-bash@gnu.org; Tue, 13 Jun 2017 21:27:28 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:60059
	helo=homiemail-a116.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dKx5g-0004wg-Eo
	for bug-bash@gnu.org; Tue, 13 Jun 2017 21:27:24 -0400
Received: from homiemail-a116.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a116.g.dreamhost.com (Postfix) with ESMTP id 384B260001346;
	Tue, 13 Jun 2017 18:27:20 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=iI84UChcMUzS7Sns
	a05MPnowknc=; b=fC61vRB0KlUKW0iEGAB8JIfMBMjSncnygndVlIb9xV5gTl/F
	1QDEStkcsXmFWQE+rz0uKjLmcy8U0+meI3HtFkEpW7tFxUUBsNivQh8zNWswt/mA
	6oSVRKooouuMAxySWyluUxLFnnPDLtL65/fvs526MZ3xvGvf3tA/vOb/gss=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a116.g.dreamhost.com (Postfix) with ESMTPSA id
	9FD2E60001341; Tue, 13 Jun 2017 18:27:19 -0700 (PDT)
Message-ID: <1497403638.17253.515.camel@scope-eye.net>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
From: George <tetsujin@scope-eye.net>
To: chet.ramey@case.edu, Greg Wooledge <wooledg@eeg.ccf.org>
Cc: bug-bash <bug-bash@gnu.org>
Date: Tue, 13 Jun 2017 21:27:18 -0400
In-Reply-To: <9f6fba01-4b23-8b75-b887-735fce2a18d3@case.edu>
References: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
	<9f6fba01-4b23-8b75-b887-735fce2a18d3@case.edu>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 01:27:30 -0000

On Tue, 2017-06-13 at 20:14 -0400, Chet Ramey wrote:
> On 6/13/17 5:19 PM, tetsujin@scope-eye.net wrote:
> > 
> > 
> > In that case, the answer is simple:
> > 
> > The shell swiftly rejects the script, and provides a clear reason why
> > it cannot be run. ("bash: Script requires the en_US.utf8 locale which
> > is not installed on this system. Sorry, dude.")
> The shell has no business doing this. If a script requires a certain
> locale, and won't run correctly without it, the author can ensure that
> an assignment to LC_CTYPE produces the desired results.
> 
I already addressed this. Changing LC_CTYPE doesn't just impact how the shell interprets the script, it also changes how various other I/O operations
occur, how filenames are processed, and (presumably, assuming locale is exported) the setting is inherited by commands run by the script as well.
If my system's locale were based on GB18030, and I run a shell script that's encoded in UTF-8, and the author of that script had the bright idea to
set LC_CTYPE to en_US.utf8 to make the shell work in any locale - then I haven't succeeded in "running a script in a different locale than the one it
was written in", because once LC_CTYPE has been reset I am no longer IN my system's locale for the duration of that script.
The script doesn't necessarily require to run IN a particular locale, it needs to be INTERPRETED according to a certain locale, because locale
settings influence how the parser works.
> > 
> > This is also why I think this should be an optional "encoding marker"
> > at a fairly fixed location in the file, rather than an option setting
> > that could occur anywhere in the script: It allows an incompatible
> > script to be immediately identified and rejected before it does
> > anything.
> > 

> 
> 
> This is relatively trivial to do with a shell function.
> 
> 

Sure, I just don't think that's the right answer.
If this method of supporting cross-locale scripts were adopted (and honestly, that possibility seems pretty remote, but I'm enjoying the discussion
anyway), this is a check we'd want in place for pretty much every script that uses the feature. Every time the script is run, we'd want to know first,
"can the shell run this script?" - there's no point repeating that bit of boilerplate in every single script. And there's nothing out there that can
better answer the question "Can the shell run this?" than the shell. And if the answer is "no" then it doesn't make sense for the shell to do anything
BUT error out of processing the script. And we should get that answer without *running* the script.

From MAILER-DAEMON Tue Jun 13 22:10:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKxlH-0003x5-0g
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 22:10:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42613)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKxlE-0003wu-KN
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:10:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dKxlB-0000po-9r
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:10:20 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:49530
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dKxlB-0000pc-1d
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:10:17 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANH99871; Tue, 13 Jun 2017 22:10:11 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPP68204 (AUTH cpr);
	Tue, 13 Jun 2017 22:10:10 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
To: George <tetsujin@scope-eye.net>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <9fb59c27a753936045c35ae46700805025566404@webmail.scope-eye.net>
	<9f6fba01-4b23-8b75-b887-735fce2a18d3@case.edu>
	<1497403638.17253.515.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <89d14ee7-6c4f-cf63-e8e6-53398a4090e0@case.edu>
Date: Tue, 13 Jun 2017 22:10:09 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <1497403638.17253.515.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.14.11216:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_4000_4999, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 02:10:22 -0000

On 6/13/17 9:27 PM, George wrote:
> On Tue, 2017-06-13 at 20:14 -0400, Chet Ramey wrote:
>> On 6/13/17 5:19 PM, tetsujin@scope-eye.net <mailto:tetsujin@scope-eye.net> wrote:
>>> In that case, the answer is simple: The shell swiftly rejects the
>>> script, and provides a clear reason why it cannot be run. ("bash: Script
>>> requires the en_US.utf8 locale which is not installed on this system.
>>> Sorry, dude.") 
>>
>>
>> The shell has no business doing this. If a script requires a certain
>> locale, and won't run correctly without it, the author can ensure that
>> an assignment to LC_CTYPE produces the desired results.
>>
> I already addressed this. Changing LC_CTYPE doesn't just impact how the
> shell interprets the script, it also changes how various other I/O
> operations occur, how filenames are processed, and (presumably, assuming
> locale is exported) the setting is inherited by commands run by the script
> as well.

LC_CTYPE affects case and collation, but not necessarily other I/O ops
or filename processing, except to the extent that they're sorted.  It
does affect regular expression character class processing.

And it's easy enough to avoid exporting LC_CTYPE. If you want to really
nail things down, you can export LC_ALL with its original value, unexport
LC_CTYPE, and make sure LANG is unset.

> If my system's locale were based on GB18030, and I run a shell script
> that's encoded in UTF-8, and the author of that script had the bright idea
> to set LC_CTYPE to en_US.utf8 to make the shell work in any locale - then I
> haven't succeeded in "running a script in a different locale than the one
> it was written in", because once LC_CTYPE has been reset I am no longer IN
> my system's locale for the duration of that script.

Quite true. And that's why the author would set LC_CTYPE -- if he embedded
something that required UTF-8 encoding and character classification. I
would argue that nobody interested in real portability would do that, but
we all know of plenty of non-portable scripts in wide distribution.

> The script doesn't necessarily require to run IN a particular locale, it
> needs to be INTERPRETED according to a certain locale, because locale
> settings influence how the parser works.

They really don't very much.  And if I add provisions to allow alpha-
numerics in the current locale to the set of acceptable characters for
identifiers, that would affect the parser only to the extent that commands
are or are not interpreted as assignment statements. All of the shell's
syntactic elements are single-byte characters, or composed of single-byte
characters, so there are few ways for locale-specific character classes to
affect the parser.

(And for a shell script, running and being interpreted is a distinction
without a difference. You can't really "run" a script without interpreting
it.)

> 
>>> This is also why I think this should be an optional "encoding marker" at
>>> a fairly fixed location in the file, rather than an option setting that
>>> could occur anywhere in the script: It allows an incompatible script to
>>> be immediately identified and rejected before it does anything. 
>>
>>
>> This is relatively trivial to do with a shell function.
>>
> Sure, I just don't think that's the right answer.
> If this method of supporting cross-locale scripts were adopted (and
> honestly, that possibility seems pretty remote, but I'm enjoying the
> discussion anyway), this is a check we'd want in place for pretty much
> every script that uses the feature. Every time the script is run, we'd want
> to know first, "can the shell run this script?" - there's no point
> repeating that bit of boilerplate in every single script. And there's
> nothing out there that can better answer the question "Can the shell run
> this?" than the shell. And if the answer is "no" then it doesn't make sense
> for the shell to do anything BUT error out of processing the script. And we
> should get that answer without *running* the script.

A script that someone writes for his own use won't need it.  A script that
is distributed and expected to run on other systems won't need it unless it
chooses to use locale-specific identifiers. It's one of those portability
decisions -- if you want to do things a certain way, you need to make sure
things can be done that way. Locale verification isn't a feature that would
be used enough to make putting it into the shell worthwhile.

It would, however, be trivial to do with a loadable builtin.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 13 22:34:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKy95-00011q-RD
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 22:34:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45526)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKy93-00011k-E8
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:34:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dKy90-0006bZ-9I
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:34:57 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:48200
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dKy90-0006b8-0Q
	for bug-bash@gnu.org; Tue, 13 Jun 2017 22:34:54 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5E2Ykdi014039; Tue, 13 Jun 2017 19:34:48 -0700
Message-ID: <5940A0C6.3070703@tlinx.org>
Date: Tue, 13 Jun 2017 19:34:46 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
	<59407C43.8010503@tlinx.org>
	<c137d3f8-6d3b-fb7e-6053-f0e81b46d165@case.edu>
	<594084D4.1000402@tlinx.org>
	<5ce52418-a206-c54b-09c9-675ed4484c43@case.edu>
In-Reply-To: <5ce52418-a206-c54b-09c9-675ed4484c43@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 02:34:58 -0000



Chet Ramey wrote:
> On 6/13/17 8:35 PM, L A Walsh wrote:
>   
>> Chet Ramey wrote:
>>     
>>> That's not relevant to the issue of whether or not a particular character
>>> is classified as alphabetic in one locale and not another.
>>>       
>> That isn't relevant either.  Unicode declares the categories
>> that characters are in -- GLOBALLY.  It doesn't vary by locale.
>>     
>
> But people don't work in Unicode. They work in their own locale.
> That locale may be consistent with Unicode, and it may not.  Adding
> something that doesn't respect a user's locale isn't useful.
>   
----
    It's locale agnostic.  On the Web (html5), on Windows, on Linux, all 
of them are using Unicode and they all work, are viewable and usable in
different locales.  The web WAS in the western locale w/html4 and 
before, but its using locale agnostic utf-8 in html5.  More and more 
locales are
switching to utf8 only.  I posted the numbers earlier in this
thread:
========================
If you look at the locales on a recent linux distro, (locale -a), out of
279 country codes, you'll see
 9 that only have a local-encoding listed.
98 have no encoding listed (guessing they default to POSIX)
172 that have UTF-8
  and
139 that ONLY have UTF-8 listed.

Just from the numbers if you _don't_ support UTF-8 you support
131 locales (47%).  If you do support UTF-8, you can reach
270 locales (97%).

Seems that by supporting UTF-8, you have a good chance of being
understandable in over 95% of the locales in the locale database,
vs. less than 50% if you don't
===========================
So you say that "this year" we don't respect 3.3% of locals that
currently don't use unicode vs over 95% that do.  At some
point you figure out the costs to support 95% vs. the
extra costs to support those 3%, *this year*.  The ones
that haven't moved to unicode decrease ever year.
Making the claim that a solution won't work unless it covers
100% is riduculous given how large a percentage is
covered by the 63 chars in ASCII. 

And I don't know what you mean by people don't work in unicode.
If they work with the web, they do.  If they work on windows
or linux, they do.  Probably Macs as well --- most people
just may not be aware of it.

How many already work with English or ASCII?  Those are
already included in Unicode.





From MAILER-DAEMON Tue Jun 13 23:04:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dKybc-0008AL-U9
	for mharc-bug-bash@gnu.org; Tue, 13 Jun 2017 23:04:28 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54917)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dKybb-0008AE-3C
	for bug-bash@gnu.org; Tue, 13 Jun 2017 23:04:27 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dKybW-0002Bi-7A
	for bug-bash@gnu.org; Tue, 13 Jun 2017 23:04:27 -0400
Received: from mail-pf0-x236.google.com ([2607:f8b0:400e:c00::236]:34004)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dKybV-0002B8-V1
	for bug-bash@gnu.org; Tue, 13 Jun 2017 23:04:22 -0400
Received: by mail-pf0-x236.google.com with SMTP id s66so8786010pfs.1
	for <bug-bash@gnu.org>; Tue, 13 Jun 2017 20:04:20 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=quNdN/kyH9OcLh+j+YvaJwnFmX3+BSoy+I6Z9Mj9Gak=;
	b=tixkpUUwE8DebchVJc6MGcdophuDQ0MsD3xIA3fY9z0pid68o1ocnVOoQv72rd7Fn1
	uZS/uCoPPIL3BZSrIlwp/ucKVGcTpQ1b3hLt4vWBMe05AUqVxP6NfhDPmb2iEQp0Cccc
	lqnDJqaavQgjO0IlosUjOBiVYO1FdLqa+wfS+2OhFV7EwIHhtoNqAKcxm5pbPAEeZ7pn
	hOwE4fNFSp1YtPtH48WmmtdnhxbnAAY2A3IpAXlhbKLr01khDkOAuG1sfZjxgJrPvrx7
	g8glAzSxkRV1NAW0Gqh+CliCnm4lTuSbhTT0eMuCOTxJkee5TtXOuj+dGtzsEc6xcuQx
	o2CQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=quNdN/kyH9OcLh+j+YvaJwnFmX3+BSoy+I6Z9Mj9Gak=;
	b=YMUhyM0fxrV4c1maCDJXxpwN7iABbPAoysm+vPgymYNRudsXh4NzsJdbVAnLxHW7RZ
	++uCA5V7yhdAy/D7lmZN3IsOsPU4Mu2iTEvJ+BMkPoup8BSCWlAwSj9OJojEa/V7PVSj
	69adwRYDSQeBN62hr07wTuJvDAPLJfR76ZHPbMo2MAJBoZuN6+tf3fwwu74qD6C2i6zo
	Y5kOu59ODYhciQIeF/H9WutLJxp/bRdR+ULzuhEFAg6f3Tvu8wrYTck1XPRWBm1mDgtn
	x7B+J8eeSajQra+4Zt8bEEwKeO6Lo0FDuhoFXyKp8iQzscEY0xbK6Tq+rfCKj8z7yKXV
	d+2g==
X-Gm-Message-State: AKS2vOzPhrQNviFORPAdzAX23P7Y7MBX05eml+hmrjHodaC6pfN4/+mE
	pmTaoXUGdTSLUYtT
X-Received: by 10.84.217.25 with SMTP id o25mr2581601pli.201.1497409459371;
	Tue, 13 Jun 2017 20:04:19 -0700 (PDT)
Received: from [192.168.4.100] ([171.4.48.146])
	by smtp.gmail.com with ESMTPSA id
	69sm27240115pfy.119.2017.06.13.20.04.17 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 13 Jun 2017 20:04:18 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Subject: Re: Trailing newlines disappear
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <ddbdd452-d1ec-786e-4951-f24c202e7fa5@passchier.net>
	<20170608174238.GH3691@eeg.ccf.org>
	<8a848d3b-d602-39ae-e46c-8f8b0d385196@passchier.net>
	<20170608191440.GI3691@eeg.ccf.org>
	<1fe420a1-13a0-291b-bb5f-e236e964e96f@passchier.net>
	<20170608204429.p3dwazxuqqlp3yeb@MacGeir>
	<20170608205637.GK3691@eeg.ccf.org>
	<CAOSMAusOp09tFC38+k5ShG+BLMA1h_xab90-eWBsYKrLkFb=Qw@mail.gmail.com>
	<6f8da598-168f-cdbd-e170-735b5bc9bd6f@passchier.net>
	<20170609120642.GL3691@eeg.ccf.org>
	<ba96609a-6f0b-8a89-7bc4-a6c99872408a@case.edu>
	<593ACF01.3000404@tlinx.org>
	<b1638d2a-b2a6-80b0-a0b5-4b027dc7a054@passchier.net>
	<d3c28d1d-4245-4597-bbdf-f50a53184dca@case.edu>
	<d9b0b7e9-1aaa-b80b-e167-9587c68a82d7@passchier.net>
	<88028197-5c95-c784-9c5e-018c530d643b@case.edu>
Message-ID: <55f44e7e-5ae2-6b6f-b98e-434519bc1890@passchier.net>
Date: Wed, 14 Jun 2017 10:04:15 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <88028197-5c95-c784-9c5e-018c530d643b@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 03:04:27 -0000

On 14/06/2560 03:52, Chet Ramey wrote:
> You mean command substitution cutting off the input it reads at the
> occurrence of a NUL?

What I am really after is a shell option for command substitution not
discarding trailing newlines.

Peter




From MAILER-DAEMON Wed Jun 14 08:08:46 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dL76M-0001wE-6a
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 08:08:46 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59663)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL76J-0001w6-EU
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:08:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL76G-0007dv-2x
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:08:43 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:36501 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL76F-0007Qn-Ro
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:08:40 -0400
Received: (qmail 11192 invoked from network); 14 Jun 2017 12:08:10 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Wed, 14 Jun 2017 08:08:10 -0400
Received: (qmail 23851 invoked by uid 563); 14 Jun 2017 12:08:10 -0000
Date: Wed, 14 Jun 2017 08:08:10 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170614120810.GA22519@eeg.ccf.org>
References: <9ebad712-87bc-3dcf-82a2-0415a3ef0146@case.edu>
	<829785493d324b60eb46937621879764c024d3a1@webmail.scope-eye.net>
	<20170613210010.GD3691@eeg.ccf.org>
	<cfd45e31-e1d7-06e5-e7a2-cb0bbf760213@case.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <cfd45e31-e1d7-06e5-e7a2-cb0bbf760213@case.edu>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 12:08:44 -0000

On Tue, Jun 13, 2017 at 08:06:50PM -0400, Chet Ramey wrote:
> That works with Mac OS X, where the output of locale(1) is a series of
> shell assignment statements with quoted values; your mileage may vary, of
> course.

POSIX <http://pubs.opengroup.org/onlinepubs/9699919799/utilities/locale.html>
defines the format.  LANG is unquoted, and other values are either
quoted or unquoted depending on whether they are explicitly set in the
environment, or derived.

Sounds pretty unsafe to eval, to me.

imadev:~$ locale
LANG=en_US.iso88591
LC_CTYPE="en_US.iso88591"
LC_COLLATE="en_US.iso88591"
LC_MONETARY="en_US.iso88591"
LC_NUMERIC="en_US.iso88591"
LC_TIME=POSIX
LC_MESSAGES="en_US.iso88591"
LC_ALL=
imadev:~$ LC_CTYPE='$(date +%Y%m%d)' locale

Warning! One or more of your selected locales are not available.
Please invoke the commands "locale" and "locale -a" to verify your
selections and the available locales.

Continuing processing using the "C" locale.

LANG=en_US.iso88591
LC_CTYPE=$(date +%Y%m%d)
LC_COLLATE="C"
LC_MONETARY="C"
LC_NUMERIC="C"
LC_TIME=POSIX
LC_MESSAGES="C"
LC_ALL=


From MAILER-DAEMON Wed Jun 14 08:43:22 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dL7dq-00075y-7s
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 08:43:22 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39509)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL7dn-00075e-GU
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:43:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL7dk-0003BZ-DU
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:43:19 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:36514 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dL7dk-0003BG-6J
	for bug-bash@gnu.org; Wed, 14 Jun 2017 08:43:16 -0400
Received: (qmail 11413 invoked from network); 14 Jun 2017 12:43:14 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Wed, 14 Jun 2017 08:43:14 -0400
Received: (qmail 23912 invoked by uid 563); 14 Jun 2017 12:43:14 -0000
Date: Wed, 14 Jun 2017 08:43:14 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Please allow unicode ID chars in identifiers
Message-ID: <20170614124314.GB22519@eeg.ccf.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5931E57E.8090801@tlinx.org>
	<da910517-a1da-b08e-b9cb-661fc887cf6f@case.edu>
	<59407C43.8010503@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <59407C43.8010503@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 12:43:20 -0000

On Tue, Jun 13, 2017 at 04:58:59PM -0700, L A Walsh wrote:
> Forgive me if I'm misremembering, but hasn't Greg argued against
> the ability to supply "libraries" of re-usable scripts due to
> the ease with which names could conflict with each other and cause
> script incompatibilities?

Namespace collisions are certainly an issue, yes.  But my primary
argument against trying to write "libraries" in bash has always been
the limitations of bash's functions.

1) You can't return values from them (making them more like "commands"
   than actual functions).

2) You can't pass variables by reference.  Therefore:

3) You can't pass the name of a variable in which you'd like to receive
   a value from the function, to work around point 1.

4) You can't pass an array by name.  You have to pass every single array
   element separately, losing the indices in the process.

"declare -n" looks like it should address point 2, but it doesn't
do so safely.  It only works if you magically choose a name (within
the function) that the caller does NOT choose (outside the function).
In fact, the caller's variable name must not match ANY local variable
of the function, or it breaks.

See examples at <http://mywiki.wooledge.org/BashProgramming#Functions>.

If your function is recursive (is its own caller), then you're simply
doomed -- you can't avoid having the same name used in the caller and
callee, because they're both the same piece of code.  You might be able to
hack up a global indexed array of return values, and then each instance
of the recursive function can use its recursion depth as an index into
this array to retrieve its return value.  That's the best I can think of.


From MAILER-DAEMON Wed Jun 14 11:19:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLA5I-0007PY-Ge
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 11:19:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37527)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLA58-0007Hx-Ae
	for bug-bash@gnu.org; Wed, 14 Jun 2017 11:19:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLA4y-0007Bx-UU
	for bug-bash@gnu.org; Wed, 14 Jun 2017 11:19:42 -0400
Received: from mail-ot0-x22d.google.com ([2607:f8b0:4003:c0f::22d]:36849)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLA4y-0007B0-FK
	for bug-bash@gnu.org; Wed, 14 Jun 2017 11:19:32 -0400
Received: by mail-ot0-x22d.google.com with SMTP id s7so2857389otb.3
	for <bug-bash@gnu.org>; Wed, 14 Jun 2017 08:19:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=KUxhY6j3K8yXqbbdNUQNPzwnbKZiRDa/puRT9WxhOLs=;
	b=kT6b/OSCYKVdTZe7f0DWg/0Qbfs6E41Q1gKUgP26iozpAO3k1eV1sVAlEuP6JMClj3
	Sw1A0MPcSfG/bmC+gMDCceBPkkN3LUiuIG3zxEqGWeSg5fX4IaUlsbxPcYKAWfkpPLeV
	A0FaIp9k6eKZ1YMD3KA8V40kqGS26b4hy+Z4VLDZqe5rLmgcxtn01CNVw/x5RlVN5u68
	UBs2sN/1lVYuYuuj5dcY399z0eLhq2nTndMgfEdfKuMbEvSut5J20n9aKq6ay1I0AN22
	8fu0MKPjKuznE+seoqHLth+zfo3SiZMMOt+rIf1reUPI8QNZcXLUMCQXvZlFpYEykMMM
	33eg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=KUxhY6j3K8yXqbbdNUQNPzwnbKZiRDa/puRT9WxhOLs=;
	b=r1wT++lj3PByWUjJOwcNdvq0bWn8yy3IjkAkn6t+GJsVayxL3JAmhBT0CnKlxHJAfk
	dmtzKdeISsC2Kr92xCYAxVE7q6LY85j0jhJr9MHVcoNKAoi+2A4qpNv2OFoq3Um/EeFS
	2un7qApZdPKubRhzu7WL7W334J9qJ2rIl9e1IrDSrHy3sRmrEPgKJRNmwDYW2BPL2v9D
	dMpi9QoDj9Ar7gvIYEPMKYVV18w347iqblgn1pzKEnrpHKz/qoB+D7Qpconq3onWammj
	nI0QZLCksg2fgDen8PyGrh7ig/l5pKcbu96p/EhZXCVUDt0GvuqRMNIg9gojEUeCjmh7
	rYng==
X-Gm-Message-State: AKS2vOzxjVdCkYRYf3HokexmRfkvtosFGXATB6v5wqjCndaW8JayArEQ
	L+PJVamsOiXuUg==
X-Received: by 10.157.82.91 with SMTP id q27mr533264otg.163.1497453567929;
	Wed, 14 Jun 2017 08:19:27 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id l92sm162602otc.13.2017.06.14.08.19.26
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Wed, 14 Jun 2017 08:19:27 -0700 (PDT)
Date: Wed, 14 Jun 2017 10:19:24 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: AddressSanitizer: heap-buffer-overflow
	_rl_find_prev_mbchar_internal / expand_prompt
Message-ID: <20170614151924.ucgxwya2h5izvuof@debian>
References: <20170613151431.ka6rw6tnjaavtyco@debian>
	<ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 15:19:51 -0000

On Tue, Jun 13, 2017 at 04:30:23PM -0400, Chet Ramey wrote:
[...]
> I can't reproduce it with asan or without on Mac OS X. I'll look around
> for a Linux system with asan to run it on.

All these inputs seem to trigger the same problem. You'll find the
stacktrace as reported by ASAN first, and then the corresponding input
base64 encoded.


==12445==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60d00000c159 at pc 0x7f0b81373063 bp 0x7ffc11229040 sp 0x7ffc112287f0
READ of size 138 at 0x60d00000c159 thread T0
    #0 0x7f0b81373062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55787f2df88b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55787f2e035c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55787f2aeca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55787f2ba190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55787f2a8986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55787f2adab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #7 0x55787f2adcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55787f2a87ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55787f27e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55787f27dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55787f27d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55787f27d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55787f27d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55787f27ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55787f238136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55787f235aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55787f14bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55787f14d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55787f14b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55787f138f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55787f2230f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55787f104401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55787f1028da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f0b80b8b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55787f101749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60d00000c159 is located 0 bytes to the right of 137-byte region [0x60d00000c0d0,0x60d00000c159)
allocated by thread T0 here:
    #0 0x7f0b813f8d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55787f211d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55787f2ae574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55787f2ba190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55787f2a8986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55787f2adab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #6 0x55787f2adcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55787f2a87ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55787f27e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55787f27dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55787f27d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55787f27d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55787f27d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55787f27ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55787f238136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55787f235aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55787f14bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55787f14d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55787f14b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55787f138f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55787f2230f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55787f104401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55787f1028da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f0b80b8b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c1a7fff97d0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff97e0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff97f0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9800: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9810: fa fa fa fa fa fa fa fa fa fa 00 00 00 00 00 00
=>0x0c1a7fff9820: 00 00 00 00 00 00 00 00 00 00 00[01]fa fa fa fa
  0x0c1a7fff9830: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff9840: fd fd fd fd fd fd fa fa fa fa fa fa fa fa fd fd
  0x0c1a7fff9850: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff9860: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c1a7fff9870: fd fd fd fd fd fd fd fd fd fd fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==12445==ABORTING

INPUT
GwMWF/zuFQAXCxcXFwAD6FNTALwAABAAgCkZGRkZ/zpQFxkZGRkZGRcXIH/6AAD6jlxchDP8GQAB
AFhLYEpLZ0tKOEsQSz0aGgIZGSEZAID/GRkZGRkZS0tXS0tLAAAAAEtLHBMZWmBKS0tLSjhLEEtL
S0tKS0tLSj0+EEtLHBkZGRkZGbS8Ehn/OlAXGRkZGRkZFxcgLA==



==12456==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60d00000cd8f at pc 0x7ffb5bb14063 bp 0x7fff1f7e1e40 sp 0x7fff1f7e15f0
READ of size 144 at 0x60d00000cd8f thread T0
    #0 0x7ffb5bb14062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x5629fe96888b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x5629fe96935c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x5629fe937ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x5629fe943190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x5629fe931986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x5629fe936784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x5629fe936cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x5629fe9317cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x5629fe90730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x5629fe906ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x5629fe906727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x5629fe9067b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x5629fe9067dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x5629fe905e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x5629fe8c1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x5629fe8beaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x5629fe7d4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x5629fe7d689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x5629fe7d411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x5629fe7c1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x5629fe8ac0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x5629fe78d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x5629fe78b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7ffb5b32c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x5629fe78a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60d00000cd8f is located 0 bytes to the right of 143-byte region [0x60d00000cd00,0x60d00000cd8f)
allocated by thread T0 here:
    #0 0x7ffb5bb99d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5629fe89ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5629fe937574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x5629fe943190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x5629fe931986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x5629fe936784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x5629fe936cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x5629fe9317cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x5629fe90730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x5629fe906ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x5629fe906727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5629fe9067b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5629fe9067dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x5629fe905e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x5629fe8c1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x5629fe8beaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x5629fe7d4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x5629fe7d689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x5629fe7d411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x5629fe7c1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5629fe8ac0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x5629fe78d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x5629fe78b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7ffb5b32c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c1a7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9990: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff99a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c1a7fff99b0: 00[07]fa fa fa fa fa fa fa fa 00 00 00 00 00 00
  0x0c1a7fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 fa fa fa fa
  0x0c1a7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff99e0: fd fd fd fd fd fa fa fa fa fa fa fa fa fa fd fd
  0x0c1a7fff99f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fa
  0x0c1a7fff9a00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==12456==ABORTING

INPUT
GwMWF/zuFQAXCxcXFwAD6FNTALwAABcAgCkZGRkZ/zpQFxkZGRkZGRcXIH/6AAD6a1xchDP8GQAB
AFhLYEpLZ0tKOEsQSz0aGgIZGSEZAID/GRkZGRkZS0tXS0tLAAAAAEtLHBMZWmBKS0tLSjhLEEtL
S0tKS0tLSj1DEEtLHhkZGRkZGbS8GRn/OlAXGRkZGRkZFxcgLA==



==12475==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60d00000cd89 at pc 0x7f0fe9f1f063 bp 0x7ffe6681f370 sp 0x7ffe6681eb20
READ of size 138 at 0x60d00000cd89 thread T0
    #0 0x7f0fe9f1f062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x5630286d088b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x5630286d135c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x56302869fca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x5630286ab190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x563028699986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x56302869e784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x56302869ecae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x5630286997cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x56302866f30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x56302866eee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x56302866e727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x56302866e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x56302866e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x56302866de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x563028629136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x563028626aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x56302853cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x56302853e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x56302853c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x563028529f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x5630286140f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x5630284f5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x5630284f38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f0fe97372b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x5630284f2749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60d00000cd89 is located 0 bytes to the right of 137-byte region [0x60d00000cd00,0x60d00000cd89)
allocated by thread T0 here:
    #0 0x7f0fe9fa4d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x563028602d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56302869f574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x5630286ab190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x563028699986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x56302869e784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x56302869ecae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x5630286997cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x56302866f30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x56302866eee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x56302866e727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x56302866e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x56302866e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x56302866de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x563028629136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x563028626aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x56302853cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56302853e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56302853c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x563028529f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5630286140f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x5630284f5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x5630284f38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f0fe97372b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c1a7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff9990: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1a7fff99a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c1a7fff99b0: 00[01]fa fa fa fa fa fa fa fa 00 00 00 00 00 00
  0x0c1a7fff99c0: 00 00 00 00 00 00 00 00 00 00 00 02 fa fa fa fa
  0x0c1a7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c1a7fff99e0: fd fd fd fd fd fa fa fa fa fa fa fa fa fa fd fd
  0x0c1a7fff99f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fa
  0x0c1a7fff9a00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==12475==ABORTING

INPUT
GwMWF/zuFQAXCwAAACAD6FNTALwAABAAgCkZGRkZ/zpQFxkZGRkZGRcXIH/6AAD6jlxchDP8GQAB
AFhLYEpLZ0tKOEsQSz0aGgIZGSEZAID/GRkZGRkZSwBkS0tLAAAAAEtLHBMZWmBKS0tLSjhLEEtL
S0tKS0tLSj1LEEtLHBkZGRkZGbS8GRn/OlAXGRkZGRkZFxcgLA==



==12488==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60b00000a395 at pc 0x7f6463ad3063 bp 0x7ffce4c552f0 sp 0x7ffce4c54aa0
READ of size 102 at 0x60b00000a395 thread T0
    #0 0x7f6463ad3062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x563dd177888b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x563dd177935c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x563dd1747ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x563dd1753190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x563dd1741986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x563dd1746ab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #7 0x563dd1746cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x563dd17417cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x563dd171730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x563dd1716ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x563dd1716727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x563dd17167b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x563dd17167dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x563dd1715e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x563dd16d1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x563dd16ceaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x563dd15e4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x563dd15e689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x563dd15e411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x563dd15d1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x563dd16bc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x563dd159d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x563dd159b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f64632eb2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x563dd159a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60b00000a395 is located 0 bytes to the right of 101-byte region [0x60b00000a330,0x60b00000a395)
allocated by thread T0 here:
    #0 0x7f6463b58d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x563dd16aad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x563dd1747574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x563dd1753190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x563dd1741986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x563dd1746ab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #6 0x563dd1746cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x563dd17417cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x563dd171730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x563dd1716ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x563dd1716727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x563dd17167b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x563dd17167dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x563dd1715e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x563dd16d1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x563dd16ceaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x563dd15e4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x563dd15e689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x563dd15e411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x563dd15d1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x563dd16bc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x563dd159d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x563dd159b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f64632eb2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c167fff9420: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9430: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9440: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9450: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9460: fa fa fa fa fa fa 00 00 00 00 00 00 00 00 00 00
=>0x0c167fff9470: 00 00[05]fa fa fa fa fa fa fa fa fa 00 00 00 00
  0x0c167fff9480: 00 00 00 00 00 00 00 00 00 00 fa fa fa fa fa fa
  0x0c167fff9490: fa fa fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c167fff94a0: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c167fff94b0: fd fd fd fd fd fd fa fa fa fa fa fa fa fa 00 00
  0x0c167fff94c0: 00 00 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==12488==ABORTING

INPUT
GwMWF/zuFQAXCxcXFwAD6FNTALwAABAAgCkZGRkZ/zpQFxkZQAAZGRcXIH/jAAD6jlxchDP8GQAB
AFhLYEpLZ0sAAUsQSz0aGgIZGSEZAID/GRkZGRkZS0tXS0tLAAAAAEtLHBMZWmBKS0tLSjhLEEtL
S0tKS0tLSj1LEEtLHBkZGRkZGbS8GRn/OlAXGRkZGRkZFxcgLw==



==13418==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000ece3 at pc 0x7fb77f4a1063 bp 0x7fff34c647a0 sp 0x7fff34c63f50
READ of size 612 at 0x61600000ece3 thread T0
    #0 0x7fb77f4a1062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x56425c0ff88b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x56425c10035c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x56425c0ceca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x56425c0da190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x56425c0c8986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x56425c0cd784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x56425c0cdcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x56425c0c87ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x56425c09e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x56425c09dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x56425c09d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x56425c09d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x56425c09d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x56425c09ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x56425c058136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x56425c055aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x56425bf6bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x56425bf6d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x56425bf6b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x56425bf58f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x56425c0430f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x56425bf24401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x56425bf228da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7fb77ecb92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x56425bf21749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000ece3 is located 0 bytes to the right of 611-byte region [0x61600000ea80,0x61600000ece3)
allocated by thread T0 here:
    #0 0x7fb77f526d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56425c031d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56425c0ce574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x56425c0da190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x56425c0c8986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x56425c0cd784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x56425c0cdcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x56425c0c87ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x56425c09e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x56425c09dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x56425c09d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x56425c09d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x56425c09d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x56425c09ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x56425c058136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x56425c055aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x56425bf6bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56425bf6d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56425bf6b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x56425bf58f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x56425c0430f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x56425bf24401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x56425bf228da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fb77ecb92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9d40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9d50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9d90: 00 00 00 00 00 00 00 00 00 00 00 00[03]fa fa fa
  0x0c2c7fff9da0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9db0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9de0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==13418==ABORTING

INPUT
p6enpwAAAAGnpxCnlKi9JycfJycgqqgIh3SoqKgwGzg45wAAp6enp6enp6enAAAAAaenp6eUqAhA
4AAICAgIQLqf2br6/xkZB6hHlKi9JyeUqL0nJx9AACeqnwAABAAA+UdHR0dHR0dHTId0qKioMBs4
OOcAAKenp6enp6enpwAAAAGnp6enlKi9JycfJ4UgqqgICPr/GRkZGRkZEi4ZhhsP5en/E/9/ff//
gAAA7QAlC2Bg9PX2RwNTA0MDAwMDEQMDup+6urqAAMwICAgIKkDgBwADAwPiAgMDAwPuAwMDAwMD
AxAZGRsAAQAHCAgIKkDgAAgICAhAup/Zurre3tsICAgIJkDgugAI3AgIAAC6AAAdpgB/kA==



==16703==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61700000ed84 at pc 0x7f92f64a6063 bp 0x7ffe69dd1dd0 sp 0x7ffe69dd1580
READ of size 645 at 0x61700000ed84 thread T0
    #0 0x7f92f64a6062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55f1495a088b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55f1495a135c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55f14956fca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55f14957b190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55f149569986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55f14956e784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x55f14956ecae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55f1495697ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55f14953f30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55f14953eee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55f14953e727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55f14953e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55f14953e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55f14953de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55f1494f9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55f1494f6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55f14940cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55f14940e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55f14940c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55f1493f9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55f1494e40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55f1493c5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55f1493c38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f92f5cbe2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55f1493c2749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61700000ed84 is located 0 bytes to the right of 644-byte region [0x61700000eb00,0x61700000ed84)
allocated by thread T0 here:
    #0 0x7f92f652bd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f1494d2d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f14956f574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55f14957b190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55f149569986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55f14956e784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x55f14956ecae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55f1495697ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55f14953f30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55f14953eee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55f14953e727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55f14953e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55f14953e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55f14953de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55f1494f9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55f1494f6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55f14940cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55f14940e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55f14940c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55f1493f9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55f1494e40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55f1493c5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55f1493c38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f92f5cbe2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2e7fff9d60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9d70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9d90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9da0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2e7fff9db0:[04]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2e7fff9dc0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2e7fff9dd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9de0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9df0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2e7fff9e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==16703==ABORTING

INPUT
QBvz//wOYADtACULYGD08UAk////f/n5qEf5+fn5qCiUqAtgYPTxQEf5+fn5+QGoR/n5+fn/GRkZ
GRkZEi4ZZJ8AfgQAAPlHR0dHR0dHR0yHQACoqDAEAAD5R0dHR0dHR0dMh3SRqKgwGzg45wAAp6en
p6enpxs4OOcAAKenp6enp6enpwAAAAEZGRkZGRkSLhl5IQ/l/xol/399//wOYH/tACULYGD09fZH
A1MDQwMDAwMDAwO6n7q6x4AAzAgICAgqQOAHAAMDAwMDAwMDAwMDA0DjAgMDDBkZGwABAAAICAgq
QOQACAje3tsICAgIKkDgBwAI3AgIAAC3AAAdpgB/kA==



==16704==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000e98d at pc 0x7f638fed4063 bp 0x7ffe92091ff0 sp 0x7ffe920917a0
READ of size 526 at 0x61600000e98d thread T0
    #0 0x7f638fed4062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55b1102a388b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55b1102a435c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55b110272ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55b11027e190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55b11026c986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55b110271784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x55b110271cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55b11026c7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55b11024230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55b110241ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55b110241727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55b1102417b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55b1102417dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55b110240e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55b1101fc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55b1101f9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55b11010fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55b11011189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55b11010f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55b1100fcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55b1101e70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55b1100c8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55b1100c68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f638f6ec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55b1100c5749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000e98d is located 0 bytes to the right of 525-byte region [0x61600000e780,0x61600000e98d)
allocated by thread T0 here:
    #0 0x7f638ff59d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b1101d5d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b110272574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55b11027e190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55b11026c986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55b110271784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x55b110271cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55b11026c7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55b11024230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55b110241ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55b110241727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55b1102417b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55b1102417dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55b110240e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55b1101fc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55b1101f9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55b11010fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55b11011189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55b11010f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55b1100fcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55b1101e70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55b1100c8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55b1100c68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f638f6ec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9ce0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9cf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9d30: 00[05]fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9d40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9d50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==16704==ABORTING

INPUT
QFtbW1tbW1tbW1tbW1tbW1tbW1tbW1tbW1tbW1tbG3///A5gAO0AJQtgYPTxQEf5+fn5+fmoR/n5
+fmoKJSoCPr/GRkZGRkZEi4ZZJ8AAAQAAPlHR0dHR0dHR0yHdJGoqDAbODjnAACnp6enp6enp6cA
AAABGRkZGRkZEi4ZZCEP5f//Jf9/ff/8DmB/7QAlC2Bg9PX2RwNTA0MDAwMDAwMDup+6urqAAMwI
CAgI1NTU1NQqQOAHAAMDAwMDAwMDAwMDAwPjAgMDEBkZGwABAAAICAgqQOAACAje3tsICAgIKkDg
BwAI3AgIAAC3AAAdpgB/kA==



==18236==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61300000dab3 at pc 0x7f4401c15063 bp 0x7fffb2e33540 sp 0x7fffb2e32cf0
READ of size 372 at 0x61300000dab3 thread T0
    #0 0x7f4401c15062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x56448c87988b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x56448c87a35c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x56448c848ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x56448c854190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x56448c842986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x56448c847784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x56448c847cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x56448c8427cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x56448c81830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x56448c817ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x56448c817727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x56448c8177b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x56448c8177dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x56448c816e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x56448c7d2136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x56448c7cfaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x56448c6e5c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x56448c6e789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x56448c6e511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x56448c6d2f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x56448c7bd0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x56448c69e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x56448c69c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f440142d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x56448c69b749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61300000dab3 is located 0 bytes to the right of 371-byte region [0x61300000d940,0x61300000dab3)
allocated by thread T0 here:
    #0 0x7f4401c9ad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56448c7abd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56448c848574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x56448c854190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x56448c842986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x56448c847784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x56448c847cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x56448c8427cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x56448c81830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x56448c817ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x56448c817727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x56448c8177b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x56448c8177dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x56448c816e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x56448c7d2136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x56448c7cfaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x56448c6e5c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56448c6e789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56448c6e511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x56448c6d2f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x56448c7bd0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x56448c69e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x56448c69c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f440142d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c267fff9b00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c267fff9b10: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c267fff9b20: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c267fff9b30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c267fff9b40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c267fff9b50: 00 00 00 00 00 00[03]fa fa fa fa fa fa fa fa fa
  0x0c267fff9b60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c267fff9b70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c267fff9b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 04 fa
  0x0c267fff9b90: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c267fff9ba0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18236==ABORTING

INPUT
/wMAAugDKh0AAH8AnxkZGRkZILwAABAAgCkZGTYZ/zpQFxkZGRkZGRcXIH/6AAD6zlxcnTP8GQAB
AFhLYBkZGRkZFxcgf/oAAPrOXFyEM/wZAAEAWEtgSktLSktLS0o4SxBLS0scGRkZGRkZtLwZGf86
UBdLS1dLS0sAAAAAS0scExlgSktLSktLC1pgSktLS0o4SxBLS0tLSktLS0o9SxBLSxwZGRkZGQe0
qhkZ/zpQFxkZGRkZGRcXICw=



==23036==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000ecf5 at pc 0x7fca62518063 bp 0x7ffc83653670 sp 0x7ffc83652e20
READ of size 630 at 0x61600000ecf5 thread T0
    #0 0x7fca62518062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55a4b743788b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55a4b743835c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55a4b7406ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55a4b7412190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55a4b7400986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55a4b7405784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x55a4b7405cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55a4b74007ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55a4b73d630d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55a4b73d5ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55a4b73d5727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55a4b73d57b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55a4b73d57dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55a4b73d4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55a4b7390136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55a4b738daa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55a4b72a3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55a4b72a589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55a4b72a311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55a4b7290f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55a4b737b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55a4b725c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55a4b725a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7fca61d302b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55a4b7259749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000ecf5 is located 0 bytes to the right of 629-byte region [0x61600000ea80,0x61600000ecf5)
allocated by thread T0 here:
    #0 0x7fca6259dd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55a4b7369d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55a4b7406574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55a4b7412190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55a4b7400986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55a4b7405784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x55a4b7405cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55a4b74007ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55a4b73d630d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55a4b73d5ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55a4b73d5727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55a4b73d57b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55a4b73d57dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55a4b73d4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55a4b7390136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55a4b738daa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55a4b72a3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55a4b72a589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55a4b72a311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55a4b7290f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55a4b737b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55a4b725c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55a4b725a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fca61d302b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9d40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9d50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9d90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00[05]fa
  0x0c2c7fff9da0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9db0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9de0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23036==ABORTING

INPUT
QBt///wOYADtACULYGD08UBH+fn5+fn5qEf5+fn5qCiUqAj6/wMZGRkZGRIuGWSfAAAEAAD5R0dH
R0dHR1JSh3SRqKgwGzg45wAAp6enp6enp6enBgAAAYAAGRkZkaioMBs4OOcAAKenp6enp6enpwAA
AAGAABkZGRkSLhkZEi4ZZCEv5f//Jf9/ff/8DmB/7QAlC2Bg9PX2RwNTA0MDAwMDAwMDup+6urqA
AMwICAgIEEDgBwADAwMDAAD/AwMDAwMD4wIDAxAZGRsAACsqjo6kPDw8Rvr/AxkZGTw8AAABKBkA
/xsZAAD/f/8qG28AGwU=



==23039==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000ece7 at pc 0x7f82d5a5b063 bp 0x7ffc1a0a6db0 sp 0x7ffc1a0a6560
READ of size 616 at 0x61600000ece7 thread T0
    #0 0x7f82d5a5b062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x555ab13bf88b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x555ab13c035c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x555ab138eca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x555ab139a190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x555ab1388986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x555ab138d784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x555ab138dcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x555ab13887ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x555ab135e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x555ab135dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x555ab135d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x555ab135d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x555ab135d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x555ab135ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x555ab1318136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x555ab1315aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x555ab122bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x555ab122d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x555ab122b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x555ab1218f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x555ab13030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x555ab11e4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x555ab11e28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f82d52732b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x555ab11e1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000ece7 is located 0 bytes to the right of 615-byte region [0x61600000ea80,0x61600000ece7)
allocated by thread T0 here:
    #0 0x7f82d5ae0d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x555ab12f1d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x555ab138e574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x555ab139a190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x555ab1388986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x555ab138d784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x555ab138dcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x555ab13887ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x555ab135e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x555ab135dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x555ab135d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x555ab135d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x555ab135d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x555ab135ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x555ab1318136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x555ab1315aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x555ab122bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x555ab122d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x555ab122b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x555ab1218f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x555ab13030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x555ab11e4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x555ab11e28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f82d52732b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9d40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9d50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9d90: 00 00 00 00 00 00 00 00 00 00 00 00[07]fa fa fa
  0x0c2c7fff9da0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9db0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9dd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9de0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23039==ABORTING

INPUT
QBt///wOYADtACVLYGD08UBH+fn5+flHR0dHR0yHdKioqDAbODjnAACnp6enp6enpwAEAAD5R0dH
R0dHR0dMh3SoqKgwGzg45wAAp6enp6enp6enAAAAAaeyp6eUqL0nJx8nJyCqqAgI+v8ZGRkZGRkS
LhlkAwO6n7q6uoAAzAgICAgqQOAHAAMDAwMDAwMDAwMDAwMDAwMDEBkZGwBzAAX/fxzIzhLwEg4S
EhMAEszMf1cT4P1nZ63ADeB9HAAAEOAAAmQi



==23409==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000e6dd at pc 0x7ff016534063 bp 0x7ffd6cc64a50 sp 0x7ffd6cc64200
READ of size 606 at 0x61600000e6dd thread T0
    #0 0x7ff016534062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55a2c507288b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55a2c507335c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55a2c5041ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55a2c504d190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55a2c503b986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55a2c5040784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x55a2c5040cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55a2c503b7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55a2c501130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55a2c5010ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55a2c5010727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55a2c50107b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55a2c50107dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55a2c500fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55a2c4fcb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55a2c4fc8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55a2c4edec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55a2c4ee089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55a2c4ede11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55a2c4ecbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55a2c4fb60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55a2c4e97401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55a2c4e958da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7ff015d4c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55a2c4e94749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000e6dd is located 0 bytes to the right of 605-byte region [0x61600000e480,0x61600000e6dd)
allocated by thread T0 here:
    #0 0x7ff0165b9d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55a2c4fa4d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55a2c5041574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55a2c504d190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55a2c503b986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55a2c5040784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x55a2c5040cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55a2c503b7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55a2c501130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55a2c5010ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55a2c5010727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55a2c50107b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55a2c50107dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55a2c500fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55a2c4fcb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55a2c4fc8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55a2c4edec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55a2c4ee089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55a2c4ede11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55a2c4ecbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55a2c4fb60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55a2c4e97401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55a2c4e958da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7ff015d4c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9c80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9c90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9ca0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9cb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9cc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9cd0: 00 00 00 00 00 00 00 00 00 00 00[05]fa fa fa fa
  0x0c2c7fff9ce0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9cf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9d20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23409==ABORTING

INPUT
QBt///wOYADtACULYET0dKioqDkbODjnAACnpwAAp5inwqcAAAABJacnK0AAJ6qfAAAE/+n5R0dH
R0dkR0dMh3SoqKg5Gzg45wAAp6cAAKeYp8KnAAAAASWnpxOUGRkSLhlkAwO6n726uoAAzAgICBw1
HBwcHBzoAxwcHBwcHBwcHBwcGRsAcv///38cyM4S8BIOBRITABLMzH9XE+D9Z1utwP//fRwAABDg
AAJkIg==



==24074==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61a00001c7ff at pc 0x7fbe66c82063 bp 0x7fff7e1b9b10 sp 0x7fff7e1b92c0
READ of size 1408 at 0x61a00001c7ff thread T0
    #0 0x7fbe66c82062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x558b6d5bc88b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x558b6d5bd35c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x558b6d58bca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x558b6d597190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x558b6d585986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x558b6d58a784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #7 0x558b6d58acae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x558b6d5857cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x558b6d55b30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x558b6d55aee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x558b6d55a727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x558b6d55a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x558b6d55a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x558b6d559e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x558b6d515136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x558b6d512aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x558b6d428c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x558b6d42a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x558b6d42811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x558b6d415f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x558b6d5000f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x558b6d3e1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x558b6d3df8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7fbe6649a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x558b6d3de749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61a00001c7ff is located 0 bytes to the right of 1407-byte region [0x61a00001c280,0x61a00001c7ff)
allocated by thread T0 here:
    #0 0x7fbe66d07d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x558b6d4eed95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x558b6d58b574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x558b6d597190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x558b6d585986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x558b6d58a784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x558b6d58acae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x558b6d5857cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x558b6d55b30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x558b6d55aee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x558b6d55a727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x558b6d55a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x558b6d55a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x558b6d559e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x558b6d515136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x558b6d512aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x558b6d428c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x558b6d42a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x558b6d42811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x558b6d415f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x558b6d5000f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x558b6d3e1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x558b6d3df8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fbe6649a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c347fffb8a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb8b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb8c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb8d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb8e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c347fffb8f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00[07]
  0x0c347fffb900: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c347fffb910: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb920: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb930: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c347fffb940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==24074==ABORTING

INPUT
LbUAAlv/JHt7e3t71i8QGAACGy21AAJbEBgyGBUcGBgAAAQA0hj7FxsttQACARAYDBQQ//+AAACh
FCR7e3t7e94u+pYBGxsbKegDVP8BGxlgBHt7e3t7e3sQlvwAcQ7/IuAMFBCSljyAFH8bGxlUBBsb
GxtUAEArAJftlhAbGxsKGxSWFBsbAAAAQFT23teWUyQtlgAAECBTE/ogG94vVP8BGxlgBHt7e3t7
e3sQlvwAcQ7/IuAMFBCSlgCV/ZYQGxsb/3///yR7e3t7e94vFAABG/8bKgCh8QJ///IbkCEk+iAD
VP8bG28AGwIbUyQoeRv/GvpAFJQABAIbU+KVG1Sw3iYUvxQbGwAC/RYBGwMWAhoBExgZIhSJUxsv
GxsAAv1TGy8bVAQbGxsbPwBAKwCX7ZYQGxsbChsUlhQbGwAAAEBAAACD7ZYQGxsbKHkO/yLgDBQQ
GxsbKAAyZFFRUVH9/AD9ohD8AJYEGwL9UxsVAAAD6BlU//9//5YE3pYYGxob3i8UlhQaVGbnJof/
G4AAAAB7e/ogA1T/GxtTJAp5G/8aDBSUAAR7/3t7e/oMFJQABHsUGxsbKgChFA==



==24681==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60b00000a394 at pc 0x7f0644db5063 bp 0x7ffd0d51fe70 sp 0x7ffd0d51f620
READ of size 101 at 0x60b00000a394 thread T0
    #0 0x7f0644db5062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55aac2f3d88b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55aac2f3e35c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55aac2f0cca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55aac2f18190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55aac2f06986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55aac2f0bab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #7 0x55aac2f0bcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55aac2f067cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #9 0x55aac2edc30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55aac2edbee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55aac2edb727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55aac2edb7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55aac2edb7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55aac2edae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55aac2e96136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55aac2e93aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55aac2da9c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55aac2dab89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55aac2da911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55aac2d96f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55aac2e810f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55aac2d62401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55aac2d608da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f06445cd2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55aac2d5f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60b00000a394 is located 0 bytes to the right of 100-byte region [0x60b00000a330,0x60b00000a394)
allocated by thread T0 here:
    #0 0x7f0644e3ad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55aac2e6fd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55aac2f0c574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55aac2f18190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55aac2f06986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55aac2f0bab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #6 0x55aac2f0bcae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55aac2f067cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x55aac2edc30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55aac2edbee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55aac2edb727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55aac2edb7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55aac2edb7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55aac2edae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55aac2e96136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55aac2e93aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55aac2da9c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55aac2dab89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55aac2da911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55aac2d96f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55aac2e810f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55aac2d62401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55aac2d608da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f06445cd2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c167fff9420: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9430: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9440: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9450: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c167fff9460: fa fa fa fa fa fa 00 00 00 00 00 00 00 00 00 00
=>0x0c167fff9470: 00 00[04]fa fa fa fa fa fa fa fa fa 00 00 00 00
  0x0c167fff9480: 00 00 00 00 00 00 00 00 00 00 fa fa fa fa fa fa
  0x0c167fff9490: fa fa fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c167fff94a0: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c167fff94b0: fd fd fd fd fd fd fa fa fa fa fa fa fa fa 00 00
  0x0c167fff94c0: 00 00 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==24681==ABORTING

INPUT
GwPoB6d6LBohGQCA/zkZGRkZGbwAACcAgCkZGRkZ/zpQFxn5GRkZGRcXIGP6AAD6zlxqhDP8GQAB
S0sAAAAAS0scExlaYEpLS0tKOEsQS0tLS0pLL0tKPUsAAABAGRkZGRn6AAD6GRo7+s5caoQz/BkA
AUtLAAAAAEtLHBNQFxkZOxkZGRcXICw=



==24886==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61600000dd90 at pc 0x7f2f9ad94063 bp 0x7ffc119eda20 sp 0x7ffc119ed1d0
READ of size 529 at 0x61600000dd90 thread T0
    #0 0x7f2f9ad94062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55c45dea988b in _rl_find_prev_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d88b)
    #2 0x55c45deaa35c in _rl_find_prev_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e35c)
    #3 0x55c45de78ca1 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22cca1)
    #4 0x55c45de84190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #5 0x55c45de72986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #6 0x55c45de77ab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #7 0x55c45de77cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #8 0x55c45de727ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #9 0x55c45de4830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #10 0x55c45de47ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55c45de47727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55c45de477b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55c45de477dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55c45de46e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55c45de02136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55c45ddffaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55c45dd15c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55c45dd1789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55c45dd1511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55c45dd02f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55c45dded0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55c45dcce401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55c45dccc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7f2f9a5ac2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55c45dccb749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61600000dd90 is located 0 bytes to the right of 528-byte region [0x61600000db80,0x61600000dd90)
allocated by thread T0 here:
    #0 0x7f2f9ae19d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c45dddbd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55c45de78574 in expand_prompt (/home/dualbus/src/gnu/bash-build/bash+0x22c574)
    #3 0x55c45de84190 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238190)
    #4 0x55c45de72986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55c45de77ab7 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22bab7)
    #6 0x55c45de77cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55c45de727ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55c45de4830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55c45de47ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55c45de47727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55c45de477b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55c45de477dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55c45de46e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55c45de02136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55c45ddffaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55c45dd15c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55c45dd1789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55c45dd1511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55c45dd02f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55c45dded0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55c45dcce401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55c45dccc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f2f9a5ac2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c2c7fff9b60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9b70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9b80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9b90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9ba0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c2c7fff9bb0: 00 00[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9bc0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c2c7fff9bd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9be0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9bf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c2c7fff9c00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==24886==ABORTING

INPUT
E9AYAAA1BSAAAABcGyEKGGQALx01BRsAGBpcGyGAGIAfHx8fbFHnaoxWIjajIQcYJCQkASQkpCQk
JCQkJCQkJCQkJIAAL/+AG/8YGJP7fwCAAPxWIjajIQQYgAAvbBshkBiAHx8A/2CAWx4EWx4AAAAh
fQRAf/wZAPyOABzIBEAA+h9aPQh/ODw9IBAABEALAAIAGCQkJAEkJKQkJCQkJCQkJCQkJCSAAC//
gBv/GBiTgDx//BkQADwAQwD8jjwZEAA8/yokUo6kPBlW0QAcyARAAAMVGVY8KCooKCgoKCgoKPyN
6AYAAAEAAAAeHhgZnGA8Iz0LQCYZEABkHjkA/B4eHhkBAAAAAEDr6+vr6+va6/wA/I3oBgAAAQAA
AAQDPP8qJFKOpDwZVtE1////AP9gBFseBFseACAAAX0EQH8SGRDaGwU=

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Wed Jun 14 12:04:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLAmi-0000A9-Vr
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 12:04:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54218)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLAmf-00007V-EQ
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:04:43 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLAmc-0004tE-34
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:04:41 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:44064
	helo=homiemail-a122.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dLAmb-0004qe-NJ
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:04:38 -0400
Received: from homiemail-a122.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a122.g.dreamhost.com (Postfix) with ESMTP id EAE7860001108;
	Wed, 14 Jun 2017 09:04:35 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=GFIcd26nDKLpDGdaTUuRAgWvC/E=; b=
	1I6n6aUnASwyxaGsklVIQ0A8+xdNW4AXDpxAmHUSmtMbu461Ow6gwBZkqkJ6kxAj
	llTypO4NOeYSuAlMuAUNfRQA30DgyAqori5sOI+jc8ILMBzulJJnDYwy5yRqICgg
	BJD+QD6j3A/xX7hJvhU7ZKu8/9oWbhKzZyRoC91hTfU=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a122.g.dreamhost.com (Postfix) with ESMTPSA id
	DF0FA60001105; Wed, 14 Jun 2017 09:04:35 -0700 (PDT)
Message-Id: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Greg Wooledge" <wooledg@eeg.ccf.org>,
 "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: &lt;20170614124314.GB22519@eeg.ccf.org&gt;
Subject: RFE: Fix the name collision issues and typing issues with namerefs,
	improve various issues for function libraries
Date: Wed, 14 Jun 2017 12:04:35 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 16:04:43 -0000

=0AThis is relevant to my interests!=0A=0ASo first off, the circular ref=
erence problem with "declare -n"=0Aapparently doesn't exist in Korn Shel=
l: If you "typeset -n x=3D$1", and=0A$1 is "x", it's not a circular refe=
rence. The nameref seems to take=0Athe origin of the name into account w=
hen creating the nameref: If $1=0Ais used to provide the name for a name=
ref within a function, then the=0Anameref refers to a variable in the sc=
ope of the function's caller.=0ABut if the name for the nameref is taken=
 from another parameter, or a=0Astring literal, then the variable is dra=
wn from the scope of the=0Afunction itself. It seems a little "black mag=
ic" in a way but it has=0Athe benefit of neatly matching some important=
 common use-cases. I=0Athink Bash should either adopt something similar,=
 or provide another=0Amechanism to exclude function-local variables from=
 nameref=0Aconstruction.=0A=0A...And I could be wrong here (as I haven't=
 used namerefs much in bash)=0Abut it seems you can't use a nameref to c=
hange the type of a=0Avariable...=C2=A0 For instance if "x" is local to=
 f1, and f1 calls "f2 x",=0Aand f2 declares a nameref that resolves to i=
ts argument "x", f2 cannot=0Athen change "x" to an associative array, fo=
r instance. The caller has=0Ato declare the variable with the proper typ=
e before passing it into=0Athe function as a nameref.=0A=0ARegarding ret=
urn values, there's a couple ways of looking at this:=0A=0AFirst, a comm=
on way of dealing with the situation is to have functions=0Aemit their r=
esults to stdout, and then capture the data with command=0Asubstitution.=
 This is a bit problematic because command substitution=0Aoccurs in a su=
bshell environment. (This is actually mandated in Posix,=0Ait seems - wh=
ich is unfortunate, because there's actually no need for=0Ait to be a su=
bshell environment! In Korn Shell, it's not...=C2=A0 Command=0Asubstitut=
ion is evaluated in the main shell environment - which struck=0Ame as od=
d at first, but it actually makes sense for these kinds of=0Ascenarios,=
 where you want to run something that has a side-effect, and=0Acapture i=
ts output.)=C2=A0 This means a function call or built-in can't=0Acreate=
 side-effects in the shell environment (setting environment=0Avariables=
 or open/close files) AND emit a result on stdout for=0Acapture. It's st=
rictly one or the other.=0A=0ASecond, with namerefs in the picture, one=
 could use them to tell a=0Afunction where to store its return value. It=
 doesn't look "functional"=0Abut it gets the job done, right? But again,=
 there's the various=0Aproblems with namerefs in Bash presently. Name co=
llisions can lead to=0Acircular references, and the type of the var can'=
t be changed using=0Athe nameref.=0A=0AFinally, of course...=C2=A0 Funct=
ions could simply "return" values by=0Apopulating a variable in the call=
er's scope. I don't think it's a=0Agreat solution=0A=0AAnd finally, with=
 respect to creating Bash "libraries" of functions:=0AThe problem of nam=
espace pollution could be largely solved by=0Asupporting some form of na=
mespaces to contain the declarations that=0Aare needed only locally. (Cu=
rrent versions of ksh have a whole OO=0Asystem, meaning a library's foot=
print in global namespace can be very=0Asmall!)=0A=0A----- Original Mess=
age -----=0AFrom: "Greg Wooledge" <wooledg@eeg.ccf.org>=0ATo:"bug-bash"=
 <bug-bash@gnu.org>=0ACc:=0ASent:Wed, 14 Jun 2017 08:43:14 -0400=0ASubje=
ct:Re: RFE: Please allow unicode ID chars in identifiers=0A=0A On Tue, J=
un 13, 2017 at 04:58:59PM -0700, L A Walsh wrote:=0A > Forgive me if I'm=
 misremembering, but hasn't Greg argued against=0A > the ability to supp=
ly "libraries" of re-usable scripts due to=0A > the ease with which name=
s could conflict with each other and cause=0A > script incompatibilities=
?=0A=0A Namespace collisions are certainly an issue, yes. But my primary=
=0A argument against trying to write "libraries" in bash has always been=
=0A the limitations of bash's functions.=0A=0A 1) You can't return value=
s from them (making them more like=0A"commands"=0A than actual functions=
).=0A=0A 2) You can't pass variables by reference. Therefore:=0A=0A 3) Y=
ou can't pass the name of a variable in which you'd like to=0Areceive=0A=
 a value from the function, to work around point 1.=0A=0A 4) You can't p=
ass an array by name. You have to pass every single=0Aarray=0A element s=
eparately, losing the indices in the process.=0A=0A "declare -n" looks l=
ike it should address point 2, but it doesn't=0A do so safely. It only w=
orks if you magically choose a name (within=0A the function) that the ca=
ller does NOT choose (outside the function).=0A In fact, the caller's va=
riable name must not match ANY local variable=0A of the function, or it=
 breaks.=0A=0A See examples at=0A<http://mywiki.wooledge.org/BashProgram=
ming#Functions>.=0A=0A If your function is recursive (is its own caller)=
, then you're simply=0A doomed -- you can't avoid having the same name u=
sed in the caller and=0A callee, because they're both the same piece of=
 code. You might be=0Aable to=0A hack up a global indexed array of retur=
n values, and then each=0Ainstance=0A of the recursive function can use=
 its recursion depth as an index=0Ainto=0A this array to retrieve its re=
turn value. That's the best I can think=0Aof.=0A=0A

From MAILER-DAEMON Wed Jun 14 12:06:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLAoR-0001mc-A7
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 12:06:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55853)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLAoP-0001iJ-Bb
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:06:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLAoM-0005xP-28
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:06:29 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:3253
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLAoL-0005x2-SX
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:06:25 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMD60712; Wed, 14 Jun 2017 12:06:24 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFX54647 (AUTH cpr);
	Wed, 14 Jun 2017 12:06:24 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: AddressSanitizer: heap-buffer-overflow
	_rl_find_prev_mbchar_internal / expand_prompt
To: Eduardo Bustamante <dualbus@gmail.com>
References: <20170613151431.ka6rw6tnjaavtyco@debian>
	<ca83aa09-ad60-3753-e7fe-25722392ecaf@case.edu>
	<20170614151924.ucgxwya2h5izvuof@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <e678638d-095b-e617-d734-99105c6836b1@case.edu>
Date: Wed, 14 Jun 2017 12:06:24 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170614151924.ucgxwya2h5izvuof@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.14.152116:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_1100_1199,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 16:06:30 -0000

On 6/14/17 11:19 AM, Eduardo Bustamante wrote:
> On Tue, Jun 13, 2017 at 04:30:23PM -0400, Chet Ramey wrote:
> [...]
>> I can't reproduce it with asan or without on Mac OS X. I'll look around
>> for a Linux system with asan to run it on.
> 
> All these inputs seem to trigger the same problem. You'll find the
> stacktrace as reported by ASAN first, and then the corresponding input
> base64 encoded.

OK. I finally got it on a Fedora 25 VM. It's an easy fix:

*** display.c	2017-06-09 17:03:59.000000000 -0400
--- /Users/chet/display.c	2017-06-14 12:02:37.000000000 -0400
***************
*** 467,472 ****
--- 467,473 ----
  	      if (physchars > bound)		/* should rarely happen */
  		{
  #if defined (HANDLE_MULTIBYTE)
+ 		  *r = '\0';	/* need null-termination for strlen */
  		  if (mb_cur_max > 1 && rl_byte_oriented == 0)
  		    new = _rl_find_prev_mbchar (ret, r - ret, MB_FIND_ANY);
  		  else


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 14 12:18:22 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLAzu-0007jc-8Q
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 12:18:22 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33435)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dLAzs-0007jP-6d
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:18:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dLAzp-0002sG-Iw
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:18:20 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:36559 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dLAzp-0002rP-BA
	for bug-bash@gnu.org; Wed, 14 Jun 2017 12:18:17 -0400
Received: (qmail 12676 invoked from network); 14 Jun 2017 16:18:15 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Wed, 14 Jun 2017 12:18:15 -0400
Received: (qmail 24287 invoked by uid 563); 14 Jun 2017 16:18:15 -0000
Date: Wed, 14 Jun 2017 12:18:15 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
Message-ID: <20170614161815.GE22519@eeg.ccf.org>
References: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 16:18:21 -0000

On Wed, Jun 14, 2017 at 12:04:35PM -0400, tetsujin@scope-eye.net wrote:
> So first off, the circular reference problem with "declare -n"
> apparently doesn't exist in Korn Shell: If you "typeset -n x=$1", and
> $1 is "x", it's not a circular reference.

Korn shell actually has two different *kinds* of functions.

If you declare using:  foo() { ...; }

Then you get bash-like behavior.

If you declare using:  function foo { ...; }

Then it works as you described.

$ ksh
$ foo() { typeset -n x="$1"; x=y; }
$ x=global
$ foo x
ksh: typeset: x: invalid self reference
$ function bar { typeset -n x="$1"; x=y; }
$ bar x
$ echo "$x"
y

As far as I know, bash has no equivalent of ksh's "function foo"
declaration.  Bash permits that *syntax* to be used as a function
declaration, but it has exactly the same semantics as "foo()".

> Regarding return values, there's a couple ways of looking at this:
> [...]

You're retracing a lot of the ground I've already covered in the last
few years.  Which is cool, and I'll be happy if you find something
that I missed.


From MAILER-DAEMON Wed Jun 14 15:04:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLDav-0000zP-Ld
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 15:04:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44273)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLDat-0000zG-R4
	for bug-bash@gnu.org; Wed, 14 Jun 2017 15:04:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLDaq-0003ub-M6
	for bug-bash@gnu.org; Wed, 14 Jun 2017 15:04:43 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:43137
	helo=homiemail-a69.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dLDaq-0003u4-AE
	for bug-bash@gnu.org; Wed, 14 Jun 2017 15:04:40 -0400
Received: from homiemail-a69.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a69.g.dreamhost.com (Postfix) with ESMTP id 01E6448000B39; 
	Wed, 14 Jun 2017 12:04:39 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=5dK+juWFcuAM8ShhH/dRCQjp/P0=; b=
	DsLPbILW5Qc9vsDB9WnKU7pCkZI7ouxZbnrFqSExxkycGcvG1hJlPmC25lC8TKu9
	objxns24cAA84pZ1CqqPu8Cu6zv+7NJVW2cJYV+1yYisSt1IDSZclW99kHcMrzuC
	8v8hVZRXT4zPtVw2e1U3Rpj3QZYuOx2Et8tkEZQDvXw=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a69.g.dreamhost.com (Postfix) with ESMTPSA id
	ED4EF48000B35; Wed, 14 Jun 2017 12:04:38 -0700 (PDT)
Message-Id: <4b856a1dcb24d7eb4064a97cc61012418b35bfe0@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Greg Wooledge" <wooledg@eeg.ccf.org>,
 "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <20170614161815.GE22519@eeg.ccf.org>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
Date: Wed, 14 Jun 2017 15:04:38 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 19:04:44 -0000

=0A=0AYeah I didn't really consider ksh's "backward compatible" function=
=0Asyntax in my post because using that form while looking for better=0A=
support for function libraries would be a needless handicap. You don't=
=0Aeven get local variables with the backward-compatible syntax, so=0Ath=
ere's no hope of getting around issues like nameref collision.=0A=0AInde=
ed, much of what I had to say about returning values from=0Afunctions wa=
s on your site. I included the information mainly to=0Aprovide some cont=
ext to the feature request.=0A=0A----- Original Message -----=0AFrom: "G=
reg Wooledge" <wooledg@eeg.ccf.org>=0ATo:"bug-bash" <bug-bash@gnu.org>=
=0ACc:=0ASent:Wed, 14 Jun 2017 12:18:15 -0400=0ASubject:Re: RFE: Fix the=
 name collision issues and typing issues with=0Anamerefs, improve variou=
s issues for function libraries=0A=0A On Wed, Jun 14, 2017 at 12:04:35PM=
 -0400, tetsujin@scope-eye.net=0Awrote:=0A > So first off, the circular=
 reference problem with "declare -n"=0A > apparently doesn't exist in Ko=
rn Shell: If you "typeset -n x=3D$1",=0Aand=0A > $1 is "x", it's not a c=
ircular reference.=0A=0A Korn shell actually has two different *kinds* o=
f functions.=0A=0A...=0A If you declare using: function foo { ...; }=0A=
=0A Then it works as you described.=0A...=0A=0A > Regarding return value=
s, there's a couple ways of looking at this:=0A > [...]=0A=0A You're ret=
racing a lot of the ground I've already covered in the last=0A few years=
. Which is cool, and I'll be happy if you find something=0A that I misse=
d.=0A=0A

From MAILER-DAEMON Wed Jun 14 17:04:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLFSh-00069G-LK
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 17:04:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41508)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLFSf-000699-Od
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:04:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLFSc-0007dT-JI
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:04:21 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:47390
	helo=homiemail-a69.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dLFSc-0007cx-6v
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:04:18 -0400
Received: from homiemail-a69.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a69.g.dreamhost.com (Postfix) with ESMTP id 7379848000B35; 
	Wed, 14 Jun 2017 14:04:13 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=3jantPjZoIdGQcvNui/NZG0v2eQ=; b=
	TXeEQVNoFTiK+UqvJQ49f5tYp6Y+AGnFm9S43DjhSbX+35XqB+FnBzSmbg2K7uqx
	WnDDqq+r0Yq4BTj0+vk59wom0dTvRVWn7eD2ZEzNuHKHK6PRAyK7nI43HLnh6BQC
	+p0vpqzac1EJEzOG5HLOPZTtgx0ZoTdIpjM/Cx1rtkI=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a69.g.dreamhost.com (Postfix) with ESMTPSA id
	683E448000B33; Wed, 14 Jun 2017 14:04:13 -0700 (PDT)
Message-Id: <5c96ee86e5e5a995b1222b7467970752dc63926e@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: tetsujin@scope-eye.net, "Greg Wooledge" <wooledg@eeg.ccf.org>,
	"bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
Date: Wed, 14 Jun 2017 17:04:13 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 21:04:22 -0000

=0AI should add the related problem:=0A=0A$ f() { declare -n x=3D$1; ech=
o "x=3D$x"; declare y=3D"local Y"; echo=0A"x=3D$x"; }=0A$ y=3D"global Y"=
=0A$ f y=0Ax=3Dglobal Y=0Ax=3Dlocal Y=0A=0AIn other words, even if you d=
o get a nameref to point to something in=0Athe caller's scope, as soon a=
s you shadow that variable with another=0Alocal variable, the nameref po=
ints to that one instead.=0A(As Greg pointed out, the name ref basically=
 fails if the referenced=0Aname is shared with any local variable in the=
 function.)=0AThis is arguably in line with the name of the feature ("na=
meref", i.e.=0Areferencing the variable by name rather than by specific=
 identity) but=0AI feel it's much more useful for a variable reference,=
 once=0Aestablished, to be stable.=0A=0ATo sum up a bit:=0A=0A- There sh=
ould be a way to declare a nameref locally in a function=0Awhich reliabl=
y refers to a variable in the caller's scope - IMO this=0Ais the whole p=
oint of having a reference type, to get around the fact=0Athat the langu=
age is otherwise pass-by-value.=0A=0A- A nameref, once established, shou=
ld refer to a particular name _in a=0Aparticular scope_. Shadowing the r=
eferenced variable with a new local=0Ashould not cause the nameref to sw=
itch to the new definition.=0A=0A- Because Bash can create global namere=
fs from within a function,=0Acreating a global nameref to a function-loc=
al variable should not be=0Aallowed (because the global nameref would ou=
tlive the declaration it=0Areferences)=0A

From MAILER-DAEMON Wed Jun 14 17:53:09 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLGDs-0006VD-QC
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 17:53:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49833)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLGDq-0006Ua-4M
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:53:07 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLGDm-0003YE-4x
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:53:06 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:38038
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dLGDk-0003Vi-V2
	for bug-bash@gnu.org; Wed, 14 Jun 2017 17:53:02 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5ELqh74019359; Wed, 14 Jun 2017 14:52:45 -0700
Message-ID: <5941B02B.7000801@tlinx.org>
Date: Wed, 14 Jun 2017 14:52:43 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Greg Wooledge <wooledg@eeg.ccf.org>, Chet Ramey <chet.ramey@case.edu>
CC: bug-bash <bug-bash@gnu.org>
Subject: people working in Greg's locale (+euro) & display of Unicode names
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>
	<20170602121541.GP7764@eeg.ccf.org>
In-Reply-To: <20170602121541.GP7764@eeg.ccf.org>
Content-Type: multipart/mixed; boundary="------------050805050408090707050208"
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 14 Jun 2017 21:53:07 -0000

This is a multi-part message in MIME format.
--------------050805050408090707050208
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

Greg Wooledge wrote:
> Here is a demonstration of the cost of what you are proposing. In my
> mail user agent, your variable shows up as L??v.
>   
iso8859-15 was introduced in 1999 to replace iso8859-1 as it didn't
have the Euro symbol.  I can set my system to use iso8859-15,
but not "-1".  If you had a charset installed that displayed
"U+0113 LATIN SMALL LETTER E WITH MACRON", you'd be able to
see it. 

It *is* a latin character, similarly, Microsoft
refused to move beyond Unicode V2 for over 20 years because
versions above that didn't fit in 65536 characters, which
meant MS's 2-byte/character encoding would no longer hold
the world's languages.  MS had heavily tied their software
into that encoding.  Their kernel SW uses it. You can see
it in use in their log files, which are still UCS-2 encoded
(no BOM at the beginning of the file & encoded Little Endian).
> Source code with your UTF-8 identifiers would no longer even be READABLE
> on systems that do not use UTF-8. 
----
    It's not a matter of a system not using UTF-8, but
being a system that's come out in the past ~10 years.  I know
MS from WinXP and above supported Unicode to some degree, and
current linux distros have for the past 10-15 years. 
>  Like the system I am using RIGHT NOW, which uses Latin-1: [i.e]:
> $ locale
> LANG=en_US.iso88591
> LC_CTYPE="en_US.iso88591"
> LC_COLLATE="en_US.iso88591"
> LC_MONETARY="en_US.iso88591"
> LC_NUMERIC="en_US.iso88591"
> LC_TIME=POSIX
> LC_MESSAGES="en_US.iso88591"
I only have iso885915 to use.

Chet Ramey wrote:
> But people don't work in Unicode. They work in their own locale.
----
    Ok, I have my locale set to latin9 (iso8859-15).

Attached is a pic of how files display in a console
and how they display in vim.

> That locale may be consistent with Unicode, and it may not.  Adding
> something that doesn't respect a user's locale isn't useful.
>   
What do you mean by respect?  I am running in the locale and
characters from other locales still display correctly.

Isn't that respecting both the local locale as well as
the one being displayed?

How is having UTF-8 for files and text not showing
respect?

-linda





--------------050805050408090707050208
Content-Type: image/jpeg;
 name="latin1+Jap-display1.jpg"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
 filename="latin1+Jap-display1.jpg"

/9j/4AAQSkZJRgABAQEAeAB4AAD/2wBDABALDA4MChAODQ4SERATGCgaGBYWGDEjJR0oOjM9
PDkzODdASFxOQERXRTc4UG1RV19iZ2hnPk1xeXBkeFxlZ2P/2wBDARESEhgVGC8aGi9jQjhC
Y2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2P/wAAR
CAUTArMDASIAAhEBAxEB/8QAHwAAAQUBAQEBAQEAAAAAAAAAAAECAwQFBgcICQoL/8QAtRAA
AgEDAwIEAwUFBAQAAAF9AQIDAAQRBRIhMUEGE1FhByJxFDKBkaEII0KxwRVS0fAkM2JyggkK
FhcYGRolJicoKSo0NTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqDhIWG
h4iJipKTlJWWl5iZmqKjpKWmp6ipqrKztLW2t7i5usLDxMXGx8jJytLT1NXW19jZ2uHi4+Tl
5ufo6erx8vP09fb3+Pn6/8QAHwEAAwEBAQEBAQEBAQAAAAAAAAECAwQFBgcICQoL/8QAtREA
AgECBAQDBAcFBAQAAQJ3AAECAxEEBSExBhJBUQdhcRMiMoEIFEKRobHBCSMzUvAVYnLRChYk
NOEl8RcYGRomJygpKjU2Nzg5OkNERUZHSElKU1RVVldYWVpjZGVmZ2hpanN0dXZ3eHl6goOE
hYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4uPk
5ebn6Onq8vP09fb3+Pn6/9oADAMBAAIRAxEAPwDRnnO/yUOXPX2FX7uZdJ0g4/1hGcep7Cs/
QLczSG4lJIU7snuaq6hdnU9UhiU5jaYBf90d/wA813Td9DiSsX9TDx6NbWYOZbllU+/c1jMy
vrpCfdXci/QDAra1WTGsQjtbRFvxxn/Cud0rMurKe2G5/A1n0NEVvEOs6jpuptb2l00URRHK
hR1KKCensKzP+Eo1r/n/AJP++V/wq34tcQeJA7RpIFijOx84Py98VTvtsmkQzzW8MNw8h8vy
0Cbo8dSB79DWDXU6I7C/8JRrX/P/ACf98r/hR/wlGtf8/wDJ/wB8r/hSSC0fw+7wW+yRJkVp
HO5myDn6D2rJpNDNf/hKNa/5/wCT/vlf8KP+Eo1r/n/k/wC+V/wpuiR70vWCQtIkOUMwUqp3
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
xIQ+0/8Ajuf0q3b6pFDFNEdPg8uZdrBXcH2PLEcfSoNMjie8V7h1WGL94+T94DsPUnpR1DoW
NYsba1uHSG5hBRVBiG8sWwM8kY689ainsomsxd2jsyLgTRv96M+vuD60+eFJv9Nvbgxm5ZmV
Uj3nGep5GBVnxBZSfaXuo2WWEKgYqeU+UY3DtmjoBFaagbiNbS8aNkxw08kpXPYEB8Ae+KsS
pZWKn7fY2zSsuUigkkOR2YtvIx+Z+lZq6pqCKFS+uVUDAAlYAD8617/VJ7fVQZbq7MSxIwjj
lIDNtHXngetMDI023iu7zy5dwj2O5CHB4BOMnPpWhaW1klzDJJbgoHUkNfwuMZ7qFyfpUNrd
y3moXMzAyXc8bLGBgDJGDz2AGavS3WbJhK7xiW2TCG4yoXIBKrtHPy5xnvQu4Mo6pFAkUgjs
pIvKmaPzTKpyc5xjaKyq6HU7qK5snmktp1KL5SbwuCTg7z3BIHpz61iG0nFmLsxHyC2wP2zU
2sMlsrJbiKeaabyYYQNzBdxJJ4AHFSWdla3d+LZbuQByBG4hzkn1G4Y/WrWnXlzDoV8IriVN
jR7Nrkbck5x6VX0aRn121klcszSglmOSTTW9iXsZ7rtdlznBxSVoWdnJNrEcLFoS0hw2ORg9
vfir9/Mt1o0rOLktBcKga4YMwBBzzgY+nNJbXKe9jAorc1e4vLW4Ftal4rMoPKEYwsi7eT/t
Vh0CCiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiii
gAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAK
KKKACiiigAooooAKKKKAL2aUGkpR1qjMd9O9atha+SVZ/vsCSPTiobK3EeJZPvdh6VaWbdP1
7H+VIpIy/E3/ACFR/wBcY/8A0EVl+Y/liPe3lg7tueM+uK2NXge81yKFOrxR8noBsGTS6lNF
JocS26BYYrlkTjlhtHJ9zS6FGaNRvli8oXlwIwNuwStjHpjNVq3Le7uH0y5lvmBtDGY4oyoA
L9to9u5rJgtLm5DG3t5ZQv3iiFsfXFNgLZwR3FwsctxHbqSAXcHH6f1xWjIjiyS2t9RtZfNf
yzFFFtZsEYyduT17/rVTSZ2t7pmUctGy584REZ7hj3ro5LySHULaMfvA7QnMl0sm3jHC9c89
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
ism5uGuWDNHEhHH7uMID+Ap8eoXcd290kzCZ87m4+bPXI6Uy4uZLkqZNg29AkaoPyAFLoMho
oooEFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFF
ABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAU
UUUAFFFFAG1RmmZpQasQ/NER/eH/AHT/ACptOi/1h/3TQIg1SF7jVYoYhl3iiAH/AAAVLqMd
omjxC1jUmOdozNjmTCgk/TPQUzUrmW01VJoGCuIIxkqG6oAeDUU+qGfSRatHGJPNLkrCijGB
0wOtS9iluWriOU2ETWUdnJEluDNtSNpAe5P8Q+tYladtdWNl5k0H2iSZoyiq6qFXIwSSDz+Q
qlBd3NsrLb3EsQb7wRyufrih7gti1o0UbXTzzoHht4zKysOGx0H5kVJqNkj6xHHbgRxXex4+
OFDf4HNRWeoC0sLiONQZ5mXJdFddoz2Oec+1THVY5X06WZD5tq/z7EVQVzkYAwM9aemgiteW
1tAzxxXMksqPtIMW0H1wdx/lVg6Ooka2+1A3qpvMOzjpkruz1x7fjVC4lEl3LMmQGcsM9eua
1rvWvtQMv2zUIZGXBiR8x5x2ORge2DUrYrqVoNNge1t5ri7MJuHZEAi3AY9Tnioo7A/2hJaS
+bvjJB8mLzCSD2GRSveRtY2UAVt0DszHHByQePyqz/alu91qJcTJFeHh0xvXnPTPI9RmnoIq
anp7afKilmZZE3qWQo3pyD0NU6valdQ3EdrFAZCsEezdIACeSegJ9aivXs3aP7FFJGojAcOc
5buaQGvJPDY6PZ/ZbueIyb2JWBf3hBx83zdPzqrp9xM+k6jC0rmJYgVQtwDvHQVUubpJrCzg
UMGgDhiehyc8U7TrqGBbmK4D+XPHsLIASpyCDg9elPuHYisrcXU/lnzemQIovMY/hkVauNGm
jv4LWNi3nruQuhQgc53A9MYNJZ3ltbi7gzOIJ1CiRQN64OemcYPpmpW1WKG5sXt1kkW1jMZ8
0BS4JOehOODRoBUuoLOJSILxp3BwR5W1T9Dn+lVKtXQsMM1q9xuJ4SRFwv4g8/kKq0hhRRRQ
IKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACi
iigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAoooo
AKKKKACiiigAooooAKKKKACiiigDXApwFAFLViDFOiH7w/7ppKdF/rT/ALp/lQxFPXP+P9f+
uMf/AKAKS80t7PT4bmSUeZI20xAcpxkZPrg9KtXklvDrkMt0rNGkUZwoBydgxwSO9LeNBJoQ
lFxNKzXTNl4guTgZz8xqehSKMlglvarJdXAjlkXdHCq7mI7E9hVKupuv9KuZppoIG05oNyz7
FBB28YbrnPGK5yBrZVb7RFLIf4dkoTH1ypzQ9wWxJY2ZuzIzSCKGJd0kjDO0fTuabPDCHjW0
maff2MZVgfTGT+lXNLAubG9skYCaXY0YJxu2nkZ9eaZaaa8WpW0WoK1ukh7naf8A63NFgKc9
rcW2PtEEsW7pvQrn86ctjdvF5qWs7R4zvEZIx9a2b9JE0KZJbI2oW4Xy1LMcjB5G4n8xVPWn
YPZAMcC0jxz0yOaTApRWd1PGZIbaaRB1ZEJH51HFFJNII4o3dz0VQSfyrWMskWl6S0bspE0h
BBx3FXlERvdZgRHM7yfKkcgjZlycgEg+3HenYDnTbXAmMJgk80DJTYdw/CmLHIyM6oxRMbmA
4XPTNbFxfSWt9YPJazQNbrg+c+53QnoeB2yKNWij060+xxOG+0SecSD/AAfwf1NAGW1ncrAJ
2tphEeRIUO386s2ttbXGnXUhWZZ4EDZ3ja2WA6Yz39a24LcW8kqQ2pa0a1b/AEouxD/J9dvX
jGKyNHRprbUIIxulkhGxB1bDAnFFugeZnxRSTSBIo2kc9FUZJolikhkMcsbRuOqsMEfhWzpE
flwX9o8cn2shQI0kCOwzyASD7cVV1iV2FtFJazQNFHgec+52GeM8DpzQwM2tlNH8mwjuLq1v
naTJIiTAjUdzkH+lZ97Yy2LRrKUJkjEg2Nng1Z1Ak6PpnP8ADJ/6FQAy2trW40+6k2zLNAgY
HeNrZbHTGe/rVSGCa4fZBE8r9dqKWP6Vf0dGmttQgjG6WSEbEHVsMCcU7TLL5rtZYDLcwqNl
vvK7jnnpycegosBmyRSQyGOWNkcdVYYI/Cny2dzDGJJbaaOM9GZCAfxroJZEj1TSXu4xAwh+
YOSdjZbbndk9cdayL+11KMySXizFSRmRjlW9MHoaGBQooopAFFFFABRRRQAUUUUAFFFFABRR
RQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUA
FFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAFFFFABRRRQAUUUUAbI6UtAHt
jHUHtS4qyQpYv9Yf90/yoxSRf6w/7poYFXXP+P8AX/rjH/6AKomKQRCUxsI2OA+Dgn0zWtd2
bX2tw26Z+aKPJAyQAgJqxqy3L6Ihe0lgiiuCERoyNibQBn6nv61LWlykZP8AZeobd32C624z
nyWx/KqlalmzWWkz3YJEs7eRGfQdWP8AIfjVGC1kuFYo0QC9d8qJ+W4jNJgRrHI6O6IzKgyx
AyF+tDxSRhS6MocZUkY3D1Fa+jPHFYXhnbbDIyRO2M4BDc/gcH8Km1BP7QfThbIJEJaJATtB
VTxn04p2AwKK2ruytGsPPh8gSRzLG/kO7KQc/wB76djV1tP01rgwLaBSbhoMiVsgBchuvXP4
UWA5iit6C1sUsEaW1WST7O024yMNxDYxgHpUT6fHHqVzsiiNtEqsfPdgqbgCOV5PpRYDGorR
1i1gga3kttojni34ViVByRwSAe3es6kMtW+nXVzD5sUY8snaGZ1XJ9Bk8/hSLYXD2r3KqhjQ
ZbEi5XnHK5z+laN/cxf2Np4+xQfMsmPmf5fm6j5v55qvpn/IP1P/AK4r/wChimIzaKu6Zbec
0sjxwtDEuXaZmVVyePu8k1fl0u2m1KySFgsNxGZG8tiwGM52lhnt3osBh0Vburi1kUrb2Sw4
PDeYzN+OTj9KqUhhRRRQIKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKK
KACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigA
ooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigDu9U0xLnM0WEm7ns31/xrBIKs
UdSrLwQe1dgw4rN1GxS5G4fLIOjU07G9SF9UYJpIv9af900rq8bmORdrjtSRf6w/7pqjnKeu
f8fy/wDXGP8A9AFVjdSGyW0wvlrIZAe+SMVb1hGl1KNEBZmiiAA7naKk1GytLbS4zDl51mMc
smeCQASAPQZqRooS3Ty2sFuQoSHdtwOTk5Oagrfk022RXQ2rCBbfzFvd5wzYz9MZ4x1rApPc
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
yDgc4ptWRMal58t+5i1uaBpsUoe6lltH2xsyxSP90joXH92s680+aygtpZWQrcJvXaTkDjrx
71a0L/mIf9eUn9KFo9R1HzQvFkmqTeTJbv5ekybWLYtRkHpww9KS/ljutEiufsttBJ55Q+TH
tyNtY9acn/ItRf8AX03/AKCKL3TDl5eX+u5DZaa93GZDcW0CZ2gzybdx74/MfnTLnT7i2vvs
bpumyAoXndnpitCy0zztMS5t4I7qQsRKJJdqxAfQjr161evCtn4gsb2XZ9lZAqyK2V+7jI9h
kU+XYl1XzNLz/Ayp9Elgjcvd2fmIu5oRN844yRj1rMrVudBv4xJOQkkABfzxIuGHXPXNZVSz
WDut7hRRRSLCiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKK
KKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiigAooooAKKKKACiiig
AooooAKKKKACiiigDVXrTz0pqU5ulaiGUUUUALTof9Yf9002nQ/6w/7poAsa5/yCov8Arqn/
AKJWsZLO4e0e6WM+QhCs+RjP9a6K9s5L+2traPAZ5k5PYeSuTT5dPv30u8thamOIbBBGXU8A
kknnqepqOXqZTqqLSOVjjeWRY41LOxwAOpNPubeW1naCddkidRkHH5VsaXpl6tj9stId80uV
jbco8tehbk9T0HpzTPEVnMNbLSbY0uGAR3YY6AEn0FDjZAqqc+Uxae0brGkhHyPnaevTqPr7
e49avy6P5UTyf2jp77VJ2pPkn2Ax1qO3t1U2rSzo9vPJhlDMoDKBw2QMfexkZxk9aVi+dPVF
UwTAkGJwQWBG08FRlvyHX0qOtmRpTA7nJmMcjHIwfMZsS8f3guBt/u/NweKxqGrBGVyxFY3k
0YkitJ5EPRljJB/GoHVkdkdSrKcEEYINXbaK2t0868kKyEAxRCPeef4mBIGPQE85BxjrDdR9
LhZWljlY/O4wxYYzkZPPIPU9fqAWBS1sV6UqyhSykBhlSR1GccfiDSVo2qWs9ubY3EwODMcw
A7SqksAd/cD05wKEOTtqUnglSd4WQ+ZGWDKOcY69PTBqOte7azEslwJ50N7ukBEALKpZgVzv
74/L6kVkUNWCMuYKK17OR7O/tIoTsVVSaZ1GCy43tk9cBeNvQ7c4yaqSM11YvcTMXmjkRN5O
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
FFFABRRRQB//2Q==
--------------050805050408090707050208--


From MAILER-DAEMON Wed Jun 14 20:13:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLIPk-0007Sb-7j
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 20:13:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44373)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLIPi-0007SK-8Z
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:13:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLIPe-0007e8-8s
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:13:30 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:13135
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLIPe-0007dk-2z
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:13:26 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANJ19237; Wed, 14 Jun 2017 20:13:16 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HPZ26767 (AUTH cpr);
	Wed, 14 Jun 2017 20:13:16 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: L A Walsh <bash@tlinx.org>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
Date: Wed, 14 Jun 2017 20:13:15 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5941B02B.7000801@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.14.230916:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW, __CP_MEDIA_BODY,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_EURO,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW, BODY_SIZE_1900_1999,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	__FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS, IN_REP_TO,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 00:13:31 -0000

On 6/14/17 5:52 PM, L A Walsh wrote:

> Chet Ramey wrote:
>> But people don't work in Unicode. They work in their own locale.
> ----
>    Ok, I have my locale set to latin9 (iso8859-15).
> 
> Attached is a pic of how files display in a console
> and how they display in vim.

I am less concerned with how glyphs display in a console than how they
are interpreted as alphanumerics given the C library interfaces that
determine those character classes.

Users expect alphanumerics in their own locale to be allowable as
alphanumerics, and characters that are not to not be allowable as
alphanumerics, and they expect that to be consistent across programs
running on the same system using the same locale. That's the basis to use
for determining whether or not a character is a valid part of a shell
identifier.

A character that is classified as an alphanumeric in a particular locale,
but not in another, can lead to portability problems. That's what we're
debating here, not how something gets displayed in a text editor.

> 
>> That locale may be consistent with Unicode, and it may not.  Adding
>> something that doesn't respect a user's locale isn't useful.
>>   
> What do you mean by respect?  I am running in the locale and
> characters from other locales still display correctly.

See above.

> Isn't that respecting both the local locale as well as
> the one being displayed?

How glyphs are displayed is not an issue for the shell to be concerned
with.

> How is having UTF-8 for files and text not showing
> respect?

Look at the the issue with different locales classifying
characters as alphanumerics differently, and how that would impact
variable names incorporating locale-specific characters in `portable'
scripts.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 14 20:54:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLJ3B-0001dT-3h
	for mharc-bug-bash@gnu.org; Wed, 14 Jun 2017 20:54:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50737)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLJ39-0001dM-9q
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:54:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLJ35-0001xM-C1
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:54:15 -0400
Received: from mail-pg0-x22d.google.com ([2607:f8b0:400e:c05::22d]:36576)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dLJ35-0001xB-5f
	for bug-bash@gnu.org; Wed, 14 Jun 2017 20:54:11 -0400
Received: by mail-pg0-x22d.google.com with SMTP id a70so7336187pge.3
	for <bug-bash@gnu.org>; Wed, 14 Jun 2017 17:54:10 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=pZKq/5M3nNTGPBsHcOpn/Fnpx32nI9oRBMAAEzDPdJQ=;
	b=Y+JG2nMBtwDEdsVA5LHlNuRb3PJ6BLSlB02sWrae+f8eA3wiPXFwQT34b/pucyPUvm
	N7mYzEO+/LHWTx/V9bJfuFJaDo1QfSSFbIItVpRzhiXD4TAfJo02sExI5HS2rp2SMH7p
	CRfH4R37W4VjoA3heo6eNMNQkHB+sdlPu2ZUR4JPsIWuK6pvuxRr39JwAj1ZxHiYtk4D
	9tsDbdl+RPY6hSp+gKO82pw3GLHiwWksm+WG2qUOwO2Pvm2PQUsuiuPgDUbkDZJgdM0t
	xGsDZt9oHp9ERBpgL5o3KEJy9RJMh4ElMN+onX73Qc+xiK1DJk9eBHymL556YtMoe/rt
	GaSA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=pZKq/5M3nNTGPBsHcOpn/Fnpx32nI9oRBMAAEzDPdJQ=;
	b=dfZjlPG4+6+guRw+MAUphRt6OdJVUj2w35UCVP05OvDAr3onp2ECjpawvBMXo3AUha
	Rj2PZQUe+Bjqz1wOMXSSZnVD/8fi3LMysOir8nvkgXUuguFDq+XtHkKC8sk1R5iWAdbg
	BNxObEpaJjmdei/bGPwh/JmBZDQvFTwgkXvHRLigwXW5drt26/RdGoENx8jhQB6CYx3A
	B+rRnLqYmPS1WhfHkHJ3ZcS8aw3lAmIC/JyzabDycjbq9+4hNe1jZ4KVG4ysNtnHlpfb
	T3iQX1hpLJu6Xzp1tESsTKd0IvlUS0FLrO68vVBgsbiJIwBPL/n/O0IN6viCLqSWsseD
	17Bw==
X-Gm-Message-State: AKS2vOyGbZsen2ZcuvuaEPpJaYGniFfRhKuVC7ETW7gAIqud2E2ndsZT
	XC3+rOFAodbmGOFe
X-Received: by 10.99.170.79 with SMTP id x15mr2720016pgo.248.1497488049797;
	Wed, 14 Jun 2017 17:54:09 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.150.222])
	by smtp.gmail.com with ESMTPSA id
	q76sm1931640pfg.117.2017.06.14.17.54.07 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Wed, 14 Jun 2017 17:54:08 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
Message-ID: <795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
Date: Thu, 15 Jun 2017 07:54:05 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 00:54:16 -0000

On 15/06/2560 07:13, Chet Ramey wrote:
> A character that is classified as an alphanumeric in a particular locale,
> but not in another, can lead to portability problems. That's what we're
> debating here, not how something gets displayed in a text editor.

I don't think that exists in unicode or UTF-8 -- could you give an
example of a character that is classified as an alphanumeric in a
particular locale, but not in another?

I think this whole discussion about alphanumerics in world languages is
a red herring though. I don't see any objection in using any
symbol/glyph as admissible in variable names, barring certain reserved
ASCII ones, like space, comma, dot, dash, several kinds braces etc.
It would also greatly simplify the whole implementation.

Peter


From MAILER-DAEMON Thu Jun 15 10:37:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLVtU-000743-QZ
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:37:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39853)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVtR-00073u-RQ
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:37:07 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVtO-0004PP-KP
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:37:05 -0400
Received: from mail-oi0-x22d.google.com ([2607:f8b0:4003:c06::22d]:34404)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLVtO-0004PH-EP
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:37:02 -0400
Received: by mail-oi0-x22d.google.com with SMTP id b6so8807437oia.1
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:37:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=k8ile5rpc497t9ohYNulacJdAlekl17t1kbIZ8ZLEdc=;
	b=jCz42xD8TR6jAB3LdiFtajGL0FKVEJFQCxXKWCQUs/MY1amIVKhigGMOpL61Y+DwUV
	B73+szmomDnmdQy7JiI04b16zyH/U4Upiq8ysjjH5PGN1rwKP6xaWL3kdX++gxL7IuJ/
	p6wsPhXx14AQdWO9zRmnvgMug6NI04nq0fjzczrtv5buzGB8bh3r1IVzPgVYJmnGVZTU
	yDbLVLQSBKL4yCwcqhC3AmY5gNmHb02D+g3TZ2IQtEsqCBLjEiTiw42vgPaHvVF+suQC
	OpUdX9X4BbsfoIHJX0etWmca+htTlXhpeG0DOaVbHKHrn5J3uLIwEO9lEnbTod4comp8
	GBPg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=k8ile5rpc497t9ohYNulacJdAlekl17t1kbIZ8ZLEdc=;
	b=iG7OSsfW6wwK6ulZdyw0KKPYz9/m7+lEQPmTISO9YtJAnOwPYjuRFqZdYWL9sM+OvE
	WCSRx7CPDymOMTp2nrR5JsICJCcCAd6PMQRdnGtk9M7QYB3zDQIKYblbCrszA10sJ2Y6
	il1wr9NijHNCoDeJRzgpiC6jIsu/lrfyHpxRcgHfFurX7cKmwLsREIV6nKMBb1BIGDaQ
	AruCAMeqQS2lpkFEF1Hmjjo0E03XCGOIGTXBcxOZdp4LTWGcpKY8q+DTjXhmMiHjCOEi
	2cg5YKSyeInfn2aFZ2v9sETF7fTgNHhkI+LmxLfdoYaqWRyCHdT9Yqyh/qJku7qF+Mvj
	7ucA==
X-Gm-Message-State: AKS2vOyfjPjwwFB2sMsM5rMmMthEJoOnRLW43Qi4wqpl81xkuUtLvbda
	8bvpKqT9janTtzBK
X-Received: by 10.202.206.212 with SMTP id e203mr3266217oig.206.1497537421254; 
	Thu, 15 Jun 2017 07:37:01 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id p44sm149586otg.33.2017.06.15.07.37.00
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:37:00 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:36:58 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in rl_delete
Message-ID: <20170615143658.uluux6n27z4eix3t@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:37:07 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==1736==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x611000009880 at pc 0x7f464da3a063 bp 0x7ffe86032fe0 sp 0x7ffe86032790
READ of size 115 at 0x611000009880 thread T0
    #0 0x7f464da3a062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x5634e38634c3 in _rl_find_next_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d4c3)
    #2 0x5634e3864375 in _rl_find_next_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e375)
    #3 0x5634e3850c0e in rl_delete (/home/dualbus/src/gnu/bash-build/bash+0x24ac0e)
    #4 0x5634e380230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #5 0x5634e3801ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #6 0x5634e3801727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #7 0x5634e38017b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #8 0x5634e38017dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #9 0x5634e3800e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #10 0x5634e37bc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #11 0x5634e37b9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #12 0x5634e36cfc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #13 0x5634e36d189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #14 0x5634e36cf11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #15 0x5634e36bcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #16 0x5634e36c582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #17 0x5634e36bdd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #18 0x5634e37a70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #19 0x5634e3688401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #20 0x5634e36868da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #21 0x7f464d2522b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #22 0x5634e3685749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x611000009880 is located 0 bytes to the right of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f464dabfd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5634e3795d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5634e3803220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x5634e38030c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x5634e3770c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x5634e37bc096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x5634e37b9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x5634e36cfc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x5634e36d189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x5634e36cf11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x5634e36bcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x5634e36c582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x5634e36bdd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x5634e37a70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x5634e3688401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x5634e36868da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f464d2522b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff9310:[fa]fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
  0x0c227fff9340: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9350: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9360: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==1736==ABORTING

INPUT
G1AKIQMMAgIAgGA8PD0LACQbJCckoAAJAAIAr1wJCT8kJySgAAkAAgCvXAkJYycgYww8PH89CyBg
BEADFRlWPEkA/wEbU4ChPAtJ//t//4A8PQtAPBkQIjyAPDwAARsAIAQgAP8AgBkQAAAAAGRgBFr9
/wAAAADoGRAAPDw8EfyOAID/9K6urq6urq6uk66urq6urq6urq6urq6uva6uYARAAxUTVjxJAIA8
QBn8GwAgBACOjv8g//+Ojo486BkQAAAAAGRgBFoD6AAAfQRAA+g8PBkQACRSUlJSUoBSUlJSUlJS
UlJSUlJSUlJSUlJSUlJSUlJSbvIbBQ==

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:39:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLVvg-000869-Ov
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:39:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40251)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVvY-000857-Il
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:39:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVvV-0004wr-6j
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:39:16 -0400
Received: from mail-ot0-x235.google.com ([2607:f8b0:4003:c0f::235]:34756)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLVvU-0004wf-Uh
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:39:13 -0400
Received: by mail-ot0-x235.google.com with SMTP id r67so11100118ota.1
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:39:12 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=JLjOLuj6pff5OL91DcqAcKnlUezFleHzGP1RPus6pVI=;
	b=HQkxqXz6WIXBw4NewsGmIJqQBqutuZ/fJac+X1lc7fRGJxgWRJM79SIIPRpxtfkmM7
	L8AieWK3t2FAn2J1zuj9FI73I7elNBCxqZXhpc0sM7Dhf/+soDFKNgs+pQxMWNpzgYVp
	uRda+pZ41DZZROvAxtky2rS+Vl69tHcQxW4TG/WG73iVAJvhRF7Qi+ZoLXE2GvI6TCmP
	Fy8sntcBRdmVWvFT9ym0cKQ8Tho02yn+Lgi6KYHVN3CQFfPQBkrTMGxNhey0UlO7vwJ3
	z82fiyX3RuUHlRFrkG0zA92403I8HEfn8KY7FyfnftKJR19z315crfbN691NIeoIbknQ
	bAew==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=JLjOLuj6pff5OL91DcqAcKnlUezFleHzGP1RPus6pVI=;
	b=fAoJpuwhPGZaR2TQ4WUZQzxrilk+3OZLJr4NTmmvLM/FN58A6P5+/bTTATR4cB1ovQ
	tRr+lYvgi0bcP3R2d4FoH29U15bOXKfNV0uYWqz0FbzmbC2qr2loROPtkDmFGKhKm9mU
	ggo85ZSMWs2jMLed2F8mDwQgoqkWNlr7v94MaMdCnXwvO5gwiAbEeYQlOKtvqqP1oYGI
	PPSzt/j5MThwY+lf7ECOFDbGflDj1e4MaBwQXQ3pEne418R9GIep1GXcemae2h0yB9Xn
	i6p3aSS9+B+WclstFYtoQH+AxF6NQv8rg85JDk3EcFz6vVcWdGNhsNh3bDRvAIJk+smF
	yuqg==
X-Gm-Message-State: AKS2vOxZ172GY1hRKEk5stgNtgQgHy+HU+bfWFHWdGkQSJHq82VK/O35
	8gvJFNxKsL72SFOj
X-Received: by 10.157.48.117 with SMTP id w50mr3505201otd.61.1497537551383;
	Thu, 15 Jun 2017 07:39:11 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	s141sm128592oie.40.2017.06.15.07.39.10
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:39:11 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:39:09 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in rl_tilde_expand
Message-ID: <20170615143909.t2dy3xhcia5ufhry@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:39:20 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==472==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x562befba4a14 bp 0x7ffdee172bb0 sp 0x7ffdee172ba8
READ of size 1 at 0x61100000977f thread T0
    #0 0x562befba4a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
    #1 0x562befb6530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #2 0x562befb65aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #3 0x562befb64ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #4 0x562befb64727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #5 0x562befb647b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x562befb647dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x562befb63e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x562befb1f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x562befb1caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x562befa32c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x562befa3489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x562befa3211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x562befa1ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x562befa2882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x562befa20d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x562befb0a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x562bef9eb401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x562bef9e98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f1c9c5ec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x562bef9e8749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f1c9ce59d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x562befaf8d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x562befb66220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x562befb660c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x562befad3c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x562befb1f096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x562befb1caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x562befa32c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x562befa3489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x562befa3211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x562befa1ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x562befa2882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x562befa20d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x562befb0a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x562bef9eb401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x562bef9e98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f1c9c5ec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23ba13) in rl_tilde_expand
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==472==ABORTING

INPUT
KHo0jwAIAREB/wsLYJgAABsbGyYA1SiUYID//Qf6IhoaGFIIIhsbGwC8JLMoKCgoKCgoKCgoKCgd
Hh6Af4lN6QASixIEAQAAABkAAFKOpPsZVtEAHMgEQAADFRlWPCgqKB4eHgEzHhk8gzwA/Klo5gIA
jqQ8GVbRSf///wD/YARbHgQEQAAgIFo9CH84PBAgEAAkABAAAgAAH/q8PD0LQCEZ/n8AsBkAQwD8
jjwZEAA8/yokUo6k+xlW0QAcyARAAAMVGVY8KCooKAYoKCgoKCgoKCgoKCgoHR4eHhgxnGA8Iz0L
QCYZEABkHjkA/AEeHhnr6+vr6+vr6+s76gQC8jwAIAABfQQyf/wZENn5BQ==



==488==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x558cdb461a14 bp 0x7ffe642cea60 sp 0x7ffe642cea58
READ of size 1 at 0x61100000977f thread T0
    #0 0x558cdb461a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
    #1 0x558cdb42230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #2 0x558cdb422aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #3 0x558cdb421ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #4 0x558cdb421727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #5 0x558cdb4217b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x558cdb4217dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x558cdb420e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x558cdb3dc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x558cdb3d9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x558cdb2efc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x558cdb2f189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x558cdb2ef11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x558cdb2dcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x558cdb2e582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x558cdb2ddd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x558cdb3c70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x558cdb2a8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x558cdb2a68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f54e159f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x558cdb2a5749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f54e1e0cd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x558cdb3b5d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x558cdb423220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x558cdb4230c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x558cdb390c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x558cdb3dc096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x558cdb3d9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x558cdb2efc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x558cdb2f189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x558cdb2ef11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x558cdb2dcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x558cdb2e582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x558cdb2ddd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x558cdb3c70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x558cdb2a8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x558cdb2a68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f54e159f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23ba13) in rl_tilde_expand
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c227fff92b0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==488==ABORTING

INPUT
GwMWGOUkexvlQECwAAAoABsbGyYA1SiUYIT/2wf6IhoaGNMIIhsbGwC8JLMoKCgoKCgoKCgoKCgd
Hh6Af4lN6QASixIECQAAABkAAABAJzsAAoAAAAB/APb/Av8A/x4eHgEjHo6kPBlW0Un///////8A
AABkBEAAAyBaZAh/ODwQIBAAHQAQAAIAAB/6AAEACEAhGf5/AI6OozwLLz0LQFVA/BsAoAAABDwZ
GPgZGRkZGRkuGRkZGRkAQwDcjjwZEAA8/yokZ46k+xlW0QAcyARAAAMVGVY8KCooKSgoKCgoKCgo
KCgoKCgoHR4eHhgxnGD/fz0LQCYZEABkHjkA/NMeJFKOpPsZVtEAHMgEQAADFRlWIAABfQAyf/wZ
ENobBQ==



==2949==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x560954d2ca14 bp 0x7ffefe326770 sp 0x7ffefe326768
READ of size 1 at 0x61100000977f thread T0
    #0 0x560954d2ca13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
    #1 0x560954ced30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #2 0x560954cedaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #3 0x560954cecee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #4 0x560954cec727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #5 0x560954cec7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x560954cec7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x560954cebe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x560954ca7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x560954ca4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x560954bbac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x560954bbc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x560954bba11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x560954ba7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x560954bb082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x560954ba8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x560954c920f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x560954b73401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x560954b718da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f4c2e4d02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x560954b70749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f4c2ed3dd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x560954c80d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x560954cee220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x560954cee0c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x560954c5bc28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x560954ca7096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x560954ca4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x560954bbac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x560954bbc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x560954bba11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x560954ba7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x560954bb082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x560954ba8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x560954c920f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x560954b73401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x560954b718da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f4c2e4d02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23ba13) in rl_tilde_expand
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==2949==ABORTING

INPUT
/wIbLbUA/38QGDsYFRwYGBkYGJgYGBj4Fy8wGAAAAEAEEe8Y+xcYGRg9C0AAlGBhaPwe/4AAAFNg
PDxgPgRAAANAABhVKDYbLUo3Gy00GH/tHjAYAABkNzY2gAAbJjc3GwAAgAAtNDYlNjY2NjY3NjaA
ABsmNzcbLRh//x8AAYAAGwo=



==3283==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x5643be3e6a14 bp 0x7ffc4973af60 sp 0x7ffc4973af58
READ of size 1 at 0x61100000977f thread T0
    #0 0x5643be3e6a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
    #1 0x5643be3a730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #2 0x5643be3a7aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #3 0x5643be3a6ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #4 0x5643be3a6727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #5 0x5643be3a67b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5643be3a67dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5643be3a5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5643be361136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5643be35eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5643be274c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5643be27689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5643be27411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5643be261f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5643be26a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5643be262d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5643be34c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5643be22d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5643be22b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fc442cb52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x5643be22a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7fc443522d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5643be33ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5643be3a8220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x5643be3a80c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x5643be315c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x5643be361096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x5643be35eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x5643be274c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x5643be27689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x5643be27411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x5643be261f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x5643be26a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x5643be262d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x5643be34c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x5643be22d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x5643be22b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7fc442cb52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23ba13) in rl_tilde_expand
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3283==ABORTING

INPUT
GyIWKBsmSIFcXlxcRugDXFxGxVz8Gv9+7BsbGxsbGxsbbRs+GxsABBsrGwAAGhqIiIiIiIiIiIiI
iIiIiIiIiIh/iIiIiIiIiIiIiIgaBd8A2x8bFBQUFRQUAGdnZ2dnfmcZGRkZGV8ZGRkZGTUZGRkB
GRkUFABnZ2dnUmdnGRmjnaPgfwDfAOwiFBUUFABnZ2dnZ354GRkZGRlfGRkZGRk1GRkZARkZjhsU
BBshjo6OGxsbExsbAAAD6BQVFBQbFAQbBRsbGxQEFBQ=



==3340==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x5633b4c76a14 bp 0x7fff8bd3f650 sp 0x7fff8bd3f648
READ of size 1 at 0x61100000977f thread T0
    #0 0x5633b4c76a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
    #1 0x5633b4c3730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #2 0x5633b4c37aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #3 0x5633b4c36ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #4 0x5633b4c36727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #5 0x5633b4c367b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5633b4c367dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5633b4c35e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5633b4bf1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5633b4beeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5633b4b04c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5633b4b0689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5633b4b0411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5633b4af1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5633b4afa82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5633b4af2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5633b4bdc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5633b4abd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5633b4abb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f891c43f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x5633b4aba749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f891ccacd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5633b4bcad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5633b4c38220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x5633b4c380c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x5633b4ba5c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x5633b4bf1096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x5633b4beeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x5633b4b04c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x5633b4b0689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x5633b4b0411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x5633b4af1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x5633b4afa82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x5633b4af2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x5633b4bdc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x5633b4abd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x5633b4abb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f891c43f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23ba13) in rl_tilde_expand
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3340==ABORTING

INPUT
KHo0jwAIAQEB/wsLYJgAABsbGyYA2AgiGxsbALwksygoKCgoAAAAECgoKB0eHoB/iU3pABAolGCA
//0H+lwaGhjYCCIbGxsAvCSzKCgoKCgEAAAQKCgoHR4egH+JTekAEosSAEAAAAAZAAAAQDw7AAKA
HhYKGgAQAAL/gFv/AP8eHh4BJiYmJiYmJiYmJiYmMx4ZPIM8APypaOYCAI6kPBlW0Un///8A/2AE
Wx4EBEAAAyBaPQh/OHwQIBAABAAQAAIA//8AADw9C0AhGf5/AI6OozwLLz0LQFVA+RsAoAAABDwZ
GRkZGRkZGRkuGRkZGRkAQwD8jjwZEAA8/yokUo6k+xlW0QAcyARAAAMVGVY8KCooKCgoKCgoKCgo
KCgoKCgoHR4eHhgxnGA8Iz0L3d3d3d3d3d3d3d3d8t3d3d3d3d3d3d3d3d3d3d3dIAABfQQyY/wZ
ENobBQ==

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:41:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLVxc-0000EP-Ka
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:41:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40811)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVxX-0000BN-FL
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:41:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVxU-0005jh-31
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:41:19 -0400
Received: from mail-ot0-x233.google.com ([2607:f8b0:4003:c0f::233]:33370)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLVxT-0005jU-P6
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:41:16 -0400
Received: by mail-ot0-x233.google.com with SMTP id k4so11177928otd.0
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:41:15 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=P4vbxW+2JWUl+Zui+qYkYAs1Fw3mbeSWK4uu/mBRyL0=;
	b=Qa5QrNMXBGuSBVI+rvaHh5oUd6sPLjU3zxbSYydGqXz162ejauiLbpxOnYPcjIUqlJ
	eZQnc/pr4ZnGcpBw3rwAL6pob50nHOd7vswhb+Te/WZURwoOE2ozxkk/chVHcj7z0s+G
	HTkyAug55Btu3W6UJsvIGcFleM7YROKgn1aG1Os1eovrhw3EjlBt6UwmMsu6lT8NBKZZ
	c56c0SmbZenpqbsCejLgSFXXO4BdoLg500EXiXVBCTW0wkSrkpERjxTdjeQ31fwB5D5q
	ULApkx4gDNRNV7vX/gWNgOfzZzpcVquiUMNaOiIqYw5LN523PX3NvkrSLezk6RkHnZp3
	A+aw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=P4vbxW+2JWUl+Zui+qYkYAs1Fw3mbeSWK4uu/mBRyL0=;
	b=p26S8fs45MZqu29Kjv3Xp2sFLGcWDavArxymYjPB6TF4nIX/nQFAlzsR7BhLCCbrXf
	Q/3QIFisDnhn4kucXPeXzi2F8hmkm69dMi775uIA7qOFHlickjs4/fMXORXWiObbWx0W
	nIbJ/LZB+buylAa+f0w18nQtzfYS4ri4r2xsFjuNqUnEJhIXXXA3uNY57MpyxrrxX1oi
	DrWFK2RT+ceMWVopCDzX1RXDOecKk6jm4gJR9vCR1ZhHpz6K7oW1PyJhO9zbJXCAna45
	XpWEqsbh8JWsrPHiNZ1bbeYHxtjlj2VFX/ESPni3qpb9VGbWnsNwtYYiAdUVzoemWKf0
	bBeg==
X-Gm-Message-State: AKS2vOyCTsSImnav9La2azXgwQA3MAyOrd7avyzf4NpMqnowu7m8aqY/
	/55MnX9F64qz4d5f
X-Received: by 10.157.24.76 with SMTP id t12mr2937359ott.145.1497537670027;
	Thu, 15 Jun 2017 07:41:10 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	m199sm142288oig.18.2017.06.15.07.41.09
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:41:09 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:41:08 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: global-buffer-overflow in
	rl_filename_completion_function
Message-ID: <20170615144108.722izyafdxhycuez@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::233
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:41:23 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==1098==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55e61a6b4c5c at pc 0x55e61a3426ca bp 0x7fff1820a300 sp 0x7fff1820a2f8
READ of size 4 at 0x55e61a6b4c5c thread T0
    #0 0x55e61a3426c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x55e61a3e0a08 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218a08)
    #2 0x55e61a3df702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x55e61a3daaab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x55e61a3dea63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x55e61a3d81e0 in rl_complete (/home/dualbus/src/gnu/bash-build/bash+0x2101e0)
    #6 0x55e61a3c430d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x55e61a3c3ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55e61a3c3727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55e61a3c37b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55e61a3c37dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55e61a3c2e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55e61a37e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55e61a37baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55e61a291c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55e61a29389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55e61a29111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55e61a27ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55e61a28782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55e61a27fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55e61a3690f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55e61a24a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55e61a2488da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fdab89d22b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55e61a247749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x55e61a6b4c5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x55e61a6b4c20) of size 4
0x55e61a6b4c5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x55e61a6b4c60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0abd434ce930: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0abd434ce980: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0abd434ce990: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce9a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce9b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce9c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abd434ce9d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==1098==ABORTING

INPUT
ACEAJDRXGgGm9ltZJwkAGhQBXID////nPlaAPz4/Kj8/Pz8AgAPoKg4YKgUECaEJAAAAZAkJCQkJ
CfoACQk2CQlfAAAACQACAK9cCQlj/wEbSYChFJQbUyQoeRsKU1O/GxtTJDX//97gLxSWZAAAACoA
/xQiBRsbIBsKG2QfEAAAlf3/4xsZVAQg6of9AABTJCf//xYnAPoZFb0AAID//xmA6xgAGQgICAgJ
GRkZGL09f/8AGf//vb29CAwH+wgIGxAIjwkIKoAMvb2Hvb0ICBoIDBn7CAgICIC9vb0ICJj0CB8A
AgAI/w8fCAj+yUB/kA==



==15163==ERROR: AddressSanitizer: global-buffer-overflow on address 0x5651610c8c5c at pc 0x565160d566ca bp 0x7ffd2a68cf50 sp 0x7ffd2a68cf48
READ of size 4 at 0x5651610c8c5c thread T0
    #0 0x565160d566c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x565160df4c30 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218c30)
    #2 0x565160df3702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x565160deeaab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x565160df2a63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x565160dec1e0 in rl_complete (/home/dualbus/src/gnu/bash-build/bash+0x2101e0)
    #6 0x565160dd830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x565160dd8f47 in _rl_subseq_result (/home/dualbus/src/gnu/bash-build/bash+0x1fcf47)
    #8 0x565160dd8b07 in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcb07)
    #9 0x565160dd8aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #10 0x565160dd7ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x565160dd7727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x565160dd77b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x565160dd77dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x565160dd6e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x565160d92136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x565160d8faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x565160ca5c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x565160ca789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x565160ca511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x565160c92f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x565160c9b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #22 0x565160c93d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #23 0x565160d7d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #24 0x565160c5e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #25 0x565160c5c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #26 0x7f4308d562b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #27 0x565160c5b749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x5651610c8c5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x5651610c8c20) of size 4
0x5651610c8c5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x5651610c8c60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0acaac211130: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac211140: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac211150: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac211160: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac211170: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0acaac211180: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0acaac211190: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac2111a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac2111b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac2111c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0acaac2111d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15163==ABORTING

INPUT
//0bLbUAAlsQGDIYFRwYGBkYGJgYGPDwXFxcXCQkKCT/fyIbG2FcAP+AC/Hw8FxcXFwkJCgk/38i
GxthXJhcXFxcXMzMderMkQAAACIAXFxcXFwkJCYk/38iGxthXJhcXFxc3wDsFxQVFBQAj6sAXFxc
XHwkJCgkIhsbgDUZGRkBGRmOjo6OGxsbGxsbGxsbIBkZGQEZGY6Pjo5/IhsbYVwA/4AL8fDwGxsb
GxsbGxsbIBsbGxsbABsbGxQbGxsbGwAbGxsUBBsFGxsbFAQUEg==



==22733==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55ae41d95c5c at pc 0x55ae41a236ca bp 0x7ffc393df460 sp 0x7ffc393df458
READ of size 4 at 0x55ae41d95c5c thread T0
    #0 0x55ae41a236c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x55ae41ac1c30 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218c30)
    #2 0x55ae41ac0702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x55ae41abbaab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x55ae41abfa63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x55ae41ab91e0 in rl_complete (/home/dualbus/src/gnu/bash-build/bash+0x2101e0)
    #6 0x55ae41aa530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x55ae41aa4ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55ae41aa4727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55ae41aa47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55ae41aa47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55ae41aa3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55ae41a5f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55ae41a5caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55ae41972c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55ae4197489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55ae4197211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55ae4195ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55ae4196882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55ae41960d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55ae41a4a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55ae4192b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55ae419298da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fee1119d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55ae41928749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x55ae41d95c5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x55ae41d95c20) of size 4
0x55ae41d95c5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x55ae41d95c60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0ab6483aab30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aab40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aab50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aab60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aab70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0ab6483aab80: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0ab6483aab90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aaba0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aabb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aabc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6483aabd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22733==ABORTING

INPUT
G+ABawIA+gAYKgUC/w4YKgUiPNHR0dHRGxgqBf9/AFwA/3+i6SR7JF4WKHmxsVQEzTVBXjFBQV1B
KUFVfRb6QBQAAWh/QAAAAAH9fgv9JCg8TUth7u7uGWFNPk1NTU1NZB39TSQJqw5AIRkuGRYZGRkG
Qx/8jjwZEAA8/yoZGRkuHTYZEBkZGRkGQx/8jjwkPI6k+xlW0QAcyAQ/AAMVGVY8KBIoPCgoKCgo
KCgqKCj1KCgoPB0eHh4YF/UoAGQBnGAtJhkQf4AeIAD+0x4eGRSAGwU=



==23291==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55dc526e9c5c at pc 0x55dc523776ca bp 0x7ffd94ca3770 sp 0x7ffd94ca3768
READ of size 4 at 0x55dc526e9c5c thread T0
    #0 0x55dc523776c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x55dc52415c30 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218c30)
    #2 0x55dc52414702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x55dc5240faab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x55dc52413a63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x55dc5240d1e0 in rl_complete (/home/dualbus/src/gnu/bash-build/bash+0x2101e0)
    #6 0x55dc523f930d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x55dc523f9f47 in _rl_subseq_result (/home/dualbus/src/gnu/bash-build/bash+0x1fcf47)
    #8 0x55dc523f9b07 in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcb07)
    #9 0x55dc523f9aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #10 0x55dc523f8ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #11 0x55dc523f8727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #12 0x55dc523f87b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #13 0x55dc523f87dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #14 0x55dc523f7e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #15 0x55dc523b3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #16 0x55dc523b0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #17 0x55dc522c6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #18 0x55dc522c889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #19 0x55dc522c611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #20 0x55dc522b3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #21 0x55dc522bc82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #22 0x55dc522b4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #23 0x55dc5239e0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #24 0x55dc5227f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #25 0x55dc5227d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #26 0x7fc98b7912b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #27 0x55dc5227c749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x55dc526e9c5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x55dc526e9c20) of size 4
0x55dc526e9c5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x55dc526e9c60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0abc0a4d5330: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d5340: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d5350: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d5360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d5370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0abc0a4d5380: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0abc0a4d5390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d53a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d53b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d53c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abc0a4d53d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23291==ABORTING

INPUT
BtAQV1sAAAABIAQqBQMQPXAFAgAAASAEQAUDEABdPQABFC1JAAABXFuYAABAXFsAf/8BIAQiBQMU
DhgqBSpfoxAO+CoFEicbqKiVuwAQ/xQbG1MkG3kF/3sQEBBQEBAQEBAQEBAhECwQEBADFQIbfyQt
lhQbG1NnZ3l5cnl5eXl5eXl5eXl5iHl5eXl5QFVW/BvnoAAhBDMZGRkZAACAABkBSygofx4eHhgZ
nAAAPQtAJi4ZLQEmAht/JC2WFBsbU2cZBkMAQCg5GAABSygofx4eAAEAAAAAPQtCJhknAAAQ/xQb
G1MkG3kF/3sQEBAQEGQeAAACAB4eGesZGQFLKBgAASgoKH8eHh4YGZwAAD0LQCYZEBpknAAAPQtA
JhkQGmQeOQD8wQB5GRSmHjkA/MGBgYGBgYGBgYGBgYGBgYGBgYGBgYGBgYEAeRkUphsF



==27624==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55e20518ac5c at pc 0x55e204e186ca bp 0x7fff45327ba0 sp 0x7fff45327b98
READ of size 4 at 0x55e20518ac5c thread T0
    #0 0x55e204e186c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x55e204eb6a08 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218a08)
    #2 0x55e204eb5702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x55e204eb0aab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x55e204eb4a63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x55e204eae1e0 in rl_complete (/home/dualbus/src/gnu/bash-build/bash+0x2101e0)
    #6 0x55e204e9a30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x55e204e99ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55e204e99727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55e204e997b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55e204e997dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55e204e98e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55e204e54136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55e204e51aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55e204d67c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55e204d6989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55e204d6711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55e204d54f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55e204d5d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55e204d55d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55e204e3f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55e204d20401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55e204d1e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f21e44ed2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55e204d1d749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x55e20518ac5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x55e20518ac20) of size 4
0x55e20518ac5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x55e20518ac60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0abcc0a29530: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a29540: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a29550: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a29560: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a29570: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0abcc0a29580: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0abcc0a29590: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a295a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a295b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a295c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0abcc0a295d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27624==ABORTING

INPUT
G+ABf2QB0YDR0QL5JgkAGhQBXAlfAAAACQACAK9cCQli/wEbU4CfFJQbUyQo4C8UlmQA/AAqAP8U
IgUgGAobZB8WJwD6GRW9AACA//8ZgOsYABkIAwgICQcZGRi9PX//ABn//729vQgMB/sICBsQCI8J
CCqADL29h729CAgaCHgZ+wgICAiAvb29CAiY9AgfAAIACP8PHwgI/tlAf5A=



==2732==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55b2cee4cc5c at pc 0x55b2ceada6ca bp 0x7ffe47c5ab90 sp 0x7ffe47c5ab88
READ of size 4 at 0x55b2cee4cc5c thread T0
    #0 0x55b2ceada6c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
    #1 0x55b2ceb78c30 in rl_filename_completion_function (/home/dualbus/src/gnu/bash-build/bash+0x218c30)
    #2 0x55b2ceb77702 in rl_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x217702)
    #3 0x55b2ceb72aab in gen_completion_matches (/home/dualbus/src/gnu/bash-build/bash+0x212aab)
    #4 0x55b2ceb76a63 in rl_complete_internal (/home/dualbus/src/gnu/bash-build/bash+0x216a63)
    #5 0x55b2ceac7a94 in bash_brace_completion (/home/dualbus/src/gnu/bash-build/bash+0x167a94)
    #6 0x55b2ceb5c30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #7 0x55b2ceb5caef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #8 0x55b2ceb5bee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #9 0x55b2ceb5b727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #10 0x55b2ceb5b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #11 0x55b2ceb5b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #12 0x55b2ceb5ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #13 0x55b2ceb16136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #14 0x55b2ceb13aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #15 0x55b2cea29c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #16 0x55b2cea2b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #17 0x55b2cea2911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #18 0x55b2cea16f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #19 0x55b2cea1f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #20 0x55b2cea17d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #21 0x55b2ceb010f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x55b2ce9e2401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x55b2ce9e08da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7fbbd390b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x55b2ce9df749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x55b2cee4cc5c is located 56 bytes to the right of global variable 'sh_syntabsiz' defined in 'syntax.c:11:5' (0x55b2cee4cc20) of size 4
0x55b2cee4cc5c is located 4 bytes to the left of global variable 'sh_syntaxtab' defined in 'syntax.c:12:5' (0x55b2cee4cc60) of size 1024
SUMMARY: AddressSanitizer: global-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9) in bash_dequote_filename
Shadow bytes around the buggy address:
  0x0ab6d9dc1930: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc1940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc1950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc1960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc1970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0ab6d9dc1980: 00 00 00 00 04 f9 f9 f9 f9 f9 f9[f9]00 00 00 00
  0x0ab6d9dc1990: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc19a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc19b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc19c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0ab6d9dc19d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==2732==ABORTING

INPUT
GyoQExgaNUxSAAIAAAcbVABAKwCX7ZYQGxsbChsUEDw8PEg8PP9/GfdPAABTYC48i6sB//9/YEAA
AAMbGTw8PDw8VP8BGxlgBHt7e3t7e3sQlvwAcQ7/IuAMFBAbGxsrAKEBAJqampqSljyAFH8bGxlU
9t7XllMkLZYAABAgUxP6GhveLwCV/ZYQGxsb/3///yR7e3t7e94vFAAA//8bKgCh8QJ///IbkCEk
+iADVP8bG28AGwIbUyQoeRv/GvpAFJQABAIbU+KVG1QE3iYUvxQbGwAC/VMbLxtUBBsbAAL9Uxsv
G1QEGxsbG1QAQCsAl+2WEBsbGwobFJYUGxsbSAAAQAAAg+2WEBsbGwrqdwAR+nx8YoB/aNkDMmRR
UVFR/fwAdgQbAhtdGxsfAIAUAACiEPwAlgQbAv1TGxUbABsbGVT//3//lgTelhQbGht7e/ogA1T/
GxtTJAp5G/8aDBSUAAR7/3t7e/oMFJQABHt7e3u/3hEUlhQbGxsqAKEUAoAAGxsbOBsfGxsE/+0F

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:42:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLVz7-00013k-5z
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:42:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41305)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVz0-000101-Lj
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:42:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLVyw-0006DE-5Q
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:42:50 -0400
Received: from mail-oi0-x22f.google.com ([2607:f8b0:4003:c06::22f]:33011)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLVyv-0006Cz-Qv
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:42:46 -0400
Received: by mail-oi0-x22f.google.com with SMTP id s3so8874399oia.0
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:42:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=nCiltAGnGGDAvmocR5rSYcwyis76v6JYgtFxiF7nxg8=;
	b=l4cr1mU2aoXHiPzvPSj9/zWEXpqATLjXauQkkLxpT589W0Uts0Mh7YaOfPrreJZ62h
	WEI5hqT9VIG8KinbRnhA3g3of5+QNOztj0G1XoEaLl8P+e+w0YwEb+5VspmqQ+KkDpPQ
	cEEJlhz8xyf3kWc/cTZXg0EaLGcD1DDsLPjbg0O6dDZsPcrdsarf4hnEiBGl5YfQiCb2
	gZ/Gt9lwk9T8Y1z3R/VdChHY06UopafrVQNBn7NIbnTMZzKr0TF1T5W/JiSat4W8F4+w
	4YEx31NZsFLDpFM9I4UE0nd/a5WkkTQFoHNSFyWIUU8D9eH1UahT+cakcKes7Y1au4W4
	wThw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=nCiltAGnGGDAvmocR5rSYcwyis76v6JYgtFxiF7nxg8=;
	b=M/TmmSPrPbA/hgRphYqYhuFN1ijXOu05JnHoDqy1OvnjYIxUW7Ci3jQBoOTkNIR3Og
	bNuIZPg8Djm8C/y8KTb0hEyk95qARz6KC0jTl+/fd7dKz0zDfuKFRQ1z8ptI9XhtKMzD
	0JKgaxKOlZU3/kveu2S2MbhyTdEkbcG7Qwdw5e4ni8eF7vku9PiF245qIpKvG/QBLzyR
	gyo2Su+MX/tC9CZuct0jjg+XxiW9rFEFZewNkrlcocJuvBa7avdvpRrjZv1rG2O1Gsfc
	iU1JFbrkCMSmbpuVZ6IXcDhCoo/uvWxuVKcUBvR1v3t5XI1VCRgfpKqs0rv9gQpys55T
	vlUQ==
X-Gm-Message-State: AKS2vOx/RKNOWTFkO5ajlIF8XeTurSAtDeyPPYIaf/hObusaBArJ/Ynb
	xRWWfNMV9pBCxZRd
X-Received: by 10.202.73.210 with SMTP id w201mr3057427oia.224.1497537764126; 
	Thu, 15 Jun 2017 07:42:44 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id i53sm153120ote.43.2017.06.15.07.42.43
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:42:43 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:42:41 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in rl_kill_text
Message-ID: <20170615144241.jxvplir4wsbau42f@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:42:55 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==11018==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x559bb60f1be7 bp 0x7ffc36ec8710 sp 0x7ffc36ec8708
READ of size 8 at 0x60700000ccc0 thread T0
    #0 0x559bb60f1be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x559bb60f1f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x559bb60f31f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x559bb60b130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x559bb60b0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x559bb60b0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x559bb60b07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x559bb60b07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x559bb60afe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x559bb606b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x559bb6068aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x559bb5f7ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x559bb5f8089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x559bb5f7e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x559bb5f6bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x559bb5f7482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x559bb5f6cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x559bb60560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x559bb5f37401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x559bb5f358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f50ebc9d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x559bb5f34749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000ccc0 is located 0 bytes to the right of 80-byte region [0x60700000cc70,0x60700000ccc0)
allocated by thread T0 here:
    #0 0x7f50ec50b090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x559bb6044e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x559bb60f1c4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x559bb60f1f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x559bb60f23eb in rl_kill_line (/home/dualbus/src/gnu/bash-build/bash+0x23d3eb)
    #5 0x559bb60b130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x559bb60b0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x559bb60b0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x559bb60b07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x559bb60b07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x559bb60afe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x559bb606b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x559bb6068aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x559bb5f7ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x559bb5f8089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x559bb5f7e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x559bb5f6bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x559bb5f7482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x559bb5f6cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x559bb60560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x559bb5f37401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x559bb5f358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f50ebc9d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa 00 00
=>0x0c0e7fff9990: 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa fd fd fd fd fd fd
  0x0c0e7fff99b0: fd fd fd fd fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11018==ABORTING

INPUT
AAIbLbUAAlsQGDIYFRkYGBn//4DdHxgYGAAYGGQAAICAgICAgICAgICAgICAgICAgICAgICAgICA
GBj6FxgZGBgjGAAYGGjw8PAgAAAA8Gjw8PDwjisrK448PDw9C0BdC0A+BP///38BARgoFRUVmBAQ
EC8BEAsQEBUVFRUVFPQUGC8IEDgbOBMYKDiTkxAQFRUFFRUVFRUVFPQUGC8IEDgbOBMYKDgbOBMU
RRgAAAYBJyJhHQIAGzgTGCh/GzgTGGUYAAAGGCf3AD8AGzgkGEX3ABAAAAAQGEUYZAAGABDbAIAA
ABjEAj9ADjs=



==11019==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x55d397c1bbe7 bp 0x7ffe1d93d800 sp 0x7ffe1d93d7f8
READ of size 8 at 0x60700000ccc0 thread T0
    #0 0x55d397c1bbe6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x55d397c1bf79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x55d397c1c3eb in rl_kill_line (/home/dualbus/src/gnu/bash-build/bash+0x23d3eb)
    #3 0x55d397bdb30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x55d397bdaee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x55d397bda727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x55d397bda7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x55d397bda7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x55d397bd9e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x55d397b95136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x55d397b92aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x55d397aa8c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x55d397aaa89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x55d397aa811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x55d397a95f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x55d397a9e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x55d397a96d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x55d397b800f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x55d397a61401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x55d397a5f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f27342a32b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x55d397a5e749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000ccc0 is located 0 bytes to the right of 80-byte region [0x60700000cc70,0x60700000ccc0)
allocated by thread T0 here:
    #0 0x7f2734b11090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55d397b6ee00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55d397c1bc4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x55d397c1bf79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x55d397c1d1f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x55d397bdb30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x55d397bdaee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x55d397bda727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x55d397bda7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x55d397bda7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x55d397bd9e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x55d397b95136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x55d397b92aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x55d397aa8c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x55d397aaa89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x55d397aa811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x55d397a95f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x55d397a9e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x55d397a96d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x55d397b800f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x55d397a61401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x55d397a5f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f27342a32b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa 00 00
=>0x0c0e7fff9990: 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa fd fd fd fd fd fd
  0x0c0e7fff99b0: fd fd fd fd fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11019==ABORTING

INPUT
AAIbLbUAAlsQGDIYFRkYGBn//4DdHxgYGAAYGGQAAICAgICAgICAgICAgICAgICAgICAgICAgICA
GBj6FxgZGBgjGAAYGGjw8PDwjh4S8Gjw8PDwjisrK448PDw9C0BdC0A+BP///38BARgoFRUVmBAQ
EC8BEAsQEBUVFRUVFPQUGC8IEDgbOBMYKDiTkxAQFRUFFRUVFRUVFPQUGC8IEDgbOBMYKDgfOBMU
RRgAAAYBJyJhHQIAGzgTGCh/GzgTCmUYAAAGGCf3AD8AGzgTGEX3ABAAAAAQGEUYZAAGABDbAIAA
ABjEAj9ADjs=



==11020==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000cc50 at pc 0x556a2aae1be7 bp 0x7ffc9f2602d0 sp 0x7ffc9f2602c8
READ of size 8 at 0x60700000cc50 thread T0
    #0 0x556a2aae1be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x556a2aae1f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x556a2aae31f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x556a2aaa130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x556a2aaa0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x556a2aaa0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x556a2aaa07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x556a2aaa07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x556a2aa9fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x556a2aa5b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x556a2aa58aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x556a2a96ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x556a2a97089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x556a2a96e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x556a2a95bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x556a2a96482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x556a2a95cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x556a2aa460f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x556a2a927401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x556a2a9258da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f4fef4b92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x556a2a924749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000cc50 is located 0 bytes to the right of 80-byte region [0x60700000cc00,0x60700000cc50)
allocated by thread T0 here:
    #0 0x7f4fefd27090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x556a2aa34e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x556a2aae1c4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x556a2aae1f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x556a2aae31f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x556a2aaa130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x556a2aaa0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x556a2aaa0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x556a2aaa07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x556a2aaa07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x556a2aa9fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x556a2aa5b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x556a2aa58aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x556a2a96ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x556a2a97089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x556a2a96e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x556a2a95bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x556a2a96482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x556a2a95cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x556a2aa460f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x556a2a927401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x556a2a9258da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f4fef4b92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9930: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
=>0x0c0e7fff9980: 00 00 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd
  0x0c0e7fff9990: fd fd fd fd fd fd fd fa fa fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa fd fd fd fd fd fd
  0x0c0e7fff99b0: fd fd fd fd fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11020==ABORTING

INPUT
AAIbLbUAAlsQGDIYFRkYGBn//4DdHxgYGAAYGGQAAICAgICAgICAgICAgICAgICAgICAgICAgICA
GBj6FxgZGBhFGAAYGGjw8PDwjh4S8Gjw8PABGCgVFRWYEBAQLwEQEBAQFRUVFRUU9BgoFRUVmBAQ
EC8BEAsQEBUVFRUVFPQUGC8IEDgbOBMYKDiTk/sQFRUFFRUVFRUVFPQUGC8IEDgbOBMYKDgbOBMU
RRgAAAYBJyJhHQIAGzgTGCh/GzgTGGUYAAAGGCf3AD8AGzgTGEX3ABAAAAAQGEUYZAAGABDbAIAA
ABjEAj9ADjs=



==15290==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x55bf58a71be7 bp 0x7fff2f94b4c0 sp 0x7fff2f94b4b8
READ of size 8 at 0x60700000ccc0 thread T0
    #0 0x55bf58a71be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x55bf58a71f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x55bf58a731f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x55bf58a3130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x55bf58a30ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x55bf58a30727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x55bf58a307b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x55bf58a307dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x55bf58a2fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x55bf589eb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x55bf589e8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x55bf588fec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x55bf5890089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x55bf588fe11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x55bf588ebf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x55bf588f482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x55bf588ecd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x55bf589d60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x55bf588b7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x55bf588b58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7fd3c37bd2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x55bf588b4749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000ccc0 is located 0 bytes to the right of 80-byte region [0x60700000cc70,0x60700000ccc0)
allocated by thread T0 here:
    #0 0x7fd3c402b090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55bf589c4e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55bf58a71c4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x55bf58a71f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x55bf58a731f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x55bf58a3130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x55bf58a30ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x55bf58a30727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x55bf58a307b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x55bf58a307dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x55bf58a2fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x55bf589eb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x55bf589e8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x55bf588fec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x55bf5890089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x55bf588fe11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x55bf588ebf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x55bf588f482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x55bf588ecd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x55bf589d60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x55bf588b7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x55bf588b58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7fd3c37bd2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa 00 00
=>0x0c0e7fff9990: 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa 00 00 00 00 00 00
  0x0c0e7fff99b0: 00 00 00 03 fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15290==ABORTING

INPUT
AAIbLbUAAlsQGDIYFxwYGBkYGJgYGBgYGAAYGBgwGAAAAEAYGBggAAAEANIY+xcYGRgYGBgYIAAA
BEA+BCbMBEABARgoFRUVFRAQ////gAsQEDMQEBAQEBAVCBA4Gzj+GH84GzgTGCYQEBUVBRUV4RUV
FRUVFPkVCBA4GzgTGCg4GzgTGBgoOBs4ExgmEBAVFQUVFeEVFRUVFRT5FRUVFRT5FQgQOBs4Exgo
OBs4ExgYKDgbGAAABgEnKGEdAgAbOBMVFeEVFRUVFRT5FQgQOBs4ExgoOBs4ExgmABs4ExgoOBs4
ExhlGAAFBhgn9wAmYR0CABs4ExgoOBs4ExgQEAsQEDMQGzgTGEX3ABAAANwQIEUYZAAGABDbAAAC
ABjEAj9ADjs=



==15291==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000cd30 at pc 0x563cebd3dbe7 bp 0x7ffe4f50b390 sp 0x7ffe4f50b388
READ of size 8 at 0x60700000cd30 thread T0
    #0 0x563cebd3dbe6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x563cebd3df79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x563cebd3f1f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x563cebcfd30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x563cebcfcee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x563cebcfc727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x563cebcfc7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x563cebcfc7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x563cebcfbe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x563cebcb7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x563cebcb4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x563cebbcac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x563cebbcc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x563cebbca11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x563cebbb7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x563cebbc082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x563cebbb8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x563cebca20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x563cebb83401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x563cebb818da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f2089e212b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x563cebb80749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000cd30 is located 0 bytes to the right of 80-byte region [0x60700000cce0,0x60700000cd30)
allocated by thread T0 here:
    #0 0x7f208a68f090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x563cebc90e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x563cebd3dc4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x563cebd3df79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x563cebd3f1f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x563cebcfd30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x563cebcfcee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x563cebcfc727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x563cebcfc7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x563cebcfc7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x563cebcfbe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x563cebcb7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x563cebcb4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x563cebbcac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x563cebbcc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x563cebbca11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x563cebbb7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x563cebbc082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x563cebbb8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x563cebca20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x563cebb83401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x563cebb818da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f2089e212b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9990: fa fa fa fa fa fa fa fa fa fa fa fa 00 00 00 00
=>0x0c0e7fff99a0: 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd fd fd
  0x0c0e7fff99b0: fd fd fd fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
  0x0c0e7fff99f0: 00 00 00 00 00 00 00 00 00 fa fa fa fa fa 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15291==ABORTING

INPUT
AAIbLbUAAlsQGDIYFxwYGBkYGJgYGBgYGAAYGBgwGAAAAEAYGBggAAAEANIY+xcYGRgYGBgYIAAA
BEA+BEDMBEABARgoFRUVFRAQ////gAsQEDMQEBAQEBAVCBA4Gzj+GEU4GzgTGCYQEBUVBRUV4RUV
FRUVFPkVCBA4/wAAAEE4GzgTGBgoOBs4ExgmEBAVFQUVFeEVFRUVFRT5FRUVFRT5FQgQOBs4Exgo
OBs4ExgYKDgbGAAABgEnKGEdAgAbOBMVFeEVFRUVFRQ1NTU1NTU1NTU1NfkVCBA4GzgTGCg4GzgT
GCYAGzgTGCg4GzgTGGUYAAAGGCf3ACZhHQIAGzgTGCg4GzgTGBAQCxAQMxAbOPf39/f39/f39/f3
9/f39/f39/f39wAAGMQCP0AOOw==



==15292==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x5581a900ebe7 bp 0x7ffe212a21a0 sp 0x7ffe212a2198
READ of size 8 at 0x60700000ccc0 thread T0
    #0 0x5581a900ebe6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x5581a900ef79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x5581a90101f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x5581a8fce30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x5581a8fcdee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x5581a8fcd727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x5581a8fcd7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x5581a8fcd7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x5581a8fcce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x5581a8f88136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x5581a8f85aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x5581a8e9bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x5581a8e9d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x5581a8e9b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x5581a8e88f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x5581a8e9182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x5581a8e89d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x5581a8f730f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x5581a8e54401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x5581a8e528da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f40896ae2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x5581a8e51749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000ccc0 is located 0 bytes to the right of 80-byte region [0x60700000cc70,0x60700000ccc0)
allocated by thread T0 here:
    #0 0x7f4089f1c090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5581a8f61e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x5581a900ec4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x5581a900ef79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x5581a90101f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x5581a8fce30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x5581a8fcdee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x5581a8fcd727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x5581a8fcd7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x5581a8fcd7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x5581a8fcce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x5581a8f88136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x5581a8f85aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x5581a8e9bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x5581a8e9d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x5581a8e9b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x5581a8e88f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x5581a8e9182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x5581a8e89d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x5581a8f730f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x5581a8e54401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x5581a8e528da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f40896ae2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa 00 00
=>0x0c0e7fff9990: 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa 00 00 00 00 00 00
  0x0c0e7fff99b0: 00 00 00 03 fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15292==ABORTING

INPUT
AAIbLbUAAlsQGDIYFxwYGBkYGJgYGBgYGAAYGBgwGAAAAEAYGBggAAAEANIY+xcYGRgYGBgYIAAA
BEA+BEDMBEABARgoFRUVFRAQ////gAsQEDMQEBAQEBAVCBA4Gzj+GEU4Gzg4GzgTGBgoOBs4Exgl
7xAVFQUVFeEVFRUVFRT5FRWAFRT5FQgQOBs4ExgoOBs4ExgYKDgbGAAABgEnKGEdAgAbOBMVFeEV
FRUVFRT5FQgQOBs4ExgoOBs4ExgmABs4ExgoOBs4ExhlGAAABhgn9wAmYSkCABs4ExgoOBs4ExgQ
EAsQEDMQGzgTGEX3ABAAANwQIEUYZAAGABDbABAAABjEAj9ADjs=



==15293==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x557cf29f6be7 bp 0x7ffd788ea1e0 sp 0x7ffd788ea1d8
READ of size 8 at 0x60700000ccc0 thread T0
    #0 0x557cf29f6be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
    #1 0x557cf29f6f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #2 0x557cf29f81f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #3 0x557cf29b630d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x557cf29b5ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x557cf29b5727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x557cf29b57b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x557cf29b57dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x557cf29b4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x557cf2970136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x557cf296daa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x557cf2883c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x557cf288589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x557cf288311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x557cf2870f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x557cf287982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x557cf2871d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x557cf295b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x557cf283c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x557cf283a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f01c74ce2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x557cf2839749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60700000ccc0 is located 0 bytes to the right of 80-byte region [0x60700000cc70,0x60700000ccc0)
allocated by thread T0 here:
    #0 0x7f01c7d3c090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x557cf2949e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x557cf29f6c4e in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cc4e)
    #3 0x557cf29f6f79 in rl_kill_text (/home/dualbus/src/gnu/bash-build/bash+0x23cf79)
    #4 0x557cf29f81f9 in rl_unix_line_discard (/home/dualbus/src/gnu/bash-build/bash+0x23e1f9)
    #5 0x557cf29b630d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x557cf29b5ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #7 0x557cf29b5727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #8 0x557cf29b57b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #9 0x557cf29b57dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #10 0x557cf29b4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #11 0x557cf2970136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #12 0x557cf296daa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #13 0x557cf2883c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #14 0x557cf288589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #15 0x557cf288311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #16 0x557cf2870f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #17 0x557cf287982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #18 0x557cf2871d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #19 0x557cf295b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #20 0x557cf283c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #21 0x557cf283a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #22 0x7f01c74ce2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6) in _rl_copy_to_kill_ring
Shadow bytes around the buggy address:
  0x0c0e7fff9940: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9950: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c0e7fff9980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa 00 00
=>0x0c0e7fff9990: 00 00 00 00 00 00 00 00[fa]fa fa fa fd fd fd fd
  0x0c0e7fff99a0: fd fd fd fd fd fa fa fa fa fa 00 00 00 00 00 00
  0x0c0e7fff99b0: 00 00 00 03 fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c0e7fff99c0: 02 fa fa fa fa fa 00 00 00 00 00 00 00 00 00 06
  0x0c0e7fff99d0: fa fa fa fa fd fd fd fd fd fd fd fd fd fd fa fa
  0x0c0e7fff99e0: fa fa 00 00 00 00 00 00 00 00 00 fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15293==ABORTING

INPUT
AAIbLbUAAlsQGDIYFxwYGBkTGEX3ABAAANwYGBgwGAAAAEAYGBggAAAEANIY+xcYGRgYGBgYIAAA
BEAjBEDMBEABARgoFRUVFRAQ////gAsQEDMQEBAQEBAVCBA4Gzj+GEU4GzgTGCYQEBUdBRUV4RUV
FRUVFPkVCBA4GzgTGCg4GzgTGBgoOBs4ExgmEBAVFQUVFeEVFRUVFRT5FRUVFRRkFQgQOBs4Exgo
OBs4ExgYKDgbGAAABgEnKGEdAgAbOBMVFeEVFRUVFRT5FQgQOBs4ExgoOBs4ExgmABs4ExgoOBs4
ExhlGAAABhgn9wAmYR0CABs4ExgoOBs4ExgQEAsQEDMQGzgTGEX3ABAAANwQIEUYZAAGABDbABAA
ABjEAj9ADjs=

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:44:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLW0F-0001pG-Lc
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:44:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41462)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLW0B-0001nW-3p
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:44:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLW06-0006lo-Si
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:44:03 -0400
Received: from mail-oi0-x235.google.com ([2607:f8b0:4003:c06::235]:34576)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLW06-0006kr-Iu
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:43:58 -0400
Received: by mail-oi0-x235.google.com with SMTP id b6so8919511oia.1
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:43:58 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=mFXjnmcaCtOCj1Xwarg9ejoTtWZkZJ3xD8VeVz4/dEw=;
	b=SmRr1I7NaiTypbWpILqm74NtH/IEF0aUJ/RR7OjAMYVH61w8CB1Hx1zTJ4+oQx8M0P
	5cf6y5ws7Bc5Q5unGVrlNTCxU2enK/IsRpUMYg1bVFnbiUYrnFI6e7PB3vgAVp/+nJ2d
	cSt9IMJDliTkv1mRGZBNmIjUXEmV7FtOjM6dq7BFGr/iBk4y0hfXgqqAMmdWql8QXXWd
	CLQzz6e6FmaeJZsln3a5GWadsRgmtVQD0y0AUokg4NyhdTd65MPKyLAkYBYMOKTh+iIN
	q7g75wfQI8XO3ALeLbYDhURezuHGu+FU5pSh41d9yTokeS0DEE6KklKusBwQX9pOX+nq
	GNiQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=mFXjnmcaCtOCj1Xwarg9ejoTtWZkZJ3xD8VeVz4/dEw=;
	b=HEiKEEcDlA2wiw0qmpnfpwo9Hgp7zHGdojNV/LTtsfi7VGHvAP+tT12KVJqtZ4dC6B
	eZXlJl3xcyRljI+Qs4e7HPThArGGFiOAi2gVcxjNtkHzL5PgLUSBrIynTMNLqUcHvG6x
	Ztm4H11ZTIrtpd8mLBCL6DePcVC5D1D01Fwr5qrsebwJFHD1ciDPcPsrB1K/sv8BRbiq
	cAntZ7O2U6GeiwY5rZBTQExil0rP1QnRoV0JkWkg8lT5YW3yXTY1yRnhUeIPsy1cVEL9
	2t3gNuLWIDe9WrHMFDLYa+kB8xkhPBkwCfGNIFSmvDUkx76dGIf8ekNmmfb6TooHQ/rG
	eg4A==
X-Gm-Message-State: AKS2vOyQOm2HIhxNc8kFRpDV6Pm6WqOjb5yu56c0GJm9VgFLG2d1NDXy
	4bUmMPOIx7Nl8qct
X-Received: by 10.202.72.20 with SMTP id v20mr3365541oia.44.1497537836793;
	Thu, 15 Jun 2017 07:43:56 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id t76sm164049ota.14.2017.06.15.07.43.55
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:43:56 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:43:54 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in rl_search_history
Message-ID: <20170615144354.uctfat2cgl4gjk3z@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:44:07 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==15910==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x55794384fd88 bp 0x7ffd35b10720 sp 0x7ffd35b10718
READ of size 1 at 0x61100000977f thread T0
    #0 0x55794384fd87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x557943850cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x55794384b7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #3 0x55794382130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x557943820ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x557943820727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x5579438207b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x5579438207dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x55794381fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x5579437db136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x5579437d8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x5579436eec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x5579436f089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x5579436ee11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x5579436dbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x5579436e482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x5579436dcd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x5579437c60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x5579436a7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x5579436a58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7fd76993a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x5579436a4749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7fd76a1a7d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5579437b4d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x557943822220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x5579438220c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x55794378fc28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x5579437db096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x5579437d8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x5579436eec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x5579436f089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x5579436ee11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x5579436dbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x5579436e482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x5579436dcd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x5579437c60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x5579436a7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x5579436a58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7fd76993a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15910==ABORTING

INPUT
AAEbLbUA9loQGDIYLhwYGBkYGJgYGBj4FwAYGBj/HgAAAEAYGBgYEhISEhISEhISEhISEhISEhIS
EhISEhISEhISEhJFbFIT+gH6Av9yzGxuRWxSE/oB+jBkAOpsgv8AIOSwzIwAAGwGbG5sXGxsIID/
//93d0B3d2BOZ2dn+vr6+mwqF+xsPQsaAQCOl36Ojhs9IFcPEAA8PCuAjgAB/+4APDwxQAuCYKUA
/n9bHlUAAQgAKFcZZf//XV07XX8c/xsF



==23875==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977e at pc 0x55e5af432d88 bp 0x7ffcf0a9ec10 sp 0x7ffcf0a9ec08
READ of size 1 at 0x61100000977e thread T0
    #0 0x55e5af432d87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x55e5af433cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x55e5af42e7cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #3 0x55e5af40430d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x55e5af403ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x55e5af403727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x55e5af4037b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x55e5af4037dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x55e5af402e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x55e5af3be136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x55e5af3bbaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x55e5af2d1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x55e5af2d389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x55e5af2d111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x55e5af2bef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x55e5af2c782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x55e5af2bfd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x55e5af3a90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x55e5af28a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x55e5af2888da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f0c847b62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x55e5af287749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977e is located 2 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f0c85023d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55e5af397d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55e5af405220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x55e5af4050c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x55e5af372c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x55e5af3be096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x55e5af3bbaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x55e5af2d1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x55e5af2d389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x55e5af2d111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x55e5af2bef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x55e5af2c782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x55e5af2bfd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x55e5af3a90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x55e5af28a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x55e5af2888da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f0c847b62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fd fd fd fd fd fd fd fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c227fff92b0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23875==ABORTING

INPUT
/wIbLbUA/38QfzsYFRwYGBkYGJgYGBj4F14wGAAAAEAEANAY+xcYGRg9C0AARRgDJ3hs51seLRAA
EFsQAQASEhITR0fHR0cTUkdHR0dAzARAAQEYKDgLJ3iA/yhhHUD/gP8oYR1A/xsTVSguGzgM1X88
PDw9f0DMBEABARgo/wAGGCdzABAAAKnw8PAbzC/I0+qvAQDMIAn9AIAAR0dHR0dHR0dHSUdHzMzQ
0NDQYWFhYWH/AADMzCkDARsSJAMA/xLMzMjT6q8BAMwgCf0AgAhHR0dHR0dHR0dJR0cSEhMSEszM
f6kTISEhISFHR0dHRxISE1ISzMx/qRMhGiEhISEhISEhISHM0szMzKAXf4DOEhISAxISEgMSEhIT
R0fHR0cTUkdHR0dHR0dHEhITUhLMzH+pExIgAxISAY+PAAD///9/gM4SEjMDEhISj4+qHAD//xCA
gBIaAxISEgES5kdHR0eAIxKwzH+pj4uPj3mPj48cAP///39AAAAA9QIBGxLxEQAAAEDMz8xuE1Dg
8GdnZ26A/wCPAPP/AAAG/QAD6PmAABPoIiAA6AMAAPr//38cyM5/8RIOEhISAxISIAMSEgGPEBcA
///wf4ASEgMSEhITEhITEp5vAQA8VBwG/xIDEhIgAxISAY+PAAD///9/gM4SEhIDA+j0DwASEgMB
GxI0LRITj48A/39Xj2SPjhISEgMA/xKPj4+ijwJkIg==



==29731==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977e at pc 0x56359e3dfd88 bp 0x7ffc11f40910 sp 0x7ffc11f40908
READ of size 1 at 0x61100000977e thread T0
    #0 0x56359e3dfd87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x56359e3e0cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x56359e3db7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #3 0x56359e3b130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x56359e3b0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x56359e3b0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x56359e3b07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x56359e3b07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x56359e3afe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x56359e36b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x56359e368aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x56359e27ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x56359e28089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x56359e27e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x56359e26bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x56359e27482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x56359e26cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x56359e3560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x56359e237401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x56359e2358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f1ea74872b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x56359e234749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977e is located 2 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f1ea7cf4d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56359e344d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56359e3b2220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x56359e3b20c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x56359e31fc28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x56359e36b096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x56359e368aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x56359e27ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x56359e28089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x56359e27e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x56359e26bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x56359e27482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x56359e26cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x56359e3560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x56359e237401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x56359e2358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f1ea74872b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29731==ABORTING

INPUT
AAAbLbUA9loQGDIYLhwYGBkYGJgYGBj4FwAEGBgwHgAAAEAYGBgYAOADgP85+xcYGRg9C0AAdGB3
aOgDAAAAAFNgPDxA0tJMTExMTExMTEwkf//6/97g+v/6DjUAggAAcknpTE1Nj3+PzhIAAACA/xLM
zACA//8BANV4Hf0AgAAAAO3AEBISEgMSQAAA8hETEhLMEughISEAAABkzMzMIBdlgM4SEhIDEhIS
AxJAFgDyERMSEszMf6kTEiADEhIGjwAABABb/3+AxhISEgMSEhJvj6ocAP//EIAQ6BL0EhKAEhoD
EhISARIDAID/AIAjErDMf6mPi4+PeY+PfwAR////f4DaEhISJAH6EvERjxwA////f4DaEhISAwEb
AAABAPYAEhIDARsSNC0SE1Dg8GdnZ257IACPAPP/AAAGAAAD6PmAAP/oIiD8//8/s//vX2eK////
fxzIzoASEg4SEhIDEhISEgGPgAAACwMAAABAEhIBj48yAP//8H+A/9h/gM4SEjMDEhISAxISEhMx
EgMA/xLMzACA//8BAMyAHf0AgADOEhIzAxISEgMSEhITEhIDAP8SzMwAgP//AQDMgB39AAAA7cAQ
APIRExISzMx/qRMSIAMSEgaPAAAEAFv/f4+Lj495j49/ABH///9/gNoSEhIkAfoSEhISExISzMx/
jxwA4v//dIASEhIDEh8gAxISAY+PAAD///+dgM4SEhISEgCd9gASgBIDARsSNC0SE4+PAwB/V49k
j44SEhLp//8Sg4+Pj48CCiI=



==29732==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x562ef1644d88 bp 0x7ffdd726f7a0 sp 0x7ffdd726f798
READ of size 1 at 0x61100000977f thread T0
    #0 0x562ef1644d87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x562ef1645cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x562ef16407ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #3 0x562ef161630d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x562ef1615ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x562ef1615727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x562ef16157b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x562ef16157dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x562ef1614e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x562ef15d0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x562ef15cdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x562ef14e3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x562ef14e589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x562ef14e311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x562ef14d0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x562ef14d982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x562ef14d1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x562ef15bb0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x562ef149c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x562ef149a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7fd6d39212b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x562ef1499749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7fd6d418ed28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x562ef15a9d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x562ef1617220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x562ef16170c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x562ef1584c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x562ef15d0096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x562ef15cdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x562ef14e3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x562ef14e589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x562ef14e311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x562ef14d0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x562ef14d982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x562ef14d1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x562ef15bb0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x562ef149c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x562ef149a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7fd6d39212b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29732==ABORTING

INPUT
AAAbLbUA9loQGDIYLhwYGBkYGJgYGBj4FwAYGBgwHgAAAEAYGBgYAOADgP85+xcYGRg9C0AAlGB3
aOgDAAAAAFNgPDxg0tJMTExMTExMTEwkf//6/97g+v/6DjUAggAAcknpTE1Nj3+PzhISEgMA/xLM
zACA//8BANWAHf0AgAAAAO3AEBISEgMSQAAA8hETEhLMEgAhISEAAABkzMzMIBdlEhIDEkAWAPIR
ExISzMx/qRMSIAMSEgaPAAAEAFv/aIDOEhISAxISEmSPqhwA//8QgBDoEhITEoASGgMSEhIBEgMA
gP8AgCMSsMx/qY+Lj495j49/ABH///9/gNoAEhIkAfoS8RGPHAD///9/gNoSEhIDARsAAAEA9gAS
EgMBGxI0LRITUODwZ2dnbnsgAI8A8/8AAAYAAAPo+YAAE+giIPz//z+z/+9fZ4r///9/HMjOgBIS
DhISEgMSEhISAY+AAAALAwAAAEASEgGPjzIA///wf4D/2H9lzhIBMwMSEhIDEhISExISAwD/EszM
AID//wEAzIAd/QCAAM4SEjMDEhISAxISEhMSEgMA/xLMAAAAAf8BAMyAHf0AAADtwBDoEhITEhLM
zH+PHAD///90gBISEgMSHyADEhIBj48AAP///52AzpqPZI+OEhIS6f//EoOPj4+PAgoi



==29733==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x56211a7b6d88 bp 0x7ffd3baee1a0 sp 0x7ffd3baee198
READ of size 1 at 0x61100000977f thread T0
    #0 0x56211a7b6d87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x56211a7b7cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x56211a7b27ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #3 0x56211a78830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x56211a787ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x56211a787727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x56211a7877b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x56211a7877dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x56211a786e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x56211a742136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x56211a73faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x56211a655c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x56211a65789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x56211a65511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x56211a642f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x56211a64b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x56211a643d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x56211a72d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x56211a60e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x56211a60c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f4820b292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x56211a60b749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f4821396d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56211a71bd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56211a789220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x56211a7890c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x56211a6f6c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x56211a742096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x56211a73faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x56211a655c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x56211a65789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x56211a65511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x56211a642f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x56211a64b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x56211a643d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x56211a72d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x56211a60e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x56211a60c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f4820b292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29733==ABORTING

INPUT
AAAbLbUA9loQGDIYLhwYGBkYGJgYGBj4FwAYGBgwHgAAAEAYGBgYAOADgP85+xcYGRg9C0AAlGB3
aOgDAAAAAFNgPDxg0tJMTExMTExJTEwkf//6/97g+v/6DjUAggAAcknpTE1Nj3+PzhISEgMA/xLM
zACA//8BANWAHf0AgAAAAO3AEBISEgMSQAAA8hETEhLMEgAhISEAAABkzMzMIBdlgM4SEhIDEhIS
A/hAFgDyERMSEszMf6kTEiADEhIGjwAABABb/3+AzhISEgMSEhJkj6ocAP//EIAQ6BISExKAEhoD
EhISARIDAID/AIAjErDMf6mPi4+PeY+PfwIR////f4DaEhISJAH6EvERjxwA////f4DaEhISAwEb
AAABAPYAEhIDARsSNC0SE1Dg8GdnZ257IACPAPP/AAAGAAAD6PmAAIAAIiD8//8/s//vX2eK////
fxzIyYASEg4SEgGPjzIA///wf4D/2H+AzhISMwMSEhIDEhISExISAwD/EszMAID//wEAzIAd8gCA
AM4SEjMDEhISAxISEhMSEgMA/xLMzACA//8BAMyAHf0AAADtwBDoEhITEhLMzH+PHAD///90gBIS
EgMSHyADEhIBj48AAP///52AzhISEhISAJ32ABISAwEbEjQtEhOPjwMAf1ePZI+OEhIS6f//QIOP
j4+PAgoi



==29734==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x5611c6942d88 bp 0x7fffd2ff9ed0 sp 0x7fffd2ff9ec8
READ of size 1 at 0x61100000977f thread T0
    #0 0x5611c6942d87 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22ad87)
    #1 0x5611c6943cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #2 0x5611c693e7ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #3 0x5611c691430d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #4 0x5611c6913ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #5 0x5611c6913727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #6 0x5611c69137b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #7 0x5611c69137dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #8 0x5611c6912e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #9 0x5611c68ce136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #10 0x5611c68cbaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #11 0x5611c67e1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #12 0x5611c67e389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #13 0x5611c67e111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #14 0x5611c67cef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #15 0x5611c67d782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #16 0x5611c67cfd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #17 0x5611c68b90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #18 0x5611c679a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #19 0x5611c67988da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #20 0x7f660833e2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #21 0x5611c6797749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61100000977f is located 1 bytes to the left of 256-byte region [0x611000009780,0x611000009880)
allocated by thread T0 here:
    #0 0x7f6608babd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5611c68a7d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5611c6915220 in readline_initialize_everything (/home/dualbus/src/gnu/bash-build/bash+0x1fd220)
    #3 0x5611c69150c6 in rl_initialize (/home/dualbus/src/gnu/bash-build/bash+0x1fd0c6)
    #4 0x5611c6882c28 in initialize_readline (/home/dualbus/src/gnu/bash-build/bash+0x16ac28)
    #5 0x5611c68ce096 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6096)
    #6 0x5611c68cbaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #7 0x5611c67e1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #8 0x5611c67e389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #9 0x5611c67e111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #10 0x5611c67cef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #11 0x5611c67d782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #12 0x5611c67cfd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #13 0x5611c68b90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #14 0x5611c679a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #15 0x5611c67988da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #16 0x7f660833e2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x22ad87) in _rl_isearch_dispatch
Shadow bytes around the buggy address:
  0x0c227fff9290: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c227fff92c0: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff92d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c227fff92e0: 00 00 fa fa fa fa fa fa fa fa fa fa fa fa fa[fa]
  0x0c227fff92f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9310: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c227fff9320: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c227fff9330: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29734==ABORTING

INPUT
AAAbLbUA9loQGDIYLhwYGBkYGJgYGBj4FwAYGBgwHgAAAEAYGBgYAOADgP85+xcYGRg9C0AAlGB3
aOgDAAAAAFNgPDxg0tJMTExMTExMTEwkf//6/97g+v/6DjUAggAAcknpTE1Nj3+PzhISEgMA/xLM
zACA//8BANWAHf0AgAAAAO3AEBISEgMSQAAA8hETEhLMEgAhISEAAABkzMzMIBdlgM4SEhIDEhIS
AxJAFgDyERMSEszMf6kTEiADEhIGjwAABABb/3+AzhIS/wASEhJkj6ocAP//EIAQ6BISExKAEhoD
EhISARIDAID/AIAjErDMf6mPi4+PeY+PfwAR////f4DaEhISJAH6EvERjxwA////f4DaEhISAwEb
AAABAPYAEhIDARsSNC0SE1Dg8GdnZ257IACPAPP/AAAGAAAD6PmAABPoIiD8//8/s//vX2eK////
fxzIzoASEg4SEhIDEhISEgGPgAAACwMAAABAEhIBj48yAP//8H+A/9h/gM4SEjMDEhISAxISEhMS
EgMA/xLMzACA//8BAMyAHf0AgADOEhIzAxISEgMSEhITEhIDAP8SzMwAgP//AQDMgB39AAAA7cAQ
6BISExISzMx/jxwA////dIASEhIDEh8gAxISAY+PAAD///+dgM4SEhISEgCd9gASEgMBGxI0LRIT
gI8DAH9Xj2SPjhISEun//xKDj4+PjwIKIg==

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:45:05 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLW1B-0002ac-IY
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:45:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41711)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLW15-0002VK-P5
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:45:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLW12-0007EQ-4G
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:44:59 -0400
Received: from mail-ot0-x235.google.com ([2607:f8b0:4003:c0f::235]:34010)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLW11-0007EI-RI
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:44:56 -0400
Received: by mail-ot0-x235.google.com with SMTP id r67so11217630ota.1
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:44:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=PSIEx7O6KqMmEQzL7USXt+5LzClSevDTbStUpIyafs4=;
	b=M+ydGUN+qfjN1Xn9t7SjSzn6ypyb9cFCYisreWYPWEBAj4w6+ENq3q/PVkvDjjPXZK
	nF/CZ1BwjKli8b6WC3FRiIHtMCeaPEA419OdH/iQgmN10pSzk/f8wZG5X8mFADAPPO2K
	Ce7i9sb++vd/ukNMtcR0bd7jnc/5g4bgAQffX2iuhC9/IpPDSialM480zPEz/i9pPbny
	YgKW/CC7ZnzHFi7F9h4TlSRwoI5C11+g6XCnaiPUikOMWHH6HBB+pqtVaVSxgEfWlB/7
	wnHWY3o7e6AyeXrzR0LsNDaaO5L0p6hh7UL6WA9NLu8SFN6rOffxWjTwU3CACiXrijWf
	WL1Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=PSIEx7O6KqMmEQzL7USXt+5LzClSevDTbStUpIyafs4=;
	b=DdjIM9JK2YUfu8pVNlE5IBBKMWyIDDxTyuUbAMWisPoVUJDMZIdIMIaJyl2JO7xwHX
	luLcSGZmy5LY1JKR+w32tVwgvOI6huwyKMoigzROmOpAvXx9vXw5b2MNgIp60J3HCovC
	s2mZ+T4dUyaxdEUseA6n8RG7AGKhFvcBJ+ipyEdleUzFfO/+CdbWZcEtYr93A+6qPPbV
	EPi7SWLh1oMzgWXL0IZnpmPzID1RBTnAsliGWalRmrgti3sv46pXPGFk3R2QugB2XOD4
	8GngnRckpNo2O7womj5PeE3ONjr5GC6Ta/7XTDDjkK72RIVtHWdP6jzguBRDUPvpa4lE
	hALA==
X-Gm-Message-State: AKS2vOxiJgMYql71LhQRtzX41ZBo33zVyGk8j7zuhqsyhiZUylN8bcxE
	6V+nXcFTV+fe6epc
X-Received: by 10.157.3.45 with SMTP id 42mr3653110otv.234.1497537894421;
	Thu, 15 Jun 2017 07:44:54 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id d27sm159210ote.41.2017.06.15.07.44.53
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:44:54 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:44:52 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in shell_expand_line
Message-ID: <20170615144452.dlck7rudoiul4fbe@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:45:03 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.


==7938==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60c00000bd00 at pc 0x55ae5ef673f0 bp 0x7ffd16140ec0 sp 0x7ffd16140eb8
WRITE of size 1 at 0x60c00000bd00 thread T0
    #0 0x55ae5ef673ef in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1023ef)
    #1 0x55ae5ef999e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #2 0x55ae5ef784f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #3 0x55ae5ef79458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #4 0x55ae5efdaed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #5 0x55ae5f06130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x55ae5f061aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #7 0x55ae5f060ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55ae5f060727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55ae5f0607b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55ae5f0607dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55ae5f05fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55ae5f01b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55ae5f018aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55ae5ef2ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55ae5ef3089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55ae5ef2e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55ae5ef1bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55ae5ef2482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55ae5ef1cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55ae5f0060f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55ae5eee7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55ae5eee58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fd2fbb0c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55ae5eee4749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60c00000bd00 is located 0 bytes to the right of 128-byte region [0x60c00000bc80,0x60c00000bd00)
allocated by thread T0 here:
    #0 0x7fd2fc379d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55ae5eff4d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55ae5ef668d7 in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1018d7)
    #3 0x55ae5ef999e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #4 0x55ae5ef784f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #5 0x55ae5ef79458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #6 0x55ae5efdaed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #7 0x55ae5f06130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55ae5f061aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55ae5f060ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55ae5f060727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55ae5f0607b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55ae5f0607dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55ae5f05fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55ae5f01b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55ae5f018aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55ae5ef2ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55ae5ef3089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55ae5ef2e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55ae5ef1bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55ae5ef2482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55ae5ef1cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55ae5f0060f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55ae5eee7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55ae5eee58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fd2fbb0c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x1023ef) in string_extract_double_quoted
Shadow bytes around the buggy address:
  0x0c187fff9750: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c187fff9760: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c187fff9770: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c187fff9780: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c187fff9790: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c187fff97a0:[fa]fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
  0x0c187fff97b0: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
  0x0c187fff97c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 03 fa
  0x0c187fff97d0: fa fa fa fa fa fa fa fa fd fd fd fd fd fd fd fd
  0x0c187fff97e0: fd fd fd fd fd fd fd fa fa fa fa fa fa fa fa fa
  0x0c187fff97f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7938==ABORTING

INPUT
suo/7TeANzc3Nzc0LDc2NoAAGwo3NxstSjcbLTQYf/82NjY2NjY2ADz/MxB/PP8qJCgoHi0pKT4p
AP8p/AD/KiRXV/8AfwB0joMASKAAPIAkKAABmJiYkpj09PT0mEr/mJiYmJiYmJiYmAB/mACARACr
AAKOPBkQADz/LiRDnZ42GVZ/////7z8oKCgH7OupKQCAKSkA/ygoACEoGyzr66uAqyE88PDw8AD/
MxDwARB/Sv8qJCgoHikpKT4pAP8AEAD8COhX/wB9xEAi+wEAAZh9mJKY9AADhARAf9obBQ==



==20067==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60400000767a at pc 0x5587995ef3f0 bp 0x7fffa1979d60 sp 0x7fffa1979d58
WRITE of size 1 at 0x60400000767a thread T0
    #0 0x5587995ef3ef in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1023ef)
    #1 0x5587996219e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #2 0x5587996004f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #3 0x558799601458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #4 0x558799662ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #5 0x5587996e930d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x5587996e9aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #7 0x5587996e8ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x5587996e8727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x5587996e87b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x5587996e87dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x5587996e7e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x5587996a3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x5587996a0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x5587995b6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x5587995b889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x5587995b611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x5587995a3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x5587995ac82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x5587995a4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55879968e0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55879956f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55879956d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f1f493702b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55879956c749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60400000767a is located 0 bytes to the right of 42-byte region [0x604000007650,0x60400000767a)
allocated by thread T0 here:
    #0 0x7f1f49bddd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55879967cd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5587995ee8d7 in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1018d7)
    #3 0x5587996219e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #4 0x5587996004f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #5 0x558799601458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #6 0x558799662ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #7 0x5587996e930d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x5587996e9aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x5587996e8ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x5587996e8727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5587996e87b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5587996e87dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x5587996e7e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x5587996a3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x5587996a0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x5587995b6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x5587995b889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x5587995b611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x5587995a3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5587995ac82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x5587995a4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55879968e0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55879956f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55879956d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f1f493702b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x1023ef) in string_extract_double_quoted
Shadow bytes around the buggy address:
  0x0c087fff8e70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c087fff8e80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c087fff8e90: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c087fff8ea0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c087fff8eb0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
=>0x0c087fff8ec0: fa fa 00 00 00 00 00 fa fa fa 00 00 00 00 00[02]
  0x0c087fff8ed0: fa fa fd fd fd fd fd fa fa fa fd fd fd fd fd fd
  0x0c087fff8ee0: fa fa fd fd fd fd fd fd fa fa fd fd fd fd fd fa
  0x0c087fff8ef0: fa fa fd fd fd fd fd fa fa fa fd fd fd fd fd fa
  0x0c087fff8f00: fa fa fd fd fd fd fd fa fa fa fd fd fd fd fd fa
  0x0c087fff8f10: fa fa fd fd fd fd fd fa fa fa fd fd fd fd fd fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==20067==ABORTING

INPUT
Gz3uP0hlSCZIA5AAEAAACz09WD45OBo8STweNTwAAAEoGQD/GAAbpqempqamXiRbHlUAAQAEABkb
Dhs2PEwBPzwlADw8bhk8HjwAAQAFAF1NXV1FXSrxXWALgYDvAGAEKyRbHlUAsV4kWx5VAAEABAAZ
BFVVVVVVVW5VNxsClhT//xSWkBsk+gkDVSIFGxsgGyQbZB8QAAAJCQkJBAkJCQkqAKEUAnwCG1QA
lf3//+9/AKEA6ip//xsAAIDplBQbAnRTJCcaAi8uCQkJBQAAECAJCQMJBAkJCQkqAKEUAnwCG1Qk
KAAAAeAvFJZkAAAAKgCXFAL//wXeGwU=



==21184==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60300000ba2b at pc 0x55cb10a913f0 bp 0x7ffed66d10c0 sp 0x7ffed66d10b8
WRITE of size 1 at 0x60300000ba2b thread T0
    #0 0x55cb10a913ef in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1023ef)
    #1 0x55cb10ac39e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #2 0x55cb10aa24f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #3 0x55cb10aa3458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #4 0x55cb10b04ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #5 0x55cb10b8b30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x55cb10b8baef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #7 0x55cb10b8aee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55cb10b8a727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55cb10b8a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55cb10b8a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55cb10b89e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55cb10b45136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55cb10b42aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55cb10a58c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55cb10a5a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55cb10a5811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55cb10a45f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55cb10a4e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55cb10a46d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55cb10b300f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55cb10a11401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55cb10a0f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7fdf1e9ad2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55cb10a0e749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60300000ba2b is located 0 bytes to the right of 27-byte region [0x60300000ba10,0x60300000ba2b)
allocated by thread T0 here:
    #0 0x7fdf1f21ad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55cb10b1ed95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55cb10a908d7 in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1018d7)
    #3 0x55cb10ac39e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #4 0x55cb10aa24f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #5 0x55cb10aa3458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #6 0x55cb10b04ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #7 0x55cb10b8b30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55cb10b8baef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55cb10b8aee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55cb10b8a727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55cb10b8a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55cb10b8a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55cb10b89e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55cb10b45136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55cb10b42aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55cb10a58c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55cb10a5a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55cb10a5811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55cb10a45f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55cb10a4e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55cb10a46d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55cb10b300f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55cb10a11401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55cb10a0f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fdf1e9ad2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x1023ef) in string_extract_double_quoted
Shadow bytes around the buggy address:
  0x0c067fff96f0: 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa
  0x0c067fff9700: 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00
  0x0c067fff9710: fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00
  0x0c067fff9720: 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa
  0x0c067fff9730: 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00
=>0x0c067fff9740: fa fa 00 00 00[03]fa fa 00 00 00 00 fa fa 00 00
  0x0c067fff9750: 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa
  0x0c067fff9760: 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00
  0x0c067fff9770: fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00
  0x0c067fff9780: 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00 fa fa
  0x0c067fff9790: 00 00 00 00 fa fa 00 00 00 00 fa fa 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==21184==ABORTING

INPUT
EAMYNQIqDhshFszM/cBA///YV8zMdQAAABAAACIAzNjMzK3MzX+rAEBcXFxcJCQoAAIAght/f39/
f11/XH9/f39/f39/fvyAXJhcXFxcXMzMderMkQAAAAAiAMzYzHnMyM1cXFxcXFRcXFwAXFxcXFwk
JBsFAAsiAMzYzMzMzM1cXFxcXFRcXH0AXFxcXFwkJBsF



==22415==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60f00000ef03 at pc 0x55db38a9d3f0 bp 0x7ffce85934f0 sp 0x7ffce85934e8
WRITE of size 1 at 0x60f00000ef03 thread T0
    #0 0x55db38a9d3ef in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1023ef)
    #1 0x55db38acf9e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #2 0x55db38aae4f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #3 0x55db38aaf458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #4 0x55db38b10ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #5 0x55db38b9730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x55db38b97aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #7 0x55db38b96ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x55db38b96727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x55db38b967b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x55db38b967dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x55db38b95e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x55db38b51136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x55db38b4eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x55db38a64c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x55db38a6689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x55db38a6411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x55db38a51f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x55db38a5a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x55db38a52d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x55db38b3c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x55db38a1d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x55db38a1b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f7fff6e62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x55db38a1a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x60f00000ef03 is located 0 bytes to the right of 163-byte region [0x60f00000ee60,0x60f00000ef03)
allocated by thread T0 here:
    #0 0x7f7ffff53d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55db38b2ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55db38a9c8d7 in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1018d7)
    #3 0x55db38acf9e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #4 0x55db38aae4f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #5 0x55db38aaf458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #6 0x55db38b10ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #7 0x55db38b9730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55db38b97aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55db38b96ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55db38b96727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55db38b967b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55db38b967dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55db38b95e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55db38b51136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55db38b4eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55db38a64c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55db38a6689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55db38a6411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55db38a51f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55db38a5a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55db38a52d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55db38b3c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55db38a1d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55db38a1b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f7fff6e62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x1023ef) in string_extract_double_quoted
Shadow bytes around the buggy address:
  0x0c1e7fff9d90: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9da0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9db0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9dc0: fa fa fa fa fa fa fa fa fa fa fa fa 00 00 00 00
  0x0c1e7fff9dd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c1e7fff9de0:[03]fa fa fa fa fa fa fa fa fa 00 00 00 00 00 00
  0x0c1e7fff9df0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fa
  0x0c1e7fff9e00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9e10: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9e20: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c1e7fff9e30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22415==ABORTING

INPUT
GwEWAAF/AMwALugAAH8Wf5ZXAP9///hkXWZdRGRkAAB/luT/4v8gYAsBgCRa3QIikl4kWyNVCfYQ
APo7APsEAAsEAAvfV4CBGVMa+RtJTU1NI1eATACYK3lIJBt5zUtLJiYmJglLS0tLS0tLS0tLS0tL
S0tLS0tLaUtL/0tL8kuDTU0WFJQgAAAAeVVjVWjVVVVVVkI3GwKWNP//ABlTGvkbSf////hkXWZd
RGRkTST/3sgATU1NEG9hTfz/gF1NVwD/f//4ZH9dZl1EZGRNJCgBTU1NTU1JTU3xTN9N+UxvTU1G
Tf8QAHR0EF1NCBuA/wAbBQ==



==20379==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x602000007ef9 at pc 0x564df0fe33f0 bp 0x7ffe40f0cbe0 sp 0x7ffe40f0cbd8
WRITE of size 1 at 0x602000007ef9 thread T0
    #0 0x564df0fe33ef in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1023ef)
    #1 0x564df10159e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #2 0x564df0ff44f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #3 0x564df0ff5458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #4 0x564df1056ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #5 0x564df10dd30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #6 0x564df10ddaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #7 0x564df10dcee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #8 0x564df10dc727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #9 0x564df10dc7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #10 0x564df10dc7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #11 0x564df10dbe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #12 0x564df1097136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #13 0x564df1094aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #14 0x564df0faac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #15 0x564df0fac89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #16 0x564df0faa11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #17 0x564df0f97f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #18 0x564df0fa082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #19 0x564df0f98d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #20 0x564df10820f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #21 0x564df0f63401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #22 0x564df0f618da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #23 0x7f4f9ae362b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #24 0x564df0f60749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x602000007ef9 is located 0 bytes to the right of 9-byte region [0x602000007ef0,0x602000007ef9)
allocated by thread T0 here:
    #0 0x7f4f9b6a3d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x564df1070d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x564df0fe28d7 in string_extract_double_quoted (/home/dualbus/src/gnu/bash-build/bash+0x1018d7)
    #3 0x564df10159e7 in expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1349e7)
    #4 0x564df0ff44f3 in call_expand_word_internal (/home/dualbus/src/gnu/bash-build/bash+0x1134f3)
    #5 0x564df0ff5458 in expand_word (/home/dualbus/src/gnu/bash-build/bash+0x114458)
    #6 0x564df1056ed3 in shell_expand_line (/home/dualbus/src/gnu/bash-build/bash+0x175ed3)
    #7 0x564df10dd30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x564df10ddaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x564df10dcee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x564df10dc727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x564df10dc7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x564df10dc7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x564df10dbe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x564df1097136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x564df1094aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x564df0faac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x564df0fac89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x564df0faa11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x564df0f97f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x564df0fa082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x564df0f98d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x564df10820f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x564df0f63401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x564df0f618da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f4f9ae362b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x1023ef) in string_extract_double_quoted
Shadow bytes around the buggy address:
  0x0c047fff8f80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff8f90: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff8fa0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff8fb0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff8fc0: fa fa fa fa fa fa fa fa fa fa fd fa fa fa 03 fa
=>0x0c047fff8fd0: fa fa 00 06 fa fa 02 fa fa fa fd fd fa fa 00[01]
  0x0c047fff8fe0: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c047fff8ff0: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c047fff9000: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c047fff9010: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c047fff9020: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==20379==ABORTING

INPUT
G+4AAEv///1////3gBqpoPkFBQUFBSQbG2OAEAUFBQUFJBVJSUlJSUlJSUlJSUlJSUlJSUlJSUlJ
SUlJ/yVBqLwkQkf5lgv8AOwA/yj/sLC0sLHTsLCwsACWfj4kGvYgQQZ8fe4kJDVTPCT0JADrl5eq
l5eXl5eXl5eXl5eXdJeXZAAAAECXl+vr6+uAfyIbG2OA+QUFBQUFJBsbY4AQBQUFBQUkAAAAfwUF
BQUFBQUFBQUFBQCTFAAkKAAbBQ==

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 10:55:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLWB4-0005sV-7q
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 10:55:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43691)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLWAJ-0005Xq-Hk
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:55:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLW9c-0001E7-49
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:54:31 -0400
Received: from mail-ot0-x235.google.com ([2607:f8b0:4003:c0f::235]:35528)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLW9a-0001B3-Q1
	for bug-bash@gnu.org; Thu, 15 Jun 2017 10:53:48 -0400
Received: by mail-ot0-x235.google.com with SMTP id 106so11408630otc.2
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 07:53:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=lL0Atw0iBKCY4Fk8cLueU/bHQ3IdPa09a+IGeTQ5AQ0=;
	b=KOT1ebVs8wjWQb/poUZHvXWSheYEN8bFvAIaxpnbBveQZI0WfAhxbRVy/oyGgZny5h
	i9tEBl7b6uUw9muLKN+IEShv7KCYVYnlk4FIX+YsSLjzWbEfp35KgVZmjr7dXYeI8ffC
	qZYZscsnhpbuJ474PmRRNUbFHmK/tFweAvPf+hJ1oL6WuC9TlGTsRuh+WLUNZTLkL1Et
	jonOofY3N2o4tvPXlg0zxvB6XumU+TwfqMCoG/EABspZ4/soqZz8ZXIqGDzGnI1U8rBS
	zugEUVcT/E89uJDVZ+ge8QmdYE62qx4ss0TyYYXL5+CdS3RxWeudm2glLENdLsBofGvm
	V1uQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=lL0Atw0iBKCY4Fk8cLueU/bHQ3IdPa09a+IGeTQ5AQ0=;
	b=EYEWyBGuLvf+4xdMW9er9NScYHomgZZULBiFp0oaUREgsY/mfX7aakhSw2V3qJuzDC
	4OqBAjLUORFh17JCDcN+adE+SJpxiBCrIHAExCusSePUg5VZ6S5s8fHxkvbhqSiRfPKL
	cNZ85ASVCyESsEvA3h9p7WKy0fZVcpM8RuSwnL2rLWfT2YY3qW3JrRx6TI1mS1kutVKz
	RnWv9dDBLhjQ+6PS0YbkESX+lYbdCOXt+NYgY2clmDS+uhmGNxlZukdQ/HOq9r80Blxv
	iBwa84iRaCyXJZ86YqF/g5pnBoulqhk5pgLG4tr3YIhMeiGzJyxqsSOULHeVJu6Q+cWf
	91jA==
X-Gm-Message-State: AKS2vOyZIkmcO/Q/PPoquJ+QZvVg2RWeo7bIlj1ip3UuZW1YXDwyDiJI
	/LoaNYuj8CZlpSKM
X-Received: by 10.157.13.130 with SMTP id 2mr3781145ots.51.1497538421682;
	Thu, 15 Jun 2017 07:53:41 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id w18sm148937oif.36.2017.06.15.07.53.36
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 07:53:40 -0700 (PDT)
Date: Thu, 15 Jun 2017 09:53:35 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-buffer-overflow in update_line
Message-ID: <20170615145335.nj65w7ytpfi2qsy6@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 14:55:16 -0000

Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
Sanitizer is followed by the base64 encoded crashing input.

By the stacktraces alone, it would seem that there are two or three bugs
still remaining. I'm sending all of the stacktraces anyways, in case my
assumptions are wrong.

==1814==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fd65690718c bp 0x7ffd35d24310 sp 0x7ffd35d23ac0
WRITE of size 189 at 0x62100002e100 thread T0
    #0 0x7fd65690718b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55ac9310c14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55ac9310a6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55ac93110214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55ac931261cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55ac93126902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55ac93126b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55ac930d430d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55ac930d4aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55ac930d3ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55ac930d3727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55ac930d37b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55ac930d37dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55ac930d2e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55ac9308e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55ac9308baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55ac92fa1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55ac92fa389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55ac92fa111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55ac92f8ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55ac92f9782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55ac92f8fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55ac930790f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55ac92f5a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55ac92f588da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fd6560f92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55ac92f57749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fd656967090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55ac93067e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55ac93106b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55ac930d33c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55ac930d379c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55ac930d37b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55ac930d37dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55ac930d2e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55ac9308e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55ac9308baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55ac92fa1c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55ac92fa389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55ac92fa111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55ac92f8ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55ac92f9782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55ac92f8fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55ac930790f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55ac92f5a401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55ac92f588da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fd6560f92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==1814==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN6QbNwABA5//kPo3kAc3DDcDSBaQR/lIPjcDkIADkP/0APEBDAwCAh6trZAbNzg3kBs3DDce
nm8BADwoPIAANuNIAwICDAACAh6trZAbNzg3kBs3DDcekEf5SABAAwEADH8A7/9A/wAE6g36De0=



==4498==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55c235da3253 bp 0x7ffca947da60 sp 0x7ffca947da58
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55c235da3252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55c235da16ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55c235d6a3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55c235d6a79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55c235d6a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55c235d6a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55c235d69e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c235d25136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c235d22aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c235c38c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c235c3a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c235c3811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c235c25f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c235c2e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c235c26d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c235d100f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c235bf1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c235bef8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd929bf02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55c235bee749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fd92a45dd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c235cfed95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55c235d9c9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55c235d9cc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55c235d6a090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55c235d6a7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55c235d69e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c235d25136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c235d22aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c235c38c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c235c3a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c235c3811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c235c25f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c235c2e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c235c26d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c235d100f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c235bf1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c235bef8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd929bf02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==4498==ABORTING

INPUT
G+ABb/sA+gDR0dHRGxgqBe9/AFw6/3+i6SR7JF4qKih5sbE+J81LQVteQUFWfRb6QBSuGxsAAAAQ
ACMAAAAbACp9IhovGRkZGRkXGR4ZGYsVWWAgG9jMuMy3AUoRgAFgGRkZGRkZGRkZGRkZGRmAFVlg
IBsZGUREgAAHDiooebFZYCAb2MzMzLcBShGAGRkZGRkZGQFgGRkZGRkZGRkZGRkZGRnNS/9bXlNB
Vn0W+kAaDmzHGwU=



==5021==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55f03a657253 bp 0x7ffca1017de0 sp 0x7ffca1017dd8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55f03a657252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55f03a6556ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55f03a61e3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55f03a61e79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55f03a61e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55f03a61e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55f03a61de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f03a5d9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f03a5d6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f03a4ecc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f03a4ee89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f03a4ec11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f03a4d9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f03a4e282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f03a4dad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f03a5c40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f03a4a5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f03a4a38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f5d90abe2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55f03a4a2749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f5d9132bd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f03a5b2d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f03a6509d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55f03a650c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f03a61e090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f03a61e7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f03a61de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f03a5d9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f03a5d6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f03a4ecc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f03a4ee89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f03a4ec11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f03a4d9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f03a4e282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f03a4dad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f03a5c40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f03a4a5401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f03a4a38da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f5d90abe2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==5021==ABORTING

INPUT
AAAAAIADKhz///OTnxkZGRkZGbwAABAAgCkZ/wAAABcZGRkZGRkXHBkZGRkSKry8GRn/OlAXEoCf
GRnvGRkZAAX//wUAAAGAnxkZ7xApKSkpKSkpKSkpKSkpKSkpKQCAKRkZGRn/OgAXGRkZGUtLV0tL
SwDa2tra2tra2hDa2tpLS97e3t7e3t7e3t7eQEo9AAFDSxwZGRkZGQe0vBk2/zoAAAABGRkZGRcX
ICw=



==6385==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f1d68a4b18c bp 0x7ffd907be500 sp 0x7ffd907bdcb0
WRITE of size 65 at 0x61900000cc80 thread T0
    #0 0x7f1d68a4b18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x555e950f814a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x555e950f66ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x555e950bf3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x555e950bf79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x555e950bf7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x555e950bf7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x555e950bee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x555e9507a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x555e95077aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x555e94f8dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x555e94f8f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x555e94f8d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x555e94f7af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x555e94f8382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x555e94f7bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x555e950650f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x555e94f46401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x555e94f448da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f1d6823d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x555e94f43749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000cc80 is located 0 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
allocated by thread T0 here:
    #0 0x7f1d68aaad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x555e95053d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x555e950f1442 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d442)
    #3 0x555e950f1c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x555e950bf090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x555e950bf7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x555e950bee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x555e9507a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x555e95077aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x555e94f8dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x555e94f8f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x555e94f8d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x555e94f7af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x555e94f8382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x555e94f7bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x555e950650f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x555e94f46401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x555e94f448da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f1d6823d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9990:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==6385==ABORTING

INPUT
GwMAAAB/ZxoAixn8GwQmUgD8AxUZVjyOjo6OZI6mjrBgPDxUgDz/fxkAf5COjl0nPQtg2DzFxcXS
EDwZEAAA//8A/I4AjqZkjo5dPD0LQDwZ/EMEJlIA/AMVGVY8jo6OjmSOQDwQ/AA8PQtAPBD8AAAo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AIoZAFAeyzw8O4AbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRYWFhYWFgABAAAAIDsZEN88PEwAfwBQHtn/AD1qlgAAdWA8jo6O
jo6PCK6OjisbPQtOVxkQADw8PAB/GQBQHss8PDwpKSkpKSkpKSkpNCkpPGarAP8AAAEoGQAABH//
KhtvABsF



==7939==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55cecbc83253 bp 0x7fff35e56700 sp 0x7fff35e566f8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55cecbc83252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55cecbc816ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55cecbc4a3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55cecbc4a79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55cecbc4a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55cecbc4a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55cecbc49e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55cecbc05136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55cecbc02aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55cecbb18c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55cecbb1a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55cecbb1811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55cecbb05f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55cecbb0e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55cecbb06d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55cecbbf00f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55cecbad1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55cecbacf8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa55742b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55cecbace749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fa557c98d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55cecbbded95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55cecbc7c960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55cecbc7cc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55cecbc4a090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55cecbc4a7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55cecbc49e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55cecbc05136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55cecbc02aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55cecbb18c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55cecbb1a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55cecbb1811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55cecbb05f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55cecbb0e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55cecbb06d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55cecbbf00f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55cecbad1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55cecbacf8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa55742b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7939==ABORTING

INPUT
GyoQExgaNUxSAAIAAAf/BwcZBwfojoCDYGBgAQCDEDw8PEg8PP9/GfdPAABZYC48i6sB//9/YEAA
AAMbGTw8PDw8PDw8//9///8ePDw8PDwBAI6Ojo6Ojo6OG46OpEM8PKRDPDw9C2IlGRAAPPwbADw8
PRujjqRDPDw9C2I2PDwBADwQADxu6BBXGRkAPDw8U38ZPIA8PAAAjpeOg44bfyRbHlUAAQAACy1X
gBsAAQAAKH8A/xs8PBoBAI6XjouOGz0gVxkQADw8K4B/GV1dXQAAAH8AX0VdTw5dUgA8PI6XjoOO
jo6OlpaWAQA8EBc8VQABAAALQFeA/+4APDw8OwuCYKUA/n9bHgBAAEAAKBka/xs2PDwBADwQADw8
bscQVxll//9/HP8bBQ==



==7940==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55b5adafd253 bp 0x7ffd5cf71a80 sp 0x7ffd5cf71a78
READ of size 4 at 0x619000002280 thread T0
    #0 0x55b5adafd252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55b5adafb6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55b5adac43c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55b5adac479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55b5adac47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55b5adac47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55b5adac3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b5ada7f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b5ada7caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b5ad992c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b5ad99489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b5ad99211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b5ad97ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b5ad98882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b5ad980d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b5ada6a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b5ad94b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b5ad9498da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbb9823d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55b5ad948749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fbb98aaad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b5ada58d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b5adaf6960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55b5adaf6c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55b5adac4090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55b5adac47d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55b5adac3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b5ada7f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b5ada7caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b5ad992c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b5ad99489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b5ad99211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b5ad97ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b5ad98882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b5ad980d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b5ada6a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b5ad94b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b5ad9498da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbb9823d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7940==ABORTING

INPUT
GyoQExgaNUxSAAIAAAf/BwcZBwfojoCDYGBgAQCDEDw8PEg8PP9/GfdPAABTYC48i6sB//9/YEAA
AAMbGTw8PDw8PDw8//9///8ePDw8PDwBAI6Ojo6Ojo6OG46OpEM8Sz0bjo6kQzw8xxBXGWX//3+O
jhuQjqRDPDw9G46OpEM8PD0LYiUZEAA8/BsAPDw9G6OOpEM8PD0LYjY8PAEAPBAAPG7oEFcZGQA8
PDxTfxk8gDw8AACOl46Djht/JFseVQABAAALLVeAGwABAAAofwD/Gzw8GgEAjpeOi44bPSBXGRAA
PDwrgH8ZXV1dAAAAfwBfRV1PDl1SADw8jpeOg46Ojo6WlpYBADwQFzxVAAEAAAtAV4D/7gA8PDw7
C4JgpQD+f1seAEAAQAAoGRr/GzY8PAEAPBAAPDxuwBBXGWX//38c/xsF



==7941==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55f2f166c253 bp 0x7ffd3f76f130 sp 0x7ffd3f76f128
READ of size 4 at 0x619000002280 thread T0
    #0 0x55f2f166c252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55f2f166a6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55f2f16333c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55f2f163379c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55f2f16337b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55f2f16337dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55f2f1632e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f2f15ee136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f2f15ebaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f2f1501c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f2f150389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f2f150111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f2f14eef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f2f14f782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f2f14efd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f2f15d90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f2f14ba401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f2f14b88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd88e0462b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55f2f14b7749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fd88e8b3d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f2f15c7d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f2f1665960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55f2f1665c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f2f1633090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f2f16337d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f2f1632e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f2f15ee136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f2f15ebaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f2f1501c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f2f150389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f2f150111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f2f14eef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f2f14f782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f2f14efd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f2f15d90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f2f14ba401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f2f14b88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd88e0462b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7941==ABORTING

INPUT
GyoQExgaNUxSAAIAAAf/BwcZBwfojoCDYGBgAQCDEEM8PEg8PP9/GfdPAABTYC48i6sB//9/YEAA
AAMbGTw8PDw8PDw8//9///9VAAEAAAtAV4A4AAEAACUZGv8INiY8AQA8EAA8bugyVxkZADw8OFN/
GTyAPDwAAI6XjoOOG38kWxZVAAEzAAtAV4AbAAEAACh/AP8bPDwaAQCOl46Ljhs9LlcZEAA8PCuA
fxldXV1dgAAAAF9FXU8OXVIAKysrKysrKwD+f1voA0AAQAAoGRoAHDY8PAEAPBAAPDxuxxBXGWX/
/38c/xsF



==9829==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55b442131253 bp 0x7ffd38c3d990 sp 0x7ffd38c3d988
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55b442131252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55b44212f6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55b4420f83c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55b4420f879c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55b4420f87b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55b4420f87dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55b4420f7e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b4420b3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b4420b0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b441fc6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b441fc889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b441fc611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b441fb3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b441fbc82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b441fb4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b44209e0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b441f7f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b441f7d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f2a5661a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55b441f7c749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f2a56e87d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b44208cd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b44212a9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55b44212ac75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55b4420f8090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55b4420f87d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55b4420f7e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b4420b3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b4420b0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b441fc6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b441fc889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b441fc611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b441fb3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b441fbc82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b441fb4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b44209e0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b441f7f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b441f7d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f2a5661a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==9829==ABORTING

INPUT
EBEWAC1dLRZ/AAABXFsAAAABAPwj//0ADo6OjnyqABc8IAQqBQMUPFt/AB48PDw8AQD8I//9AACO
jo58qisrACs8LhsZPDw8PDw7C5RgBlt/EAA8PAEA/CP//QAAjo6OfKoAFzwZGxk8IFA8PDsLlEwL
lGAEWx48PDw8/38ZAFAePI6Ojo6OAP9gPDxg////fwABPBkbGTw8PDw8OwuUTAuUYARbHjw8Sz7/
fxkAUB48PDw8AAAQAH1qEAA0NTU1NY6cAP9gPDxg////fwABPBkbNTU1NTX/gAAAU2A8PGD//yB/
AAE8GQD/G3//KhtvABsF



==9830==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f0f5efcc18c bp 0x7fff24986920 sp 0x7fff249860d0
WRITE of size 96 at 0x62100002e100 thread T0
    #0 0x7f0f5efcc18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x5593a84a214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5593a84a06ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5593a84a62c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5593a84bc7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x5593a84bc929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x5593a84bcb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x5593a846a30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x5593a846aaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x5593a8469ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x5593a8469727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5593a84697b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5593a84697dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x5593a8468e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x5593a8424136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x5593a8421aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x5593a8337c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x5593a833989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x5593a833711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x5593a8324f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5593a832d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x5593a8325d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5593a840f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x5593a82f0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5593a82ee8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f0f5e7be2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x5593a82ed749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f0f5f02c090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5593a83fde00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x5593a849cb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x5593a84693c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x5593a846979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5593a84697b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5593a84697dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5593a8468e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5593a8424136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5593a8421aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5593a8337c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5593a833989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5593a833711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5593a8324f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5593a832d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5593a8325d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5593a840f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5593a82f0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5593a82ee8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f0f5e7be2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==9830==ABORTING

INPUT
FUAAlwZBAhETixn8GwQmUgD8AxUZVjyOjo6A/46mjrBgPDxUgDz/fxn6GfwbBCZSAPwDFRlWPI6O
joD/jqaOsGA8PFSAPP9/Gf+f/0hIVANIA5BH+UgsNwOQgDeQGzcMNwOf/5D6N5AbNww3A0gWkEf5
SD43A5CAA5D/9AACAgwAAgIera2QGzc4N5AbNww3A5DkkPr/n/9ISDbjSAOQR0BIAEADkIAMfwDv
/4AN+g4N



==10408==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f1340c7918c bp 0x7ffd64eef420 sp 0x7ffd64eeebd0
WRITE of size 236 at 0x62100002e100 thread T0
    #0 0x7f1340c7918b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x5567c44b014a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5567c44ae6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5567c44b42c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5567c44ca7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x5567c44ca929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x5567c44cab59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x5567c447830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x5567c4478aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x5567c4477ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x5567c4477727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5567c44777b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5567c44777dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x5567c4476e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x5567c4432136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x5567c442faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x5567c4345c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x5567c434789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x5567c434511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x5567c4332f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5567c433b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x5567c4333d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5567c441d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x5567c42fe401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5567c42fc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f134046b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x5567c42fb749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f1340cd9090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5567c440be00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x5567c44aab99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x5567c44773c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x5567c447779c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5567c44777b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5567c44777dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5567c4476e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5567c4432136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5567c442faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5567c4345c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5567c434789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5567c434511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5567c4332f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5567c433b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5567c4333d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5567c441d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5567c42fe401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5567c42fc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f134046b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10408==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BAKooPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DB4iSBaQR/lIPjcDkIADkP/0AAICDB6trZAbNzg3kBs3DDcenm8B
ADwoPIAANuNH/wACfx6trZAbNzg3kBs3DDcenm/rADyxPIAANuNIA5BH+UgAQAOQgAx/AO//gP8A
BOoN+g4N



==10445==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fc16433118c bp 0x7ffda713c420 sp 0x7ffda713bbd0
WRITE of size 216 at 0x62100002e100 thread T0
    #0 0x7fc16433118b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55596388b14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5559638896ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55596388f2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5559638a57bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x5559638a5929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x5559638a5b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55596385330d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x555963853aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x555963852ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x555963852727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5559638527b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5559638527dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x555963851e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55596380d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55596380aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x555963720c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55596372289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55596372011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55596370df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55596371682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55596370ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5559637f80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x5559636d9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5559636d78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fc163b232b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x5559636d6749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fc164391090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5559637e6e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x555963885b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x5559638523c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55596385279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5559638527b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5559638527dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x555963851e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55596380d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55596380aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x555963720c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55596372289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55596372011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55596370df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55596371682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55596370ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5559637f80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5559636d9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5559636d78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fc163b232b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10445==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAAR/lILDcDkIA3kBs3AAEDn/+Q+jeQGzcMNwNIFpBH+Ug+
NwOQgAOQ//QAAgIMAAICHq2tkBs3ODeQGzcMNx6ebwEAPCg8gAA2kBs3ODeQGzcMNx6ebwEAPCg8
gAA240gDkEf5SABA40gDkEf5SABAA5CADH8A7/+A/wAE6g36Dg0=



==10446==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f8c19f9418c bp 0x7fff5aeda610 sp 0x7fff5aed9dc0
WRITE of size 213 at 0x62100002e100 thread T0
    #0 0x7f8c19f9418b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55fb92d5514a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55fb92d536ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55fb92d59214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55fb92d6f1cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55fb92d6f902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55fb92d6fb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55fb92d1d30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55fb92d1daef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55fb92d1cee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55fb92d1c727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55fb92d1c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55fb92d1c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55fb92d1be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55fb92cd7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55fb92cd4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55fb92beac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55fb92bec89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55fb92bea11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55fb92bd7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55fb92be082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55fb92bd8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55fb92cc20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55fb92ba3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55fb92ba18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f8c197862b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55fb92ba0749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f8c19ff4090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55fb92cb0e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55fb92d4fb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55fb92d1c3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fb92d1c79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fb92d1c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fb92d1c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fb92d1be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fb92cd7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fb92cd4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fb92beac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fb92bec89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fb92bea11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fb92bd7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fb92be082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fb92bd8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fb92cc20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fb92ba3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fb92ba18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f8c197862b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10446==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAFDgAAG5ubm5ubm5ubm5ubiFubm5ubgAAAAA8
AAEDn/+Q+gACGzd//wNIGpDw+Ug+UwOQkQOQ//QAAgIMAAICHq2tkBs3ODf5SD5TA5CRA5H/9AAC
AgwAAgIera2QGzc4N5D/qn8A8v+A/wAE6g36FCSH/QCAFJyn/Zb8HZbwGQAAAADo/wAARwQAERsA
ZwQmhxQCAEAAAAAnkBs3DDce4GMbVAAQAAKVABI=



==10750==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fe0e7a2b18c bp 0x7ffe08b33680 sp 0x7ffe08b32e30
WRITE of size 186 at 0x62100002e100 thread T0
    #0 0x7fe0e7a2b18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x557bb04e714a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x557bb04e56ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x557bb04eb214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x557bb05011cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x557bb0501902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x557bb0501b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x557bb04af30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x557bb04afaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x557bb04aeee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x557bb04ae727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x557bb04ae7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x557bb04ae7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x557bb04ade93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x557bb0469136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x557bb0466aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x557bb037cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x557bb037e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x557bb037c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x557bb0369f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x557bb037282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x557bb036ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x557bb04540f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x557bb0335401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x557bb03338da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fe0e721d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x557bb0332749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fe0e7a8b090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x557bb0442e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x557bb04e1b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x557bb04ae3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x557bb04ae79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x557bb04ae7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x557bb04ae7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x557bb04ade93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x557bb0469136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x557bb0466aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x557bb037cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x557bb037e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x557bb037c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x557bb0369f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x557bb037282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x557bb036ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x557bb04540f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x557bb0335401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x557bb03338da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fe0e721d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10750==ABORTING

INPUT
QCH/VQDo/wAAR2JbkWUenm8BADwoPIAA/v+qANqAABsF6+MBA5//kPo3kBspDDcDSBaQR/lIPkAD
kIADkP/0AAICDAACAh6trZAbNzg3kBs3DAtAPUABDAACAh6trZAbNzg3kBs3DAtAPUABARgoARgo
FRUVFRAQEBAQEBUVBRX5GyQQOBs4ExgoOBs4ExhFNgAABhs4ExgoOBs4ExhFNgAABgEnKGEdAgAb
OBMYKDgbAH8YZRgIALUYJ/cAJgAbOBMYRfcAEP/dABAYWRhkAAH5ENsAECAAGMQCIkAOEA==



==14941==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x555e62ed4253 bp 0x7fff204f0990 sp 0x7fff204f0988
READ of size 4 at 0x619000002280 thread T0
    #0 0x555e62ed4252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x555e62ed26ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x555e62e9b3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x555e62e9b79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x555e62e9b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x555e62e9b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x555e62e9ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x555e62e56136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x555e62e53aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x555e62d69c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x555e62d6b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x555e62d6911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x555e62d56f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x555e62d5f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x555e62d57d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x555e62e410f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x555e62d22401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x555e62d208da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f8097a432b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x555e62d1f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f80982b0d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x555e62e2fd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x555e62ecd960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x555e62ecdc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x555e62e9b090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x555e62e9b7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x555e62e9ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x555e62e56136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x555e62e53aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x555e62d69c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x555e62d6b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x555e62d6911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x555e62d56f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x555e62d5f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x555e62d57d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x555e62e410f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x555e62d22401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x555e62d208da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f8097a432b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==14941==ABORTING

INPUT
GwMWKjoVPDwhAJRg9ri4uLi4uMG4uBkZGRkFGYAVWWAgG9jMzKr9//0oAAD/bCA8QAEAjsHQTzyA
qwD/f5NgP///5oAdPAAAZQBrGfc8PP//AAAD6BkZJiYZ9zwbPOlrGQEZGRkmJhkXGRAgABkZGRmA
9zwbPOlrGQEZGRkmJhkXGRAgABkZGRmAFRUXGWBAAAAAgB08AAABAGsZ9zw8/////wEZGRkmJhlZ
YBcb2MzMqswBShGAAWAZGRkZGRkZARkAAAABGRcgAAU=



==23160==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f0794cdd18c bp 0x7ffe347cb040 sp 0x7ffe347ca7f0
WRITE of size 111 at 0x62100002e100 thread T0
    #0 0x7f0794cdd18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x56428f3c414a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x56428f3c26ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x56428f3c8214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x56428f3de1cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x56428f3de902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x56428f3deb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x56428f38c30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x56428f38caef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x56428f38bee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x56428f38b727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x56428f38b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x56428f38b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x56428f38ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x56428f346136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x56428f343aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x56428f259c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56428f25b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56428f25911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x56428f246f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x56428f24f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x56428f247d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x56428f3310f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x56428f212401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x56428f2108da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f07944cf2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x56428f20f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f0794d3d090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x56428f31fe00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x56428f3beb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x56428f38b3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x56428f38b79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x56428f38b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x56428f38b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x56428f38ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x56428f346136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x56428f343aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x56428f259c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x56428f25b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x56428f25911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x56428f246f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x56428f24f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x56428f247d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x56428f3310f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x56428f212401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x56428f2108da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f07944cf2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23160==ABORTING

INPUT
FREWGQAAGQIOFiozMCBTJC1qatHR0dEbGSoF/2wAXID/f6LpJHskXio/KHmxsVQEzUFBWykpKSkp
A5CAN5AbNww3A5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDby
9AACAgwAAgIera2QGzc4N5AbNww28pDkkPr/gP8ABOoN+g4N



==27899==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f265708818c bp 0x7fffcd7f55b0 sp 0x7fffcd7f4d60
WRITE of size 236 at 0x62100002e100 thread T0
    #0 0x7f265708818b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55995eab214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55995eab06ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55995eab62c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55995eacc7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55995eacc929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55995eaccb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55995ea7a30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55995ea7aaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55995ea79ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55995ea79727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55995ea797b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55995ea797dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55995ea78e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55995ea34136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55995ea31aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55995e947c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55995e94989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55995e94711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55995e934f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55995e93d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55995e935d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55995ea1f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55995e900401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55995e8fe8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f265687a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55995e8fd749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f26570e8090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55995ea0de00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55995eaacb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55995ea793c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55995ea7979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55995ea797b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55995ea797dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55995ea78e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55995ea34136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55995ea31aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55995e947c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55995e94989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55995e94711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55995e934f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55995e93d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55995e935d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55995ea1f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55995e900401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55995e8fe8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f265687a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27899==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAAAABAOMAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAIAQAACAh6trZAbNzg3kBs3DDce
nm8XADwoPIAANuNIA5BH+UgAQAOQgAx/GY48PDwAPP9/GQBRHjwAPCAAIQDOjo4gAAAAju7nXRlh
C0A8GfwbACAE8o2OPQtAPBj+ADw8PAA8/38ZGRAAPDw8APyOEysLjo6kPDxcPQtAYARiAAMVGVY8
OAA8OxAAYARbHgRCHjw8PDwXgBkhUB48PFc9jo6rAP8AAH0EQAADGxkAAAPoPB0ZEAs8/yokbvIb
BQ==



==901==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55c39fc0b253 bp 0x7ffda48f6e60 sp 0x7ffda48f6e58
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55c39fc0b252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55c39fc096ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55c39fbd23c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55c39fbd279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55c39fbd27b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55c39fbd27dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55c39fbd1e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c39fb8d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c39fb8aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c39faa0c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c39faa289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c39faa011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c39fa8df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c39fa9682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c39fa8ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c39fb780f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c39fa59401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c39fa578da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f4ffc0262b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55c39fa56749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f4ffc893d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c39fb66d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55c39fc049d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55c39fc04c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55c39fbd2090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55c39fbd27d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55c39fbd1e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c39fb8d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c39fb8aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c39faa0c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c39faa289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c39faa011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c39fa8df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c39fa9682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c39fa8ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c39fb780f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c39fa59401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c39fa578da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f4ffc0262b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==901==ABORTING

INPUT
BtDyOlYAAQABIAQqBQMQPVsAAgALAyBfDjQ0MzMzMzNAbxAQEBcQEBkQGCUQEBAQjo4AAgA8EC+M
ABkQGCUQEBADFwAbJRCOAAB9PC30/+MhlG39CPdfwsgQjphcJBt7FBR5G6T/AF8wEBAQPhAQGRAY
NRCOAAB9PC30/+MhlG39CPdfwsgQjpgAXX08XvUAACE6GRAFAAEAAFNLAIAgAEAaIDwzMzMzLB5h
JBs5G/97EF8QEBAQLxAQGRkQGCU6EBADGzMzMzM04BkQGCUQEBAQjo4AAgA8PPUAACE6AAAFAIAA
AFMIGwU=



==3864==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55f411fe2253 bp 0x7ffd09c1b150 sp 0x7ffd09c1b148
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55f411fe2252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55f411fe06ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55f411fa93c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55f411fa979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55f411fa97b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55f411fa97dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55f411fa8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f411f64136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f411f61aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f411e77c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f411e7989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f411e7711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f411e64f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f411e6d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f411e65d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f411f4f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f411e30401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f411e2e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f249673b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55f411e2d749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f2496fa8d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f411f3dd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f411fdb9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55f411fdbc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f411fa9090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f411fa97d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f411fa8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f411f64136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f411f61aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f411e77c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f411e7989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f411e7711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f411e64f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f411e6d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f411e65d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f411f4f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f411e30401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f411e2e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f249673b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3864==ABORTING

INPUT
ZDZ/FBQUIt5kAM5/ADRTKy2WAAAAIFOALxR/AH8AAAAkKLoO/yL6DBSUCAQCG3tRe94vFJYUGxsE
35YUGxob3i8UlhQbGxsbARsbVGbnJgQbAv36IFMbLxtUmpqampqampqaMTExMTExgBs4MTExMTEx
MTExgBs44p0UJIf9lt4vFJYUGxsbPgEbG1QAEAAAlf2WEBsbGygAoRQke3p7e3veLxQAAP/1GyoA
oRQCf/8bG5AAf/ogA1T/e3veAhtT4pUbVATeLxS/FBsbAAL9UwMvG1QmBBsC/VMbLxtUmpqampqa
mpqaMTExMTExgBs4MTExMWRRUWQQAPwbGxsbVABAADExgBs44p0UJIf9lhuAEf8bGxlU9t4Al+2W
EBsbGyDqfHwY+nx8UxsVGwAbGxlU9t4vPpYE35YUGxob3i8UlhQbGRsbARsbVABAAACX7YCfn5+f
n5+fn5+fn5+fn5+fn5+fn5+fpp+uAAAAe3v6IANU/xsTfwAAEBtTJAEAG/8zDBSUAAR7e3t7e/oM
FJQABHt7e3t73i8UlhQbGxsqCqEUAoAAGxsbOBsfGxsE//8F



==3951==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x563fe4a9f253 bp 0x7ffdb2db0ab0 sp 0x7ffdb2db0aa8
READ of size 4 at 0x619000002280 thread T0
    #0 0x563fe4a9f252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x563fe4a9d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x563fe4a663c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x563fe4a6679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x563fe4a667b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x563fe4a667dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x563fe4a65e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x563fe4a21136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x563fe4a1eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x563fe4934c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x563fe493689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x563fe493411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x563fe4921f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x563fe492a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x563fe4922d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x563fe4a0c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x563fe48ed401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x563fe48eb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff9d61d42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x563fe48ea749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7ff9d6a41d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x563fe49fad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x563fe4a98960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x563fe4a98c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x563fe4a66090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x563fe4a667d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x563fe4a65e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x563fe4a21136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x563fe4a1eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x563fe4934c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x563fe493689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x563fe493411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x563fe4921f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x563fe492a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x563fe4922d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x563fe4a0c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x563fe48ed401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x563fe48eb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff9d61d42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3951==ABORTING

INPUT
G+ABMzMzMwAAf/86MzMzAAEzlZUe2QAQAH88KEgzMzMzUjMzMzNDQ0NDQ0NDQ0NDQ0NDQ0NDQ0ND
Q0NDQ0NDMzUzMzN9AFxL73+i/yQgEF4qKHl/fRY1MzMzfQD6QEUUrf0AlZVklZWVZJUe2QAQUB7Z
PDw8AABQHtk8PBszNTMzM4j//5WVlf9/lZWVZJUe2QAQUB7ZPB88AABQHdk8PAQzEkNDQ0P//+Qz
HBMzMzMzMzMzMwD6QEUUrQQzNTOrM/0AlZVklZWVZJUe2QAQUCR7JF4qKHl/fWYAOYdg/zxsqwAh
AQD/23vvGwU=



==3971==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x558afd6c8253 bp 0x7ffc7543d760 sp 0x7ffc7543d758
READ of size 4 at 0x619000002280 thread T0
    #0 0x558afd6c8252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x558afd6c66ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x558afd68f3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x558afd68f79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x558afd68f7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x558afd68f7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x558afd68ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x558afd64a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x558afd647aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x558afd55dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x558afd55f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x558afd55d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x558afd54af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x558afd55382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x558afd54bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x558afd6350f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x558afd516401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x558afd5148da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7169c2a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x558afd513749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f716a497d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x558afd623d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x558afd6c1960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x558afd6c1c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x558afd68f090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x558afd68f7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x558afd68ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x558afd64a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x558afd647aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x558afd55dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x558afd55f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x558afd55d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x558afd54af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x558afd55382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x558afd54bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x558afd6350f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x558afd516401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x558afd5148da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7169c2a2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3971==ABORTING

INPUT
CxMULgH1Ihn/ABAAATgZGxk8nXxfcKqdi0pKSkobkBsk+iAbGxsBGhtUUyQoeRv/hwv7lAAEe3p7
wcF5GxuhAgAUAn//oaGhoaH4YJiYFCQ+eRsO+ll7e3sBe94Ge3uW+gwdCQkJCQkJCQkJCRsbKgAA
APkbGpZAAgACKxtUUyQoixv/GgYUlAAEeyMAAAABFiOSIyMjIyMjIyMjIyMjoRTh+RkAEAAML5YE
3pYbMjIyMjL//gsUlAAEe3p7e5b6DB0JCQkJCQkJCQkJCQQbAhtdGxSUHQR+cXt7ewkJCQl+fn5+
flwJfn5+X35+BN4vFEAULi6AIAAAANnoAwAAUVFR/fwMlgQbAhtdGxsfAAQUJHX9lvzxlgQbAgwU
lB0Ee3t7e3veLxSWFBsbGyoAoQAA5zj/////BP//7Q==



==4643==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fce3f01218c bp 0x7fffe2c64df0 sp 0x7fffe2c645a0
WRITE of size 145 at 0x62100002e100 thread T0
    #0 0x7fce3f01218b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x564b5656914a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x564b565676ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x564b5656d214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x564b565831cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x564b56583902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x564b56583b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x564b5653130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x564b56531aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x564b56530ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x564b56530727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x564b565307b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x564b565307dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x564b5652fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x564b564eb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x564b564e8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x564b563fec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x564b5640089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x564b563fe11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x564b563ebf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x564b563f482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x564b563ecd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x564b564d60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x564b563b7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x564b563b58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fce3e8042b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x564b563b4749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fce3f072090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x564b564c4e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x564b56563b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x564b565303c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x564b5653079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x564b565307b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x564b565307dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x564b5652fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x564b564eb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x564b564e8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x564b563fec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x564b5640089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x564b563fe11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x564b563ebf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x564b563f482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x564b563ecd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x564b564d60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x564b563b7401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x564b563b58da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fce3e8042b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==4643==ABORTING

INPUT
QCH/AADo/wCAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3A4AA/v+qADcDSAOQR/k3kBs3DDcD
SBaQR/lIPhcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDcenm8BADwoPIDGNuNIA5BH+UgAQAOQ
gAx/AO//gP8ABOoZGRkZGSLEORkI3AguCAkICAgkAAC6AAf7QACqAAAAPgB/kA==



==4644==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f62ee98e18c bp 0x7ffe86a68160 sp 0x7ffe86a67910
WRITE of size 203 at 0x62100002e100 thread T0
    #0 0x7f62ee98e18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55fd3394d14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55fd3394b6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55fd33951214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55fd339671cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55fd33967902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55fd33967b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55fd3391530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55fd33915aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55fd33914ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55fd33914727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55fd339147b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55fd339147dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55fd33913e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55fd338cf136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55fd338ccaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55fd337e2c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55fd337e489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55fd337e211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55fd337cff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55fd337d882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55fd337d0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55fd338ba0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55fd3379b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55fd337998da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f62ee1802b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55fd33798749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f62ee9ee090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55fd338a8e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55fd33947b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55fd339143c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fd3391479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fd339147b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fd339147dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fd33913e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fd338cf136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fd338ccaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fd337e2c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fd337e489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fd337e211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fd337cff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fd337d882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fd337d0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fd338ba0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fd3379b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fd337998da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f62ee1802b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==4644==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqASCw3A5CAN5AbNwABA5+UkPo3kBs3DDcDSBYB
R/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3CDceUo6kVBm90QAcvQRACAMVGRY8KCooKSgo
KBUoKCgoJygAAH//6+vr66/r6+va6+v8APwI6AQA6AQAAI6kPAAEAx48PBkQfwAEKiSrACCOPBkA
ABsF6+MAAAA8KDyAAP7/qgA3A0gDkP8APP8qJFKOgTwZBFr/6SAbBQ==



==5356==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55be6b07b253 bp 0x7ffe727f2de0 sp 0x7ffe727f2dd8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55be6b07b252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55be6b0796ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55be6b0423c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55be6b04279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55be6b0427b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55be6b0427dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55be6b041e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55be6affd136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55be6affaaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55be6af10c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55be6af1289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55be6af1011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55be6aefdf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55be6af0682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55be6aefed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55be6afe80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55be6aec9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55be6aec78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdb0229b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55be6aec6749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fdb02b08d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55be6afd6d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55be6b074960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55be6b074c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55be6b042090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55be6b0427d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55be6b041e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55be6affd136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55be6affaaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55be6af10c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55be6af1289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55be6af1011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55be6aefdf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55be6af0682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55be6aefed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55be6afe80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55be6aec9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55be6aec78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdb0229b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==5356==ABORTING

INPUT
GxUWGTgZROlrA69PGYD/GVQXPE8ZGRkZGQAEGTtwgoIAAABkAX///733TyggGR4dEBkXGRAZ/38A
AAABAAA86YQD6E8tHRkAAAEAGQEAAIBtPGkAIDxSTxkZGxkZAAQZRESAbm3IGzQ0NDA0Ty0dGQAA
AQAZ



==8593==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55e76ebc5253 bp 0x7ffe80571e50 sp 0x7ffe80571e48
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55e76ebc5252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55e76ebc36ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55e76eb8c3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55e76eb8c79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55e76eb8c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55e76eb8c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55e76eb8be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e76eb47136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e76eb44aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e76ea5ac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e76ea5c89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e76ea5a11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e76ea47f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e76ea5082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e76ea48d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e76eb320f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e76ea13401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e76ea118da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbc88a282b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55e76ea10749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fbc89295d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55e76eb20d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55e76ebbe9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55e76ebbec75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55e76eb8c090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55e76eb8c7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55e76eb8be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e76eb47136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e76eb44aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e76ea5ac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e76ea5c89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e76ea5a11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e76ea47f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e76ea5082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e76ea48d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e76eb320f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e76ea13401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e76ea118da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbc88a282b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==8593==ABORTING

INPUT
GyoS3wEAAF09DgAsSRLfAQAAXT0LAAAA/wCo8/Pz8/Pz8/MZEAM8PI3xgP/zgGBkuLi4uLi4uLi4
uLi4fSRAmpqampqampqampqampqampqamgAIGxkAAEDoPCY0lGCeABCOjo6Wjl08PQt/////ACQk
JBskJCQkJCQkJCQkJAAAjqSOIAC8RD0LQDwAAggZEBw8/yokUo6kVRlW0QAcyARAjRkVHVY8KCow
KCgo//+AACgoKCgZKCgoHh4eHhgZmmA8Iz0LQCYZEABkHjkA/B4eHhnr6+vrgADI6+vr6+vr6/wA
/HXIBgAAjqRUAAQDFTwAEI5rjo6OgKsA/wAAk+FAAAMbGQAAA+g8PBkQADz/KiRSoAA8gDwAqwAg
AAF9BECb/BkQADwAQwD8jjwZEAA8/46kPBlWzC////8A/2AEWx4EW+wAIAAsfQRAf/wZENobBQ==



==10229==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000d180 at pc 0x7f47d3ce318c bp 0x7ffcbeea1c60 sp 0x7ffcbeea1410
WRITE of size 593 at 0x61900000d180 thread T0
    #0 0x7f47d3ce318b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x5599173b014a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5599173ae6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5599173b42c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5599173a36df in _rl_isearch_fini (/home/dualbus/src/gnu/bash-build/bash+0x2276df)
    #5 0x5599173a7adf in _rl_isearch_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x22badf)
    #6 0x5599173a7ccb in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bccb)
    #7 0x5599173a27cb in rl_forward_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267cb)
    #8 0x55991737830d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x559917377ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x559917377727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5599173777b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5599173777dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x559917376e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x559917332136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55991732faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x559917245c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55991724789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55991724511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x559917232f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55991723b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x559917233d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55991731d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x5599171fe401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5599171fc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f47d34d52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x5599171fb749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000d180 is located 0 bytes to the right of 1024-byte region [0x61900000cd80,0x61900000d180)
allocated by thread T0 here:
    #0 0x7f47d3d42d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55991730bd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5599173a9405 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d405)
    #3 0x5599173a9c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x559917377090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5599173777d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x559917376e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x559917332136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55991732faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x559917245c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55991724789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55991724511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x559917232f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55991723b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x559917233d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55991731d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5599171fe401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5599171fc8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f47d34d52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9a30:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10229==ABORTING

INPUT
Gyary5Tz/EoQTCKQABBJDC8UlhQkPnkbDvpZeyVIGeIZGRkZEr0Bpv8ZkP///4AAAAHfCNwICAAA
uhWmpqb/GRn2gBkZJWQZAgCAGRkZEL29AH/wGRmcLhlkf/ghALoVpqam/xkZ9oAZGSVkGQIA//8T
GRYZGRkZGRkZNgE2NjY2qzY2Nsw2NjYZGRDRvQB/8BkZnEgZZH/yIf//ExkWPBkZGRkbGQCAAAD/
fyhA4CpA4AcACFwICLoVpqam/xkZ9gAAugIAHaYAf+g=



==10383==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fbd9f2d418c bp 0x7ffd1978df30 sp 0x7ffd1978d6e0
WRITE of size 211 at 0x62100002e100 thread T0
    #0 0x7fbd9f2d418b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55ecc624614a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55ecc62446ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55ecc620d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55ecc620d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55ecc620d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55ecc620d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55ecc620ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55ecc61c8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55ecc61c5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55ecc60dbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55ecc60dd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55ecc60db11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55ecc60c8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55ecc60d182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55ecc60c9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55ecc61b30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55ecc6094401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55ecc60928da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fbd9eac62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x55ecc6091749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fbd9f334090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55ecc61a1e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55ecc6240b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55ecc620d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55ecc620d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55ecc620d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55ecc620d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55ecc620ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55ecc61c8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55ecc61c5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55ecc60dbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55ecc60dd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55ecc60db11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55ecc60c8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55ecc60d182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55ecc60c9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55ecc61b30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55ecc6094401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55ecc60928da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fbd9eac62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10383==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A3CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6tqZAbNzg3kBs3DDce
nm8BkBs3ODeQAAAAAR6ebwEAPCg8gAB/AO//gP8ABOoN+g4N



==10386==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f3c2ba0218c bp 0x7ffec598d2b0 sp 0x7ffec598ca60
WRITE of size 230 at 0x62100002e100 thread T0
    #0 0x7f3c2ba0218b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x562a228ff14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x562a228fd6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x562a229032c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x562a229197bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x562a22919929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x562a22919b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x562a228c730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x562a228c7aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x562a228c6ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x562a228c6727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x562a228c67b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x562a228c67dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x562a228c5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x562a22881136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x562a2287eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x562a22794c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x562a2279689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x562a2279411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x562a22781f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x562a2278a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x562a22782d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x562a2286c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x562a2274d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x562a2274b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f3c2b1f42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x562a2274a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f3c2ba62090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x562a2285ae00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x562a228f9b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x562a228c63c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x562a228c679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x562a228c67b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x562a228c67dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x562a228c5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x562a22881136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x562a2287eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x562a22794c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x562a2279689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x562a2279411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x562a22781f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x562a2278a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x562a22782d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x562a2286c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x562a2274d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x562a2274b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f3c2b1f42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10386==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gAPDxuxxBX
GWX//38c/xsDkEf5SCw3A5aAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAAC
Ah6trZAbNzg3kBs3DDcenm88Hjw8/xs8PBoBAI6Xjo6OGz0gVxkQADw8K4COQAH/7gA8PDw7C4Jg
pQD+f1v9VSABAAAoGRr/GzY8PAEAPBAAPDxuxxBXGWX//38c/xsF



==10391==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7f78f139718c bp 0x7ffc25a68f00 sp 0x7ffc25a686b0
WRITE of size 600 at 0x61900000cc80 thread T0
    #0 0x7f78f139718b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x56247392214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5624739206ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5624738e93c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x5624738e979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5624738e97b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5624738e97dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5624738e8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5624738a4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5624738a1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5624737b7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5624737b989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5624737b711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5624737a4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5624737ad82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5624737a5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x56247388f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x562473770401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x56247376e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f78f0b892b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x56247376d749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000cc80 is located 0 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
allocated by thread T0 here:
    #0 0x7f78f13f6d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56247387dd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56247391b442 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d442)
    #3 0x56247391bc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x5624738e9090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5624738e97d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x5624738e8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5624738a4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5624738a1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5624737b7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5624737b989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5624737b711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5624737a4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5624737ad82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5624737a5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x56247388f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x562473770401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x56247376e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f78f0b892b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9990:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==10391==ABORTING

INPUT
MSH/AAAvIE0QR2JSkW8enm8BADwoPIAA/v8gAAIAUB7ZPCQbTRs3sZWvlZW1lZWV6ZyTnZWlKxAb
LQQgERstfxAAAAAAE/8jfy9KAB7xPCp/Mhs4nJWgHtk8PDwAABBQHtm3AP8AAAETGQEZAFAg2Tw8
PBovABAAPWrzPDwqYWEcrwSA/x4EWx4ZVgAZFR15PAAgAAsAAgAAH///AMMAGSQ0Vjwo+fn8EPkg
+fn5+fn5BgAAl7dUAgQDFTwAGVYAGRUdeTwo0S///wCAABkkNFY8KBCurq6ura6urq6uvK7/////
rq6urq6urq6urq6urq6uAT3sQCYZEABkHjkA/B4eHhnr6+vryOvr6+vr68vr6/wA/HXIBgAAl7dU
AgQDFTwAGVYAGRUdeTwo0S///wCAGRDaGwA9EA==



==16930==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f9e6936418c bp 0x7ffd2d96cb00 sp 0x7ffd2d96c2b0
WRITE of size 216 at 0x62100002e100 thread T0
    #0 0x7f9e6936418b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x558c632c414a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x558c632c26ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x558c632c82c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x558c632de7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x558c632de929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x558c632deb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x558c6328c30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x558c6328caef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x558c6328bee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x558c6328b727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x558c6328b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x558c6328b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x558c6328ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x558c63246136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x558c63243aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x558c63159c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x558c6315b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x558c6315911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x558c63146f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x558c6314f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x558c63147d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x558c632310f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x558c63112401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x558c631108da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f9e68b562b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x558c6310f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f9e693c4090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x558c6321fe00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x558c632beb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x558c6328b3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x558c6328b79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x558c6328b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x558c6328b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x558c6328ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x558c63246136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x558c63243aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x558c63159c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x558c6315b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x558c6315911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x558c63146f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x558c6314f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x558c63147d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x558c632310f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x558c63112401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x558c631108da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f9e68b562b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==16930==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP5H+Ug+NwOQgAOQ//QA
AgIMAAICHq2tkBs3ODeQkBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm8BADwoPIAANuNIA5BH+UgAQAOQgAx/AO//gP8AJgAbOBMYRfcAEAAAABAYRRhkAAYYJ9sAEAAA
GCgCP0AOOw==



==17284==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f88cee1e18c bp 0x7ffe1c417d50 sp 0x7ffe1c417500
WRITE of size 202 at 0x62100002e100 thread T0
    #0 0x7f88cee1e18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55f85a75214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55f85a7506ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55f85a756214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55f85a76c1cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55f85a76c902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55f85a76cb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55f85a71a30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55f85a71aaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55f85a719ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55f85a719727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55f85a7197b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55f85a7197dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55f85a718e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55f85a6d4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55f85a6d1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55f85a5e7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55f85a5e989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55f85a5e711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55f85a5d4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55f85a5dd82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55f85a5d5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55f85a6bf0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55f85a5a0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55f85a59e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f88ce6102b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55f85a59d749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f88cee7e090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55f85a6ade00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55f85a74cb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55f85a7193c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55f85a71979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55f85a7197b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55f85a7197dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55f85a718e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55f85a6d4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55f85a6d1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55f85a5e7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55f85a5e989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55f85a5e711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55f85a5d4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55f85a5dd82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55f85a5d5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55f85a6bf0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55f85a5a0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55f85a59e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f88ce6102b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==17284==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8ennQBADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA57/kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDCICAh6trZAbNzg3kBs3DDce
mm8BPP//AACOAICRGzc4jjSRGzc4jo4AEiqAAABTWgICAjw8dqsA/wAAYDw8PCg8PD0LQHwEAHr/
ABAA/CDrfhk8PD0LG2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjJCQkJMUkC/wg/34Z
AFNgPDx2MmA8PHarAP8ABEAAAxsbgCQkJCQkJCQkJCQkJCQkJCQ8PECrAOUGAAFHGQD/G0CrAOUG
AAD/Af//6AMAABzn4I5tjo6OABsF



==17317==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fd328c9118c bp 0x7ffe6bbea790 sp 0x7ffe6bbe9f40
WRITE of size 294 at 0x62100002e100 thread T0
    #0 0x7fd328c9118b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55e26f19614a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55e26f1946ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55e26f19a214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55e26f1b01cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55e26f1b0902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55e26f1b0b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55e26f15e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55e26f15eaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55e26f15dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55e26f15d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55e26f15d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55e26f15d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55e26f15ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55e26f118136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55e26f115aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55e26f02bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55e26f02d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55e26f02b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55e26f018f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55e26f02182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55e26f019d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55e26f1030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55e26efe4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55e26efe28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fd3284832b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55e26efe1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fd328cf1090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55e26f0f1e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55e26f190b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55e26f15d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55e26f15d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55e26f15d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55e26f15d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55e26f15ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55e26f118136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55e26f115aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55e26f02bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55e26f02d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55e26f02b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55e26f018f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55e26f02182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55e26f019d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55e26f1030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55e26efe4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55e26efe28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fd3284832b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==17317==ABORTING

INPUT
FS4WEHN+GQIOFiozMCBTJC2WFBsbUyQb+RudexBfEC9kEBAQEAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5AAAgIMIgICHq2tkBs3OIA3kBs3AAEDn/+Q+jeQGzcMNwNIFqZH+Ug+NwOQgAOQ//QAAgIMIgIC
Hq2tkBs3ODeQGzcMIgICHq2tkBs3ODeQGzcMNx6ebwEAPCg8gAA24ww3Hp5vAQA8KDyAADbjSAOQ
R/lIAAABAIAMfwDv/4D/AATqDfoODQ==



==19695==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x5607455e0253 bp 0x7fffebd0aa60 sp 0x7fffebd0aa58
READ of size 4 at 0x619000001d80 thread T0
    #0 0x5607455e0252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x5607455de6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x5607455a73c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x5607455a779c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x5607455a77b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x5607455a77dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x5607455a6e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560745562136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x56074555faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560745475c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56074547789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56074547511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560745462f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56074546b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560745463d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x56074554d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x56074542e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x56074542c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd53a9502b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x56074542b749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fd53b1bdd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56074553bd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5607455d99d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x5607455d9c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x5607455a7090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5607455a77d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x5607455a6e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560745562136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x56074555faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560745475c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56074547789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56074547511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560745462f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56074546b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560745463d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x56074554d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x56074542e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x56074542c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fd53a9502b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==19695==ABORTING

INPUT
bDr/2MzsFQEBShGAmpqaGQsV/hkEGRkZGYAVYCB/oukkeyQZShkZGRkZGUTszMwBShGCmpqaGQsV
/hkEGf9/mpq6mhCampqamhkLIBkZBBkZGRmAFWAgG9jM7MztAUoZGRkZGQPo7MzMAUoRgJqamhkL
Ff4ZBBkrGRmAFWAgf6LpJHskXisbBQ==



==22750==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f37cab7c18c bp 0x7ffeed9aac50 sp 0x7ffeed9aa400
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7f37cab7c18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55697e81914a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55697e8176ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55697e81d2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55697e8337bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55697e833929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55697e833b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55697e7e130d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55697e7e1aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55697e7e0ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55697e7e0727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55697e7e07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55697e7e07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55697e7dfe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55697e79b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55697e798aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55697e6aec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55697e6b089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55697e6ae11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55697e69bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55697e6a482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55697e69cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55697e7860f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55697e667401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55697e6658da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f37ca36e2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55697e664749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f37cabdc090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55697e774e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55697e813b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55697e7e03c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55697e7e079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55697e7e07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55697e7e07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55697e7dfe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55697e79b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55697e798aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55697e6aec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55697e6b089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55697e6ae11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55697e69bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55697e6a482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55697e69cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55697e7860f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55697e667401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55697e6658da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f37ca36e2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22750==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICGQACAh6trZAbNzg3kBs3DDce
nm8BADwoPIAera2QGzc4N5AbNww3Hp5vAQA240gDkEf5SABAA5CADH8A7/+A/wAE6g36Dg0=



==27242==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x5645be249253 bp 0x7fff893670f0 sp 0x7fff893670e8
READ of size 4 at 0x619000002280 thread T0
    #0 0x5645be249252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x5645be2476ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x5645be2103c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x5645be21079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x5645be2107b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x5645be2107dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x5645be20fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5645be1cb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5645be1c8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5645be0dec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5645be0e089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5645be0de11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5645be0cbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5645be0d482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5645be0ccd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5645be1b60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5645be097401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5645be0958da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff0420be2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x5645be094749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7ff04292bd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5645be1a4d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5645be242960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x5645be242c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x5645be210090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5645be2107d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x5645be20fe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5645be1cb136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5645be1c8aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5645be0dec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5645be0e089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5645be0de11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5645be0cbf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5645be0d482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5645be0ccd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5645be1b60f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5645be097401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5645be0958da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff0420be2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27242==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTAAAAAGAEQCADOxk8PDyOjn+OAFsePDwAAAEAYOJAIAM8
PAEAjpeOjo6OjvoAEfqUYAR/GRBQHtmDPDyAGwAgADw8PAF/GQBQjo5/jgBbHjw8FAABKBkA/xs8
PDwBAI4Ajo6Ojo6PCK6OjisbPQtOVxmQADw8PAB/GQBQHss8PDyA/AAgOxkQ3zw8TAB/GQBQHhYW
FhYWFhYAAAEAGwAgOxkQ1Tw8TAB/GVgAPDw8OwuUYARbAAD//wBQHtn/AD1qlgAAdWA8jo6O/3+P
CK6OjisbPQtOVxkQADw8PAB/GQBQHss8PDwpKSkpKSkpKSkpKSkpPGarAP8AAAEoGQAABH//Khtv
ABsF



==27243==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55f038ca8253 bp 0x7ffeca150e60 sp 0x7ffeca150e58
READ of size 4 at 0x619000002280 thread T0
    #0 0x55f038ca8252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55f038ca66ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55f038c6f3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55f038c6f79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55f038c6f7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55f038c6f7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55f038c6ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f038c2a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f038c27aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f038b3dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f038b3f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f038b3d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f038b2af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f038b3382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f038b2bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f038c150f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f038af6401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f038af48da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc63bbba2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55f038af3749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fc63c427d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f038c03d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f038ca1960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55f038ca1c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f038c6f090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f038c6f7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f038c6ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f038c2a136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f038c27aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f038b3dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f038b3f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f038b3d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f038b2af42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f038b3382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f038b2bd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f038c150f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f038af6401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f038af48da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc63bbba2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27243==ABORTING

INPUT
GyoDEyEaahAAQfQ5CwX//wX8Hv+AAABTYDw8/wADPDwBAI6XlGAEfxkQUB7Zgzw8gBsAIAA8PP+A
fxkAUI4AAABAWx48PBQAASgZAP8bPDw8AQCOAI6Ojo6Ojwiujo4rGz0LTlcZkAA8PDwAfxkAUB7L
PDw8gBsAIDsZEN88PEwAXxkAUB4WFhYWFhYWEAABABsAIDsZEN88PEwAfxtYADw8PDsLlGAEWwAA
//8AUB7Z/wBYKpYAAHVgPI6Ojo6Ojwiujo4rGz0GTlcZEAA8PDwAfxkAUB7LPDw8AEBbHjw8FAAB
KBkA/xs8PDwBAI4Ajo6OKSkpAAQpKRgpKSkpKTxm////AAABKBkAAAR//yobaQAbBQ==



==27244==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55ee76e51253 bp 0x7ffe9e60efc0 sp 0x7ffe9e60efb8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55ee76e51252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55ee76e4f6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55ee76e183c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55ee76e1879c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55ee76e187b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55ee76e187dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55ee76e17e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55ee76dd3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55ee76dd0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55ee76ce6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55ee76ce889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55ee76ce611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55ee76cd3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55ee76cdc82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55ee76cd4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55ee76dbe0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55ee76c9f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55ee76c9d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f204b1742b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55ee76c9c749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f204b9e1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55ee76dacd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55ee76e4a9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55ee76e4ac75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55ee76e18090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55ee76e187d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55ee76e17e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55ee76dd3136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55ee76dd0aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55ee76ce6c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55ee76ce889f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55ee76ce611f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55ee76cd3f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55ee76cdc82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55ee76cd4d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55ee76dbe0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55ee76c9f401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55ee76c9d8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f204b1742b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27244==ABORTING

INPUT
GyoDEyEaahAAQfSUAAEAAAX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBg
4kAgAzy8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFsePDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRDfPDxMAH8ZWAA8PDw7C5RgBDsAAP//AFAe2f8APWqWAAAIro6O
Kxs9C05XGRAAPDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAEf/8qG28AGwU=



==27245==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x555e0215a253 bp 0x7fff2c807520 sp 0x7fff2c807518
READ of size 4 at 0x619000002280 thread T0
    #0 0x555e0215a252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x555e021586ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x555e021213c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x555e0212179c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x555e021217b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x555e021217dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x555e02120e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x555e020dc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x555e020d9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x555e01fefc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x555e01ff189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x555e01fef11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x555e01fdcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x555e01fe582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x555e01fddd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x555e020c70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x555e01fa8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x555e01fa68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ffa24df02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x555e01fa5749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7ffa2565dd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x555e020b5d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x555e02153960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x555e02153c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x555e02121090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x555e021217d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x555e02120e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x555e020dc136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x555e020d9aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x555e01fefc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x555e01ff189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x555e01fef11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x555e01fdcf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x555e01fe582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x555e01fddd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x555e020c70f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x555e01fa8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x555e01fa68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ffa24df02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27245==ABORTING

INPUT
GyoDEyEaah0AQfSUCwX//wX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBv
4kAgAzw8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2X88PIAbACAAPDw8AX8ZAFCOjn+OAGEePDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GTw8TAB/GVgAPDw8OwuUYARbAAD//wBQHtkZAFAeyzw8PCkpKSkp
KSkpKSkpKSk8ZqsA/wAAATw8PAB/GQBQHss8PDwpKSkpKSkpKSkpKSkpPGarAP8AAAEoGQAABH//
KhtvRkZGRkZGRkYAGwU=



==27246==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55b3518a5253 bp 0x7fff67a1d7f0 sp 0x7fff67a1d7e8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55b3518a5252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55b3518a36ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55b35186c3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55b35186c79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55b35186c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55b35186c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55b35186be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b351827136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b351824aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b35173ac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b35173c89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b35173a11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b351727f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b35173082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b351728d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b3518120f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b3516f3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b3516f18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa0ccbf12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55b3516f0749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fa0cd45ed28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b351800d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b35189e9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55b35189ec75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55b35186c090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55b35186c7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55b35186be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b351827136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b351824aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b35173ac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b35173c89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b35173a11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b351727f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b35173082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b351728d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b3518120f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b3516f3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b3516f18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa0ccbf12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27246==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8HxyAAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBg
4kAgAzw8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFsePDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRDfPDxMAH8ZPwA8PDw7C5RgBFsAAP//AFAe2f8APWqWAAB1YDyO
jo6Ojo8Iro6OKxs9C05XGRAAPDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAE
f/8qG28AGwU=



==27258==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x560c1afff253 bp 0x7ffc7ff3d000 sp 0x7ffc7ff3cff8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x560c1afff252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x560c1affd6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x560c1afc63c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x560c1afc679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x560c1afc67b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x560c1afc67dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x560c1afc5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560c1af81136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x560c1af7eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560c1ae94c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x560c1ae9689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x560c1ae9411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560c1ae81f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x560c1ae8a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560c1ae82d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x560c1af6c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x560c1ae4d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x560c1ae4b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f18576132b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x560c1ae4a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f1857e80d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x560c1af5ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x560c1aff89d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x560c1aff8c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x560c1afc6090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x560c1afc67d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x560c1afc5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560c1af81136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x560c1af7eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560c1ae94c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x560c1ae9689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x560c1ae9411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560c1ae81f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x560c1ae8a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560c1ae82d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x560c1af6c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x560c1ae4d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x560c1ae4b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f18576132b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27258==ABORTING

INPUT
GyoDEyEaahAAM/SUCwX//wX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AAR48PAAAAQBg
4kAgAzw8AQCOl32Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAf/9/GVgAPDw8OwuUYARbAAD//wBQ
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRDfPDxMAH8ZWBA8PDw7C5RgBFsAAP//AFAe2f8APWqWAAB1YDyO
jo6Ojo8Iro6OKxs9C05XGRAAPDw8AH8ZAFAeyzw8PJ4pKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAE
f/8qG28AGwU=



==27259==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55c0c5af0253 bp 0x7fffc01dfd30 sp 0x7fffc01dfd28
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55c0c5af0252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55c0c5aee6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55c0c5ab73c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55c0c5ab779c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55c0c5ab77b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55c0c5ab77dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55c0c5ab6e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c0c5a72136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c0c5a6faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c0c5985c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c0c598789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c0c598511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c0c5972f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c0c597b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c0c5973d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c0c5a5d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c0c593e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c0c593c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f73c53aa2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55c0c593b749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f73c5c17d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c0c5a4bd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55c0c5ae99d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55c0c5ae9c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55c0c5ab7090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55c0c5ab77d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55c0c5ab6e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c0c5a72136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c0c5a6faa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c0c5985c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c0c598789f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c0c598511f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c0c5972f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c0c597b82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c0c5973d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c0c5a5d0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c0c593e401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c0c593c8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f73c53aa2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27259==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GTw8PI51f44AWx48PO4AAQBg
4kAgAzw8APaOl46Ojo6O+gAR+pRgBH8Y8lAe2YM8PIAbACAAPDw8BAAAgFCOjn+OAFsePDwUAAEo
jo6Ojwiujo4rGz0LTlcZkAA8PDwAfxkAUB7LPDw8gBsAIDsZEN88PEwAfxkAUB4WFhYWFhYWAAAB
ABsAIDsZEN88PEwAfxlYADw8PDv8lGAEWwAA//8AUB7Z/wA9apYAAHVgPI6Ojo6Ojwiujo4rGz0L
TlcZEAA8PDwAfxkAUB7LPDw8KSkpKSkpKSkpKSkpKTxmqwD/AAABKBkAAAR//yobbwAbBQ==



==27260==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55af70826253 bp 0x7ffc307d29b0 sp 0x7ffc307d29a8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55af70826252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55af708246ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55af707ed3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55af707ed79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55af707ed7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55af707ed7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55af707ece93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55af707a8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55af707a5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55af706bbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55af706bd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55af706bb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55af706a8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55af706b182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55af706a9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55af707930f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55af70674401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55af706728da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f823e5dc2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55af70671749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f823ee49d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55af70781d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55af7081f960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55af7081fc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55af707ed090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55af707ed7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55af707ece93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55af707a8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55af707a5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55af706bbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55af706bd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55af706bb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55af706a8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55af706b182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55af706a9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55af707930f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55af70674401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55af706728da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f823e5dc2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27260==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBg
4kAgAzw8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFsePDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAsyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRDfPDxMABR/GVgAPDw8OwuUYARbAAD//wBQHtn/AD1qlgAAdWA8
jo6Ojo6PCK6OjisbPQtOVxkQADw8PAB/GQBQHss8PDwpKSkpKSkpKSkpKSkpPGarAP8AAAEoGQAA
BH//KhtvABsF



==27261==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x559bb528c253 bp 0x7ffc2bf5ed70 sp 0x7ffc2bf5ed68
READ of size 4 at 0x619000002280 thread T0
    #0 0x559bb528c252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x559bb528a6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x559bb52533c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x559bb525379c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x559bb52537b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x559bb52537dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x559bb5252e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x559bb520e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x559bb520baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x559bb5121c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x559bb512389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x559bb512111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x559bb510ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x559bb511782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x559bb510fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x559bb51f90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x559bb50da401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x559bb50d88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f3337b012b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x559bb50d7749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f333836ed28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x559bb51e7d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x559bb5285960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x559bb5285c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x559bb5253090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x559bb52537d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x559bb5252e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x559bb520e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x559bb520baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x559bb5121c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x559bb512389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x559bb512111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x559bb510ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x559bb511782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x559bb510fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x559bb51f90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x559bb50da401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x559bb50d88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f3337b012b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27261==ABORTING

INPUT
GyoDEyEaahAAQf+UCwX//wX8Hv+AAABTYDw8HQCOAI6Ojo6Ojwiujo4rGz0LjgBbHjw8AACOjn+O
AFsePDwAAAEAYOJAIAM8PAEAjpeOjo6OjvoAEfqUYAR/GRBQHtmDPDyAGwAgADx/jgBbHjw8FAAB
KBkA/xs8PDwdAI4Ajo6Ojo6PCK6OjisbPQtOVxmQADw8PAB/GQBQHss8PECAGwAgOxkQ3zw8TAB/
GQBQHhYWFhYWFhYAAAEAGwAgOxkQ3zw8TP9+GVgAPDw8OwuUYARbAAD//wBQHtn/AD1qlgAAdWA8
jo6Ojo6PCK6OjisbPQtOVxkQADw8PAB/GQBQHss8PDwpKSkLKSkpKSkpKSkpPGarAP8AAAEoGQAA
BH//KhtvABsF



==27262==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55b5e3d2e253 bp 0x7fff38626530 sp 0x7fff38626528
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55b5e3d2e252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55b5e3d2c6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55b5e3cf53c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55b5e3cf579c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55b5e3cf57b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55b5e3cf57dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55b5e3cf4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b5e3cb0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b5e3cadaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b5e3bc3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b5e3bc589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b5e3bc311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b5e3bb0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b5e3bb982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b5e3bb1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b5e3c9b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b5e3b7c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b5e3b7a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f5a598502b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55b5e3b79749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f5a5a0bdd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b5e3c89d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b5e3d279d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55b5e3d27c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55b5e3cf5090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55b5e3cf57d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55b5e3cf4e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b5e3cb0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b5e3cadaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b5e3bc3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b5e3bc589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b5e3bc311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b5e3bb0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b5e3bb982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b5e3bb1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b5e3c9b0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b5e3b7c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b5e3b7a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f5a598502b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27262==ABORTING

INPUT
GyoDExQaahAAQfSUCwX//wX8Hv+A/+1TYDw8/wAAAAAAYARAIBQ7GTw8PI6fBf//BVAeyzw8PCkp
KSkgAzw8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2YMsPIAbACAAPDw8AAAAEFCOjn+OAP//PDwUAAEo
ro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8ZAFAeFhYWFhYWFgAAAQAbACA7
GRDfPDxMAH8ZWAA8PDw7C5RgBFsAAP//AFAW2f8APWqWBgB1YDyOjnOOjo8Iro6OKxs9C05XGRAA
PDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAEf/8qG28AGwU=



==27271==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55d158b66253 bp 0x7ffed5761d70 sp 0x7ffed5761d68
READ of size 4 at 0x619000002280 thread T0
    #0 0x55d158b66252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55d158b646ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55d158b2d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55d158b2d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55d158b2d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55d158b2d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55d158b2ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55d158ae8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55d158ae5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55d1589fbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55d1589fd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55d1589fb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55d1589e8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55d1589f182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55d1589e9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55d158ad30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55d1589b4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55d1589b28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f695bfff2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55d1589b1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f695c86cd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55d158ac1d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55d158b5f960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55d158b5fc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55d158b2d090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55d158b2d7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55d158b2ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55d158ae8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55d158ae5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55d1589fbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55d1589fd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55d1589fb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55d1589e8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55d1589f182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55d1589e9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55d158ad30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55d1589b4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55d1589b28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f695bfff2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27271==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wU8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBg4kAgAzw8AQCO
l46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFsePDwUAAEoGQD/Gzw8PAEA
jgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8ZAFAeFhYWFhY4
FgAAAQAbACA7GRDfPDxMAH8ZWAA8PDw7C5RgBFsAAP//AFAe2f8APWqWAAB1YDyOjo6Ojo8Iro6O
Kxs9C05XGRAAPDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAEf/8qG28AGwU=



==27272==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55baaedcf253 bp 0x7fff04143d10 sp 0x7fff04143d08
READ of size 4 at 0x619000002280 thread T0
    #0 0x55baaedcf252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55baaedcd6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55baaed963c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55baaed9679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55baaed967b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55baaed967dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55baaed95e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55baaed51136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55baaed4eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55baaec64c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55baaec6689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55baaec6411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55baaec51f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55baaec5a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55baaec52d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55baaed3c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55baaec1d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55baaec1b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f2a1e7792b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55baaec1a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f2a1efe6d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55baaed2ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55baaedc8960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55baaedc8c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55baaed96090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55baaed967d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55baaed95e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55baaed51136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55baaed4eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55baaec64c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55baaec6689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55baaec6411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55baaec51f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55baaec5a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55baaec52d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55baaed3c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55baaec1d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55baaec1b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f2a1e7792b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27272==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTYDw8AQAAAAAAYARAIAM7GTw8PI6Of44AWzk8PAAAAQBg
4kAgAzw8ARuOl46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFsePDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAa4iA7GRDfPDxMAH8ZWAA8PDw7C5RgBFsAAP//AFAe2f8APWqWAAB1YDyO
jo6Ojo8Iro6OKxs9C05XGRAAPDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAE
f/8qG28AGwU=



==27281==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x5560cbde4253 bp 0x7fffd4f935f0 sp 0x7fffd4f935e8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x5560cbde4252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x5560cbde26ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x5560cbdab3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x5560cbdab79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x5560cbdab7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x5560cbdab7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x5560cbdaae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5560cbd66136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5560cbd63aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5560cbc79c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5560cbc7b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5560cbc7911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5560cbc66f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5560cbc6f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5560cbc67d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5560cbd510f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5560cbc32401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5560cbc308da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f4fb2f842b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x5560cbc2f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f4fb37f1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5560cbd3fd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5560cbddd9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x5560cbdddc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x5560cbdab090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5560cbdab7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x5560cbdaae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5560cbd66136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5560cbd63aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5560cbc79c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5560cbc7b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5560cbc7911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5560cbc66f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5560cbc6f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5560cbc67d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5560cbd510f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5560cbc32401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5560cbc308da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f4fb2f842b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27281==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTYDw8/wAAAAAAYARAIAM7GQCAAACOf44AWx48PAAAAQBg
4kAgAzw8AQCOl46Ojo6O+gAR+pRgBH8ZEFAe2YM8PIAbACAAjn+OAFsePDwUAAEoGQD/Gzw8PAEA
jgCOjo6Ojo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeADw8PDsLlGAEWwAA//8AUB7Z/wA9apYAAHXL
Wjw8gBsAIDsZEN88PEwAfxkAUB4WFhYWFhYWAAABABsAIDsZEN88PEwAfxlYADw8PDsLlGAEWwAA
//8AUB7Z/wA9apYAAHVgPI6Ojo6Ojwiujo4rGz0LTlcZEAA8PDwAfxkAUB7LPDw8KSkpKSkpKSkp
KSkpKTxmqwD/AAABKBkAAAR//yobbwAbBQ==



==27282==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x5596afc5d253 bp 0x7fffe897a740 sp 0x7fffe897a738
READ of size 4 at 0x619000001d80 thread T0
    #0 0x5596afc5d252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x5596afc5b6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x5596afc243c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x5596afc2479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x5596afc247b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x5596afc247dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x5596afc23e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5596afbdf136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5596afbdcaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5596afaf2c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5596afaf489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5596afaf211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5596afadff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5596afae882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5596afae0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5596afbca0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5596afaab401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5596afaa98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc0893de2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x5596afaa8749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fc089c4bd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5596afbb8d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x5596afc569d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x5596afc56c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x5596afc24090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x5596afc247d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x5596afc23e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5596afbdf136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5596afbdcaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x5596afaf2c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x5596afaf489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x5596afaf211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5596afadff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x5596afae882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5596afae0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5596afbca0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5596afaab401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5596afaa98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc0893de2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27282==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+AAABTYDxR/wAAAAADOxk8PDyOjn+OAFsePDwAAAEAYOJAA+g8
PAEAjpeOjo6OjvoAEfqUYAR/GRBQHtmDPDyAGwAgADw8PAF/GQBQjo5/jopbHjw8FAABKBkA/xs8
PDwBAHEAf46Ojo6Ojo8Iro6OKxs9C05XGf///388AH8ZAFAeyzw8PI6Ojwiujo4rGz0LTlcZpQA8
PDz3fxkAUB7LPDw8gBsAEzsZEN88PEwAfxkAUB4WFhYWFhYWAAABAAQAADsZEN88PEwAfxlYwjw8
PDsLlF/7WwAA//8AUB7Z/wA9apYAAHVgPI6Ojo6Ojwiujo4rGz0LTlcZ////fzwAfxkAUB7LPDw8
KSkpKSkpKSkpioqKioqKioqKioqKAH8pKTxmqwD/AAABKBkAAAR//yobbwAbBQ==



==27283==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55a44aa56253 bp 0x7fff04538ff0 sp 0x7fff04538fe8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55a44aa56252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55a44aa546ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55a44aa1d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55a44aa1d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55a44aa1d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55a44aa1d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55a44aa1ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55a44a9d8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55a44a9d5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55a44a8ebc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55a44a8ed89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55a44a8eb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55a44a8d8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55a44a8e182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55a44a8d9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55a44a9c30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55a44a8a4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55a44a8a28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f09afe5d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55a44a8a1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f09b06cad28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55a44a9b1d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55a44aa4f960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55a44aa4fc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55a44aa1d090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55a44aa1d7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55a44aa1ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55a44a9d8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55a44a9d5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55a44a8ebc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55a44a8ed89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55a44a8eb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55a44a8d8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55a44a8e182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55a44a8d9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55a44a9c30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55a44a8a4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55a44a8a28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f09afe5d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==27283==ABORTING

INPUT
GyoDEyEaahAAQfSUCwX//wX8Hv+QAABTYDw8/wAAAAAAYARAIAM7GTw8PI6Of44AWx48PAAAAQBg
4kAgAzw8AQCOPCkpKSkpKSkpKSkpKSk8ZqsA/wAAASgZAAAEf/8qG5eOjo6OjvMAEfqUYAR/GRBQ
HtmDPDyAGwAgADw8PAF/GQBQjo5/jgBbHjw8gBsAIDsZEN88PEwUAAEoGQD/Gzw8PAEAjgCOjo6O
jo8Iro6OKxs9C05XGZAAPDw8AH8ZAFAeyzw8PIAbACA7GRDfPDxMAH8ZAFAeFhYWFhYWFgAAAQAb
ACA7GRDfPDxMjjwpKSkpKSkbKSkpKSkpPGarAP8AAAEoGQAABH8AfxlYADw8PDsLlGAEWwAA//8A
UB7Z/wA9jvoAEfqUYAR/GRBQHtmDPDyAGwAgADw8PAF/PDwAfxkAUB7LPDw8KSkpKSkpKSkpKSsp
KTxmqwD/AAABKBkAAAR//yobbwAbBQ==



==28413==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000cc80 at pc 0x7ff69faaa18c bp 0x7ffee50690e0 sp 0x7ffee5068890
WRITE of size 67 at 0x61900000cc80 thread T0
    #0 0x7ff69faaa18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55f79fa4514a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55f79fa436ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55f79fa49214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55f79fa5f1cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55f79fa5f902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55f79fa5fb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55f79fa0d30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55f79fa0daef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55f79fa0cee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55f79fa0c727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55f79fa0c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55f79fa0c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55f79fa0be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55f79f9c7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55f79f9c4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55f79f8dac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55f79f8dc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55f79f8da11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55f79f8c7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55f79f8d082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55f79f8c8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55f79f9b20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55f79f893401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55f79f8918da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7ff69f29c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55f79f890749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000cc80 is located 0 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
allocated by thread T0 here:
    #0 0x7ff69fb09d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f79f9a0d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f79fa3e442 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d442)
    #3 0x55f79fa3ec75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f79fa0c090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f79fa0c7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f79fa0be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f79f9c7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f79f9c4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f79f8dac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f79f8dc89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f79f8da11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f79f8c7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f79f8d082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f79f8c8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f79f9b20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f79f893401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f79f8918da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff69f29c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9990:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==28413==ABORTING

INPUT
Gwl/FBQUIt5kAM5iAH9TJC2WAAwUlAgEAhtT4pX9lhAbGxsoEKEUJHt7e3t7fwAbAhtTJCh7e3t7
3jUU3i8UlhQbGygp6ANU/xsbGWD9e3tf/4d7exCW/AAbLxs5mpqampqampqaqpqampqampqQmrGa
ABT/GxsZVBM1NTYJ3pwzni8UlhT/GxsXVBM1NTUQVxkZADw8PFN/GTyAPDwAAI4BAIOOG38kWx5V
AAEAAAtAV4AbAAEAACh/AGNjaGNjY2NjY2NjY2NjYwAQAACaAQCOl46Ljhs9IFcZEAA8PCuAfxld
XV1dgAAAAF9FXU8OXVIAPDyOl46Djo6OjpaWlgEAPBAXPFUAAQAAC0BXgP/uADw8PDsLgmClAP5/
Wx4AQABA+CgZGv8bNjw8AQA8EAA8PG51dXV1dTY2NjY2NjY2NjY2NjY2NjY2NjY2NjY2NjZ1xxBX
GWX//38c/xsF



==29130==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x564038978253 bp 0x7ffc6d0b2d30 sp 0x7ffc6d0b2d28
READ of size 4 at 0x619000002280 thread T0
    #0 0x564038978252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x5640389766ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x56403893f3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x56403893f79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x56403893f7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x56403893f7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x56403893ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5640388fa136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5640388f7aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x56403880dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56403880f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56403880d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5640387faf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56403880382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5640387fbd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5640388e50f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5640387c6401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5640387c48da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7faef76b42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x5640387c3749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7faef7f21d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x5640388d3d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x564038971960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x564038971c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x56403893f090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x56403893f7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x56403893ee93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x5640388fa136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x5640388f7aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x56403880dc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56403880f89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56403880d11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x5640387faf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56403880382e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x5640387fbd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x5640388e50f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x5640387c6401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x5640387c48da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7faef76b42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29130==ABORTING

INPUT
QCH/AAD//wAAR2JbkW8enm/kADwoPH/oV/+qANqAABsF6+MA0NAoPDwBAP8AWgBge94vFJYUGxsb
KegDVBAbGxsoAKEUJHt7e3sg3i8UlikbGxsp6ANU/5qWmpqam5qa+gwUlAAEe3t7e3veLxSWFBsb
G5oAAACABf//BZqamrOzs7Ozs7Ozs7Ozs7Ozs5oEGxtAARsXVOYQAACV/ZYQGzkbKAChFNDQ2NDQ
0NDQ0NDQniR7e3t7//9Ue97///+A//8bHwChFP9//xsbkBuu+iADVP8HG38AAipTJCh5G/8a+gwU
lAAEAkxi4oIbXATeLxS/FBsbHgL9UxsvGzO1tbW1x7W1tbW1tbW1tbW1tbW1tbW1tbW1tbUMFJQA
BHt7e4573i8UlhQbGxt9gH9o2QMfAIASJIf9AADoAxs44p0UJIeW/ACWBBsy/VMbFRsAGwsZVPbe
AICWBAABFBsgG94vFBYPGxsbBgEb+FRm5yaH/xuAAJ0Ae3waIANU/xAbDBSUAAR7Yn8AewEMFJQA
BHt7e3t73i8WlpsbGxsqAKEDGzjinQBAh5b8AJYUAoAAGRsnIRsfGxsE//8F



==29562==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fb1c3a2918c bp 0x7fff8d313150 sp 0x7fff8d312900
WRITE of size 105 at 0x62100002e100 thread T0
    #0 0x7fb1c3a2918b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55fad279214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55fad27906ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55fad2796214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55fad27ac1cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55fad27ac902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55fad27acb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55fad275a30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55fad275aaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55fad2759ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55fad2759727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55fad27597b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55fad27597dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55fad2758e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55fad2714136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55fad2711aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55fad2627c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55fad262989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55fad262711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55fad2614f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55fad261d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55fad2615d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55fad26ff0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55fad25e0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55fad25de8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fb1c321b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55fad25dd749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fb1c3a89090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55fad26ede00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55fad278cb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55fad27593c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fad275979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fad27597b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fad27597dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fad2758e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fad2714136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fad2711aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fad2627c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fad262989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fad262711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fad2614f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fad261d82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fad2615d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fad26ff0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fad25e0401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fad25de8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fb1c321b2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==29562==ABORTING

INPUT
QCH/AAD0AAICkBs3LDcBn/+Q+jeQGzcMNwNIA5BH+Ug+NwOQgAOQ/5D6/5//SEg3A0gDkJAbNww3
A5//kPo3kBs3DDcDSBaQR/lIPjeAA5D/9AACAgwAAgIera2QGzc4N5AbNww3A5DkkAOQgAOQ//Q+
NwOQgAOQ//QAAgIMAAICHq2tkBs3ODeQGzcMNwOQ5JD6/5//SEg240gDkEf5SABAA5CADH8A7/+A
/wAE6g36Dg0=



==32253==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55f15986e253 bp 0x7ffd27d22c30 sp 0x7ffd27d22c28
READ of size 4 at 0x619000002280 thread T0
    #0 0x55f15986e252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55f15986c6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55f1598353c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55f15983579c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55f1598357b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55f1598357dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55f159834e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f1597f0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f1597edaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f159703c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f15970589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f15970311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f1596f0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f1596f982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f1596f1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f1597db0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f1596bc401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f1596ba8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc43bee02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55f1596b9749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fc43c74dd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f1597c9d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f159867960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55f159867c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f159835090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f1598357d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f159834e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f1597f0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f1597edaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f159703c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f15970589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f15970311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f1596f0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f1596f982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f1596f1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f1597db0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f1596bc401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f1596ba8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fc43bee02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==32253==ABORTING

INPUT
GyZ/FBQUIoAvFH8AGwIbzs7OgBs24t2WFCcbG87Ozs7Ozs7O4pX9lhD0E5YEGwL9UxuvOVSaknyT
mpqampqqmpqampqampqamkAE3i8UAAAAgBs24p0BJAAClhuAFP8bGxlj9t4AAAEAGhveLxSWFCcb
GxsBGxtUABAAAJX9lhAbHxsoAH//JIAAe3t73i8oFAJ//xsbkBsk6iD+GhsBGwdUUyQoeRv/Gjsb
fwAbAhtUgD//5ZcbUwAAEAAEAhtT4pUbVATeLxS/FBsyMjIyMjwCHxsfAG4UJBQAAIcAZNwdlgQb
Av1TGxUbAGQbGVT23vbeE38aG94vFJYUGxsbGwEbG5YUGxsbKgCg8R2A+gAAGTkb1hsbGP//BQ==



==32258==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d00001de80 at pc 0x7f1ab532718c bp 0x7ffcfe9014f0 sp 0x7ffcfe900ca0
WRITE of size 704 at 0x61d00001de80 thread T0
    #0 0x7f1ab532718b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x56204778b14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5620477896ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5620477523c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x56204775279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5620477527b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5620477527dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x562047751e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x56204770d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x56204770aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x562047620c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x56204762289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x56204762011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x56204760df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x56204761682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x56204760ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5620476f80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5620475d9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5620475d78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f1ab4b192b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x5620475d6749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61d00001de80 is located 0 bytes to the right of 2048-byte region [0x61d00001d680,0x61d00001de80)
allocated by thread T0 here:
    #0 0x7f1ab5387090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5620476e6e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x562047785b2c in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb2c)
    #3 0x5620477523c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x56204775279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5620477527b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5620477527dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x562047751e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x56204770d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x56204770aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x562047620c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x56204762289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x56204762011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x56204760df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x56204761682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x56204760ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5620476f80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5620475d9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5620475d78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f1ab4b192b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c3a7fffbb80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbb90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbba0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbbb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbbc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c3a7fffbbd0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbbe0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbbf0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbc00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbc20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==32258==ABORTING

INPUT
GxkiEQAQAAABlPX19fX19fX19fX1HfX19aH19fX1YHdo/BGqqp2qqjyqqqrGqj57YADpdHR0dFR0
dHR0//ALYKtkAABfqKiggKioqKgBMwAAAX88APypaOYAFVseBFseACAACwAbAAAf+rw8JwsLLz0L
ORsAAB/6vDwnCwsvPQs5Euvr6+vr6+vr6+vr8+vr/AD8dcgGADSAAJSUlJSUlJSUlJSWpJSUlJSR
lICUlJQgADwAQwD8jhwZEAA8/yokUmQkVRlW0QAcyAQyABkVL1Y8KCooKDUoKBAAKIAoKCgZKCgo
Hh4mHhhAJhkQEGQeOQD8Hh4eEuvr6+vr6+vr6+vr8+vr/AD8dcgGADSAAAAABAMVPAAQjmuOjo6A
qwD/AACp4UAAAxsZAAAD6Dza2tra2tra2tra2jwZEAA8/xkQADz/KiRSoAA8gAABfQRAm/wQAAA8
AEP//I48IBAAPP+OpDwZVtFO////AP9gBFseI1uWACAALH0EQPoAkfraGwU=



==32419==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x621000030900 at pc 0x7f920193218c bp 0x7ffd9095fdc0 sp 0x7ffd9095f570
WRITE of size 3838 at 0x621000030900 thread T0
    #0 0x7f920193218b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55fc33e7b14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55fc33e796ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55fc33e423c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fc33e4279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fc33e427b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fc33e427dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fc33e41e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fc33dfd136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fc33dfaaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fc33d10c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fc33d1289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fc33d1011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fc33cfdf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fc33d0682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fc33cfed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fc33de80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fc33cc9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fc33cc78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f92011242b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x55fc33cc6749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x621000030900 is located 0 bytes to the right of 4096-byte region [0x62100002f900,0x621000030900)
allocated by thread T0 here:
    #0 0x7f9201992090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55fc33dd6e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55fc33e75b2c in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb2c)
    #3 0x55fc33e423c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fc33e4279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fc33e427b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fc33e427dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fc33e41e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fc33dfd136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fc33dfaaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fc33d10c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fc33d1289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fc33d1011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fc33cfdf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fc33d0682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fc33cfed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fc33de80f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fc33cc9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fc33cc78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f92011242b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffe0d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffe0e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffe0f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffe100: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffe110: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffe120:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffe130: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffe140: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffe150: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffe160: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffe170: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==32419==ABORTING

INPUT
GxD/fxj/3iS7JElJSUkAAAABAAD2tvb2C/b29iQbJBsbbRs+GRsUFNsfFBQUFABnZ2dnUmdnGRkZ
GRkZGRkZGgIaGhoaGhkZGTUZGRkBGRmOjo6OGxsbGxUUFABnZ2dnZ35nCxkZGRkZGRj9GRk1GRkZ
ARkZjo6OjhsbfmcZGRkZGSoZGRkZGTUZGRkBGRmOjpaOGxsMGxsbfwDdIgwAAAAAgBsbGxsUBBsF
Gxv/f+gDFA==



==3569==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f146e36518c bp 0x7ffec1c525a0 sp 0x7ffec1c51d50
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7f146e36518b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55c0983fd14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55c0983fb6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55c0984012c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55c0984177bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55c098417929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55c098417b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55c0983c530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55c0983c5aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55c0983c4ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55c0983c4727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55c0983c47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55c0983c47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55c0983c3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55c09837f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55c09837caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55c098292c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55c09829489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55c09829211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55c09827ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55c09828882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55c098280d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55c09836a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55c09824b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55c0982498da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f146db572b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55c098248749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f146e3c5090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55c098358e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55c0983f7b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55c0983c43c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55c0983c479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55c0983c47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55c0983c47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55c0983c3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55c09837f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55c09837caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55c098292c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55c09829489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55c09829211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55c09827ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55c09828882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55c098280d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55c09836a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55c09824b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55c0982498da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f146db572b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3569==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm8BADwoPIAANuNIA5BH+UgAQAM8PFN/GTwePDwAAPoZAP///4AojpeOg44bVQtAV4Ab5gEAGgEA
jgAAAIAAACgZAOsbPDwZ3wCOl46Ojhs9IFcZEAA8IACAf12AAAAAACgZAOsbPDwZAACOl46Ojhs9
X11dXQ5dOwAgLjw8PI6Xjn+/jo6OjgBA/+4APE88PECCYIAA/n8QADwrPAB/GQBc/4BdPE6AGwAB
AAABKBkA/xtl//9/AP8bBQ==



==5914==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55de176ca253 bp 0x7ffecdc210b0 sp 0x7ffecdc210a8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55de176ca252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55de176c86ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55de176913c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55de1769179c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55de176917b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55de176917dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55de17690e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55de1764c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55de17649aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55de1755fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55de1756189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55de1755f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55de1754cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55de1755582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55de1754dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55de176370f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55de17518401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55de175168da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff2052922b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55de17515749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7ff205affd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55de17625d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55de176c3960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55de176c3c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55de17691090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55de176917d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55de17690e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55de1764c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55de17649aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55de1755fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55de1756189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55de1755f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55de1754cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55de1755582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55de1754dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55de176370f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55de17518401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55de175168da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7ff2052922b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==5914==ABORTING

INPUT
GyoqLxs3AwMDGyYDGxrzAwAABAAWKgMvAQAdAzAqq4WFhUXd4O/lABA8PI6Of44AWx48PAQAAQBg
4kAgAzw8AQCOl46Ojo6O+gAAEJRgBH8ZEFAe2YM8PIAbACAAPDw8AX8ZAFCOjn+OAFv2PDwUAAEo
GQD/Gzw8PAEAjgCOjo6Ojo8Iro6OKxs9C04TGZAAPDw8AIoZAFAeyzw8PIAbACA7GRDfPDxMAH8Z
AFAeFhYWFhYWFgAAAQAbACA7GRYWFhYWFhYAAAEAGwAgOxkQ3zw8TAB/AFAe2f8APWqWAAB1YDyO
jo6Ojo8Iro6OKxs9C05XGRAAPDw8AH8ZAFAeyzw8PCkpKSkpKSkpKSk0KSk8ZqsA/wAAASgZAAAE
lv8qG28AGwU=



==7297==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fdc38c8118c bp 0x7ffd9da53cd0 sp 0x7ffd9da53480
WRITE of size 85 at 0x62100002e100 thread T0
    #0 0x7fdc38c8118b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x5623363db14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5623363d96ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5623363df214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x5623363f51cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x5623363f5902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x5623363f5b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x5623363a330d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x5623363a3aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x5623363a2ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x5623363a2727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x5623363a27b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x5623363a27dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x5623363a1e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x56233635d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x56233635aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x562336270c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56233627289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56233627011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x56233625df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x56233626682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x56233625ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5623363480f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x562336229401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5623362278da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fdc384732b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x562336226749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fdc38ce1090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x562336336e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x5623363d5b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x5623363a23c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x5623363a279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x5623363a27b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x5623363a27dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x5623363a1e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x56233635d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x56233635aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x562336270c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x56233627289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x56233627011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x56233625df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x56233626682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x56233625ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5623363480f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x562336229401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5623362278da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fdc384732b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7297==ABORTING

INPUT
Gy0Ct78A/xP8+ysIHRrfG1IDq5a5ubm5ubm5ubm5ubm5G1MbgICAXoCAgICAgKAAHREtlgB0dId/
dHSAAHRH+UgsNwOQgDeQGzcMNwOf/5D6N5AbZPn5+fn5+Qw3A0gWkEf5SD43A5CAA5D/9GQCAgwA
AgIera2QGzc4N5AbNww3A5DkkPr/ra2QGzc4N5AbNww3A5DkkPr/n/9ISDbjR/qQR/lIDQ==



==7310==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55e73f76f253 bp 0x7ffcc2a5cfe0 sp 0x7ffcc2a5cfd8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55e73f76f252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55e73f76d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55e73f7363c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55e73f73679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55e73f7367b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55e73f7367dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55e73f735e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e73f6f1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e73f6eeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e73f604c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e73f60689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e73f60411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e73f5f1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e73f5fa82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e73f5f2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e73f6dc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e73f5bd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e73f5bb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdc562c42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55e73f5ba749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fdc56b31d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55e73f6cad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55e73f7689d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55e73f768c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55e73f736090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55e73f7367d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55e73f735e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e73f6f1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e73f6eeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e73f604c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e73f60689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e73f60411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e73f5f1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e73f5fa82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e73f5f2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e73f6dc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e73f5bd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e73f5bb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdc562c42b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==7310==ABORTING

INPUT
GyoDGzca8wMCG6+vAJQAGCGvr68AFwMDAxsYAxsa8wMCG6+vAJQAGCGvr68ABEAAEBsZfn5+fn5+
fn5+fn5+fn5+fn5+fn5+fv8eHh4BMx4ZPIM8APypaOYAAI6kPBlW0Un///8A/2AEWx4EWx4AIAAL
AAIAAB/6vDw9C0AhGf5/AI6OgzwLLz0LlJSUlJSUlJSUlJSUlJSUlJSUlJSUlJSUADwAQ1bRABzI
BEAAGRUdVjwoKigoKCgoKCgoKCgoKBkoKCgeHh4eGBmaYDwjPQtAJhkQAGQeOQD8Hh4eGevr6+vr
6+vr6+vr6+vr/AD8dcgGAACOpFQABAMVPAAQjmuOjo6AqwD/AAB94UAAAxsZAAAD1Tw8GRAAPP8q
JFKgADyAPACrACAAAX0EQJv8GRAAPABDAPyOPBkQADz/jqQ8GVbRL////wD/YARbHgRb7AAgACx9
BEB//BkQ2hsF



==11625==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f27630e318c bp 0x7ffd33fa6980 sp 0x7ffd33fa6130
WRITE of size 227 at 0x62100002e100 thread T0
    #0 0x7f27630e318b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55f2789dd14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55f2789db6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55f2789e12c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55f2789f77bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55f2789f7929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55f2789f7b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55f2789a530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55f2789a5aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55f2789a4ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55f2789a4727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55f2789a47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55f2789a47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55f2789a3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55f27895f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55f27895caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55f278872c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55f27887489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55f27887211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55f27885ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55f27886882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55f278860d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55f27894a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55f27882b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55f2788298da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f27628d52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55f278828749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f2763143090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55f278938e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55f2789d7b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55f2789a43c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55f2789a479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55f2789a47b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55f2789a47dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55f2789a3e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55f27895f136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55f27895caa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55f278872c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55f27887489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55f27887211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55f27885ff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55f27886882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55f278860d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55f27894a0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55f27882b401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55f2788298da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f27628d52b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11625==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+q+NmAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA///AAA3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm8BADwoPICtkBs3ODeQGwA240gDkEf5SABAA5CADH8A7/+A/wAE6g3vDg0=



==18029==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7ffac583d18c bp 0x7ffc83455800 sp 0x7ffc83454fb0
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7ffac583d18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x559575fbb14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x559575fb96ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x559575fbf2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x559575fd57bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x559575fd5929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x559575fd5b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x559575f8330d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x559575f83aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x559575f82ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x559575f82727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x559575f827b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x559575f827dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x559575f81e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x559575f3d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x559575f3aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x559575e50c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x559575e5289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x559575e5011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x559575e3df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x559575e4682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x559575e3ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x559575f280f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x559575e09401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x559575e078da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7ffac502f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x559575e06749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7ffac589d090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x559575f16e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x559575fb5b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x559575f823c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x559575f8279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x559575f827b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x559575f827dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x559575f81e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x559575f3d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x559575f3aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x559575e50c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x559575e5289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x559575e5011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x559575e3df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x559575e4682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x559575e3ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x559575f280f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x559575e09401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x559575e078da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7ffac502f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18029==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAA5BH+UgsNwOQgDeQGzcAAQOf/5D6N5AbNww3
A0gWkEf5SD43A5CAA5D/9AACAgwAAgIera2gGzc4N5AbNz0Ifzg9C0MhGRkZGRkZMRkZLh5gGBmc
PjwjPQv/JhkLAGQeOQD80x4eKCi4KCgoKCgoKCgoKCgoHR4ouCgoKCgoKCgoKCgoKB0eHmAYGZw+
PCM9C0AmGRAAZB45APzTHsMo5+soKCgoKCgoKIAAAAAjPQtAJhkQAGQe6+vr69wZENobBQ==



==18030==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fb6b2ac618c bp 0x7ffe931bd420 sp 0x7ffe931bcbd0
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7fb6b2ac618b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55d473baa14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55d473ba86ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55d473bae2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55d473bc47bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55d473bc4929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55d473bc4b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55d473b7230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55d473b72aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55d473b71ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55d473b71727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55d473b717b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55d473b717dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55d473b70e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55d473b2c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55d473b29aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55d473a3fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55d473a4189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55d473a3f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55d473a2cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55d473a3582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55d473a2dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55d473b170f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55d4739f8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55d4739f68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fb6b22b82b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55d4739f5749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fb6b2b26090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55d473b05e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55d473ba4b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55d473b713c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55d473b7179c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55d473b717b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55d473b717dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55d473b70e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55d473b2c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55d473b29aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55d473a3fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55d473a4189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55d473a3f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55d473a2cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55d473a3582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55d473a2dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55d473b170f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55d4739f8401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55d4739f68da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fb6b22b82b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18030==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3PQh/
OD0FQyEZGRkZGRkxGRkuHmAYGZw+PCM9C/8mGQsAZB45APzTHh4o6wAcyARAAAMVGVY8KCooKCi4
KCgoKCgoKCgoKCgoHR4eYBgZnIA8Iz0LQCYZEABkHjkA/NMewyjn6ygoKCgoKCgoKB1gPCM7C0Am
GRAAZB7r6+vr3BkQ2v0F



==18033==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f312278418c bp 0x7ffe65579840 sp 0x7ffe65578ff0
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7f312278418b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x56330d4d414a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x56330d4d26ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x56330d4d82c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x56330d4ee7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x56330d4ee929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x56330d4eeb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x56330d49c30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x56330d49caef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x56330d49bee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x56330d49b727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x56330d49b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x56330d49b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x56330d49ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x56330d456136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x56330d453aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x56330d369c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x56330d36b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x56330d36911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x56330d356f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x56330d35f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x56330d357d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x56330d4410f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x56330d322401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x56330d3208da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f3121f762b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x56330d31f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f31227e4090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x56330d42fe00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x56330d4ceb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x56330d49b3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x56330d49b79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x56330d49b7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x56330d49b7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x56330d49ae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x56330d456136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x56330d453aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x56330d369c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x56330d36b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x56330d36911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x56330d356f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x56330d35f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x56330d357d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x56330d4410f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x56330d322401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x56330d3208da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f3121f762b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18033==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm+QGzc4N5ABADwoPIAANuNIA5BH+UgAQAOQgAx/AO//gP8ACeoN+g4N



==18036==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002f500 at pc 0x7fa9f554618c bp 0x7ffcfb311d50 sp 0x7ffcfb311500
WRITE of size 220 at 0x62100002f500 thread T0
    #0 0x7fa9f554618b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x556c60a5f14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x556c60a5d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x556c60a263c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x556c60a2679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x556c60a267b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x556c60a267dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x556c60a25e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x556c609e1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x556c609deaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x556c608f4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x556c608f689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x556c608f411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x556c608e1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x556c608ea82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x556c608e2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x556c609cc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x556c608ad401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x556c608ab8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fa9f4d382b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x556c608aa749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002f500 is located 0 bytes to the right of 4096-byte region [0x62100002e500,0x62100002f500)
allocated by thread T0 here:
    #0 0x7fa9f55a6090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x556c609bae00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x556c60a59b2c in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb2c)
    #3 0x556c60a263c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x556c60a2679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x556c60a267b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x556c60a267dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x556c60a25e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x556c609e1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x556c609deaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x556c608f4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x556c608f689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x556c608f411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x556c608e1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x556c608ea82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x556c608e2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x556c609cc0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x556c608ad401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x556c608ab8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fa9f4d382b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffde50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffde60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffde70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffde80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffde90: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdea0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdeb0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdec0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffded0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdee0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdef0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18036==ABORTING

INPUT
QCH/AEDo/wA8gAD+/6oANwNIA5BH+UgsNwBHYluRbx6ebwEAPCg8gAD+/6oA2oAAGwXr4wAAADwo
PIAA/v+qADcDSAOQR/lILDcDkIA3kBs3AAEDn/+Q+jeQGzcMNwNIFpBH+Ug+NwOQgAOQ//QAAgIM
AAICHq2tkBs3ODeQ////fx6ebwEAPCg8gAA240gDC0C8GRAAZGQA/wX//wVkPQsZEAiAPDz06gAg
gAADLRlWPLA8eKsA/wAKfPJAi5+O+/8d/wtAPBkfAGQ8PPUAABkQIJSNAxUZVgAjGxkIAAPoPDp/
/wUZAAAEJFMIGwU=



==20277==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000d180 at pc 0x7f0cdbdcf18c bp 0x7fff5357d7b0 sp 0x7fff5357cf60
WRITE of size 471 at 0x61900000d180 thread T0
    #0 0x7f0cdbdcf18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55fc61c7f14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55fc61c7d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55fc61c463c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55fc61c4679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55fc61c467b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55fc61c467dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55fc61c45e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55fc61c01136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55fc61bfeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55fc61b14c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55fc61b1689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55fc61b1411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55fc61b01f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55fc61b0a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55fc61b02d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55fc61bec0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55fc61acd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55fc61acb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f0cdb5c12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x55fc61aca749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000d180 is located 0 bytes to the right of 1024-byte region [0x61900000cd80,0x61900000d180)
allocated by thread T0 here:
    #0 0x7f0cdbe2ed28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55fc61bdad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55fc61c78405 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d405)
    #3 0x55fc61c78c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55fc61c46090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55fc61c467d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55fc61c45e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55fc61c01136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55fc61bfeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55fc61b14c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55fc61b1689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55fc61b1411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55fc61b01f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55fc61b0a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55fc61b02d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55fc61bec0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55fc61acd401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55fc61acb8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f0cdb5c12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9a30:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==20277==ABORTING

INPUT
/wMAAugDKh0AAACAVVUA5yNbG1WAAABwWxtVWh6fAPb///9/+1VVVQEAIAQAjpKSkpI8PQtAPBkQ
AB6APJI8PQtAPBkQAB6APGT8wwA8PP9//4A8PQFAPBkQAjyAPAD8kQA8g4ODAQCD4YODgzwDg4OD
gwGDgzw9C0BgBkD2Kzw8PABG//9/6AN1hnV1dYA8PQtAPBkQADyAPDwZ/BsAIAQAjo7/IP//jo6O
POgZEAA8PDwR5nV1dXV1cHBwcHBwcHBwcHBwcHBwcHBwcHBwcHBwdXV1dXV1dXV1dVZ1dXR1dTw8
GfwbPDwZ/BsAIAQAjo7/IP//jo6OPOgZACAEAI6O/yD//46OAgDoGRAAPDw8BACOjv8g//+Ojo48
6AsQACw7C5VgBFse/vgAfQRAA+g8PBkQ/yQAAVJSUlJSUlJAM1JSUlJSUlJSUlJSbvIbBQ==



==23399==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000d180 at pc 0x7f461aff718c bp 0x7ffcdc61ec60 sp 0x7ffcdc61e410
WRITE of size 317 at 0x61900000d180 thread T0
    #0 0x7f461aff718b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55f1e0d0f14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55f1e0d0d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55f1e0d13214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55f1e0d01986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x55f1e0d06784 in _rl_isearch_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x22b784)
    #6 0x55f1e0d06cae in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bcae)
    #7 0x55f1e0d017ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #8 0x55f1e0cd730d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #9 0x55f1e0cd6ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55f1e0cd6727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55f1e0cd67b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55f1e0cd67dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55f1e0cd5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55f1e0c91136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55f1e0c8eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55f1e0ba4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55f1e0ba689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55f1e0ba411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55f1e0b91f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55f1e0b9a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55f1e0b92d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55f1e0c7c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55f1e0b5d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55f1e0b5b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f461a7e92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55f1e0b5a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000d180 is located 0 bytes to the right of 1024-byte region [0x61900000cd80,0x61900000d180)
allocated by thread T0 here:
    #0 0x7f461b056d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55f1e0c6ad95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55f1e0d08405 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d405)
    #3 0x55f1e0d08c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55f1e0cd6090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55f1e0cd67d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55f1e0cd5e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55f1e0c91136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55f1e0c8eaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55f1e0ba4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55f1e0ba689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55f1e0ba411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55f1e0b91f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55f1e0b9a82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55f1e0b92d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55f1e0c7c0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55f1e0b5d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55f1e0b5b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f461a7e92b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9a20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9a30:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff9a80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==23399==ABORTING

INPUT
E//8BwIAAGTZPDw8Mhs3sZWVh5i1CwtguxcAgBsZGRkZAWAgYAsZGfDwZIDriwEAExISzcFfEhIT
EhMSJWZn/+8AQBMSNY7q+P8AAAAAAAPoUWRkZGQVw8zMzBIxbhcZEhLMzH+sj4+O4WQiDij///+A
EgwDEhISExOSEhIDUhIiAxISEgMwEjExMggICAhiCAgICwgICAgIABLOEh8SAID/AIASErDMf6km
j48Mj48IQAgICAhiCAj7CAgIiAgICBIAAAAgEwD8Eo+Pj4+Xf4+PjxwA/+//ErRn/+8AQBMSEs/M
bhOPj49kgFDg8AAAQAEDEhMSExL/Ml8SEhMSExIlZmf/7wBAExISAcEA4wEb/Y+PO5HfExISzMx/
EI/MzH/MzMwSEjSfEhLMbhcTEhLMzH/MzPsICAiICAgIEs4SGBITAPwSARMS3xMSEszMfxCPj48C
ZCI=



==31024==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55fd956d7253 bp 0x7fff465c9e60 sp 0x7fff465c9e58
READ of size 4 at 0x619000002280 thread T0
    #0 0x55fd956d7252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55fd956d56ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55fd9569e3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55fd9569e79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55fd9569e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55fd9569e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55fd9569de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55fd95659136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55fd95656aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55fd9556cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55fd9556e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55fd9556c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55fd95559f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55fd9556282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55fd9555ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55fd956440f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55fd95525401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55fd955238da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f9a1b6622b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55fd95522749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f9a1becfd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55fd95632d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55fd956d0960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55fd956d0c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55fd9569e090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55fd9569e7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55fd9569de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55fd95659136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55fd95656aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55fd9556cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55fd9556e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55fd9556c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55fd95559f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55fd9556282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55fd9555ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55fd956440f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55fd95525401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55fd955238da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f9a1b6622b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==31024==ABORTING

INPUT
G+ABawD/EP//gAAFvxV/9ls6/3+i6SR7JF44QCgqISh56J45BM1OqCmAACkqyLE5Hih9sbFUBMZ5
yJ45BM1OKClBGVxcXFyqjo6Ojo4AU2A8C0A0GRD8PDw8AFwAATEZGxlcXFxcqo6OjneOAFNgXjxg
////fwDfAFAaPDwQADQbNTU1NTWOjqA8PDwF//8FKDwAXAABPBkbGVxcXFyqjo6Ojp0ANTU1/yob
bwAbBQ==



==2224==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55bdc83f9253 bp 0x7ffc662b7a20 sp 0x7ffc662b7a18
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55bdc83f9252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55bdc83f76ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55bdc83c03c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55bdc83c079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55bdc83c07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55bdc83c07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55bdc83bfe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55bdc837b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55bdc8378aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55bdc828ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55bdc829089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55bdc828e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55bdc827bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55bdc828482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55bdc827cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55bdc83660f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55bdc8247401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55bdc82458da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa30cf0f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55bdc8244749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7fa30d77cd28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55bdc8354d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55bdc83f29d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55bdc83f2c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55bdc83c0090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55bdc83c07d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55bdc83bfe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55bdc837b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55bdc8378aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55bdc828ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55bdc829089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55bdc828e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55bdc827bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55bdc828482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55bdc827cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55bdc83660f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55bdc8247401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55bdc82458da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa30cf0f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==2224==ABORTING

INPUT
GykFFSQAAAB/XG1cXNcvFLYEzCQkAAAAf2RtXFzXLxS2BMyWFBsaGzgJ4hIA7wCAZAR7e2h7exAA
DBSUFBASG1MkLa0UAkAUUVBQUFA1UFBQUBsCG3WAL1iUVCQCG0gkK1ZIpBt5BBJoAAAAgDsAgBRA
h/19/ACPVVVHXFVVf25ubm5ubm5UVVVVblU3GwKWFP//ACCAUTKUFBsCG9cbgRvTGxsbAIAUJIgM
lvwAFiQbFhsCQIf9ffwAekD6QBST9VVVVVVVR1xVVX8AIFVVcwH1VAAbb7YE3v///3/5jgz/Kgyh
FAAEUxsgADoa+iADVP9k+v+WFD0aBAAJFI39/ypQ51A1UFBQUAyhFAAEUxsgADoa+iADVP9k+v//
GgT3/xsbgD0aBAAJFI39/yoMoRQABFMbIAA6GvogA1RTGzIyMjIyh/19/ACPDfpAFIAAAGTeLxQA
GxsbOBv9Uxu7GxsfGxsE//8F



==2252==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x559f7d546253 bp 0x7ffcd8c72e80 sp 0x7ffcd8c72e78
READ of size 4 at 0x619000002280 thread T0
    #0 0x559f7d546252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x559f7d5446ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x559f7d50d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x559f7d50d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x559f7d50d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x559f7d50d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x559f7d50ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x559f7d4c8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x559f7d4c5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x559f7d3dbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x559f7d3dd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x559f7d3db11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x559f7d3c8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x559f7d3d182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x559f7d3c9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x559f7d4b30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x559f7d394401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x559f7d3928da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7a8d0ab2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x559f7d391749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f7a8d918d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x559f7d4a1d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x559f7d53f960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x559f7d53fc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x559f7d50d090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x559f7d50d7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x559f7d50ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x559f7d4c8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x559f7d4c5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x559f7d3dbc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x559f7d3dd89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x559f7d3db11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x559f7d3c8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x559f7d3d182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x559f7d3c9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x559f7d4b30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x559f7d394401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x559f7d3928da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7a8d0ab2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==2252==ABORTING

INPUT
+d2UMRsaGy0tBf0pAKEUEEAkIHwxcy2WFBsbUyQbhxv/exAQEBAQEBAQEBA9C1A3GRAAZB45ABAQ
IxAQEAMbAhsBJS2WIBt73i8UlnZcZVxPkU0BgE1NAk5NAF4c/////031/f0B/f39/X39/SQoPE1L
YU1NPO7u7u7Y7u7u7u7uGRCmS2FNTU1NTU1NZB39TSQnjw5AIRn+fwD/////////////jo6jRgtA
VUD8GwCgAAAEPBkkGRkZIhkZGS4ZGRkZGeUDtPyOPBkQADz/KiRSjigoKChcT5FNAYBNTQJOTQBe
HP////9N9SooKPUoKCg8Hh4eGBmcYDwzPftQJhkQAGQeOQD80x4eGevr6+Pr65Tu7u7uAAAAAO7u
7u7u7u7V7hkUphsF



==3273==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f2242bef18c bp 0x7ffdf0962c60 sp 0x7ffdf0962410
WRITE of size 178 at 0x62100002e100 thread T0
    #0 0x7f2242bef18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55cf8d6ba14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55cf8d6b86ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55cf8d6be214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55cf8d6d41cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55cf8d6d4902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55cf8d6d4b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55cf8d68230d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55cf8d682aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55cf8d681ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55cf8d681727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55cf8d6817b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55cf8d6817dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55cf8d680e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55cf8d63c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55cf8d639aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55cf8d54fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55cf8d55189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55cf8d54f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55cf8d53cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55cf8d54582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55cf8d53dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55cf8d6270f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55cf8d508401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55cf8d5068da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f22423e12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55cf8d505749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f2242c4f090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55cf8d615e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55cf8d6b4b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55cf8d6813c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55cf8d68179c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55cf8d6817b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55cf8d6817dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55cf8d680e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55cf8d63c136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55cf8d639aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55cf8d54fc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55cf8d55189f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55cf8d54f11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55cf8d53cf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55cf8d54582e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55cf8d53dd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55cf8d6270f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55cf8d508401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55cf8d5068da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f22423e12b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3273==ABORTING

INPUT
QCH/APnn/wAAR2JbkW8enm8BADwoJoAWkEf5SD43A5CAA5D/9AACAQwAAgIera2QGzc4N5BH+RaQ
R/tIPjcDkIADkP/0AALqDAACAh6trZAbNzg3kBs3AQApKDyAADb/SAOQR/lIAEBH+UgAQAOQgAF/
AO//gP8ABOoN+g4N



==3276==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f9758c8018c bp 0x7ffdce3fa160 sp 0x7ffdce3f9910
WRITE of size 258 at 0x62100002e100 thread T0
    #0 0x7f9758c8018b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55666175614a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5566617546ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55666175a2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5566617707bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x556661770929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x556661770b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55666171e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55666171eaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55666171dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55666171d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55666171d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55666171d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55666171ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x5566616d8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x5566616d5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x5566615ebc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x5566615ed89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x5566615eb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x5566615d8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x5566615e182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x5566615d9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5566616c30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x5566615a4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x5566615a28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f97584722b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x5566615a1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f9758ce0090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x5566616b1e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x556661750b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55666171d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55666171d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55666171d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55666171d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55666171ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x5566616d8136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x5566616d5aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x5566615ebc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x5566615ed89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x5566615eb11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x5566615d8f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x5566615e182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x5566615d9d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5566616c30f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x5566615a4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x5566615a28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f97584722b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==3276==ABORTING

INPUT
QCH/AADo/wBHYluRbx6ebwEAPCg8gAD+/6oANww3A2oWkEc8gAD+/6oANww3A0gWkEf7SD43A5AD
kIA3kBs3+wEDn/+Q+jeQGzcMNwNIFpBH+Ug+NwOQgAOQ//QAAgIMIgICHq2tkBs3ODeQGzcMzh6e
bwEAPCg8gAA2ra2QGzc4N5AbNwzOHp5vAQA8/wAE6g36Dg0=



==11134==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x556ed1cf3253 bp 0x7ffeefad14e0 sp 0x7ffeefad14d8
READ of size 4 at 0x619000001d80 thread T0
    #0 0x556ed1cf3252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x556ed1cf16ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x556ed1cba3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x556ed1cba79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x556ed1cba7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x556ed1cba7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x556ed1cb9e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x556ed1c75136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x556ed1c72aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x556ed1b88c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x556ed1b8a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x556ed1b8811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x556ed1b75f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x556ed1b7e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x556ed1b76d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x556ed1c600f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x556ed1b41401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x556ed1b3f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7feccea6c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x556ed1b3e749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7feccf2d9d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x556ed1c4ed95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x556ed1cec9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x556ed1cecc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x556ed1cba090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x556ed1cba7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x556ed1cb9e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x556ed1c75136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x556ed1c72aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x556ed1b88c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x556ed1b8a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x556ed1b8811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x556ed1b75f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x556ed1b7e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x556ed1b76d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x556ed1c600f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x556ed1b41401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x556ed1b3f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7feccea6c2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11134==ABORTING

INPUT
GyoQExgaNUxSAAIAAAf/BwcZBwfojoCDYGBgAQCDEDw8PEg8PP9/GfdPAABTYC48i6sB//Z0/3//
/x48PDw8PQtiPBkQADyOjo4bjo6kQzw8PRuOGQcH6I6Ag2BgYAEAgxA8PDxIPQtiJRkQADz8GwA8
WD0bo46kQyk8PQtiVBkQAAADGxk8PJaOGWB/GQBQHjw8UzwAAIAAAAAQAF8LlBAAPPwbADwBqRuO
jqRDPDw9C2I8GRAAPPwbACALjTyDYGBgAQCDEDw8PEg8PP9/GTw7C3ZPAABTYC48YKtAAG8EGwU=



==12931==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f093946518c bp 0x7ffe1016cc30 sp 0x7ffe1016c3e0
WRITE of size 244 at 0x62100002e100 thread T0
    #0 0x7f093946518b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55d1fb84714a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55d1fb8456ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55d1fb84b2c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x55d1fb8617bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x55d1fb861929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x55d1fb861b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55d1fb80f30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55d1fb80faef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55d1fb80eee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55d1fb80e727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55d1fb80e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55d1fb80e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55d1fb80de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55d1fb7c9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55d1fb7c6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55d1fb6dcc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55d1fb6de89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55d1fb6dc11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55d1fb6c9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55d1fb6d282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55d1fb6cad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55d1fb7b40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55d1fb695401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55d1fb6938da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f0938c572b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55d1fb692749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f09394c5090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55d1fb7a2e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55d1fb841b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55d1fb80e3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55d1fb80e79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55d1fb80e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55d1fb80e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55d1fb80de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55d1fb7c9136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55d1fb7c6aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55d1fb6dcc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55d1fb6de89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55d1fb6dc11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55d1fb6c9f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55d1fb6d282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55d1fb6cad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55d1fb7b40f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55d1fb695401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55d1fb6938da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f0938c572b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==12931==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/ldXV1dXV1dXV1dXV1dXV1dXV1dXV1dXV1dXkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm88PDxTOwuUYAuUYCRbHjw8ODz/fxkAUB48PF08f////zxg///vIAABWBn//wAA/wAAAEAbBQ==



==13798==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55e3311b7253 bp 0x7ffcdf6acad0 sp 0x7ffcdf6acac8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55e3311b7252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55e3311b56ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55e33117e3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55e33117e79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55e33117e7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55e33117e7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55e33117de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e331139136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e331136aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e33104cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e33104e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e33104c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e331039f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e33104282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e33103ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e3311240f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e331005401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e3310038da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f130a9292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55e331002749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f130b196d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55e331112d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55e3311b0960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55e3311b0c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55e33117e090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55e33117e7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55e33117de93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55e331139136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55e331136aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55e33104cc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55e33104e89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55e33104c11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55e331039f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55e33104282e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55e33103ad17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55e3311240f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55e331005401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55e3310038da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f130a9292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==13798==ABORTING

INPUT
G+DfQfgA+h81GCrNTQW+/5cOazoRZP3pJHskXkxMTExMTExMFyh5sZpcBOuHKCkcHjw8/38ZHv87
YDw8YP///38AATwZGxk8PDw8PDw8t7e3t7e3t7e3t9m3t7e3t7e3OwAEYH08PDy3t7e3t7e3t7e3
2be3t7e3t7c7AEBgfWoQADQ1GzU1NTU1LCkAAH9tU088PGG0//9/AwE8bv8oFG8AGwU=



==15155==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d000019880 at pc 0x563574c3f253 bp 0x7ffeb4dd03d0 sp 0x7ffeb4dd03c8
READ of size 4 at 0x61d000019880 thread T0
    #0 0x563574c3f252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x563574c3d6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x563574c063c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x563574c0679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x563574c067b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x563574c067dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x563574c05e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x563574bc1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x563574bbeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x563574ad4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x563574ad689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x563574ad411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x563574ac1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x563574aca82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x563574ac2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x563574bac0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x563574a8d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x563574a8b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fa9e40a62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x563574a8a749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61d000019880 is located 0 bytes to the right of 2048-byte region [0x61d000019080,0x61d000019880)
allocated by thread T0 here:
    #0 0x7fa9e4914090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x563574b9ae00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x563574c3c2de in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2312de)
    #3 0x563574c063c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x563574c0679c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x563574c067b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x563574c067dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x563574c05e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x563574bc1136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x563574bbeaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x563574ad4c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x563574ad689f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x563574ad411f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x563574ac1f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x563574aca82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x563574ac2d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x563574bac0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x563574a8d401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x563574a8b8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fa9e40a62b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c3a7fffb2c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb2d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb2e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb2f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb300: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c3a7fffb310:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb320: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb330: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb340: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb350: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15155==ABORTING

INPUT
G3tkIBcB9vQLe2QgFwH29AAMIpT/GwL7UyRClgARfv//jgACPDweOy2NQjw8PP9/GQBQjrCOZBsN
AAB/AH8AQOhcBACOjv9+//+OjjxaGRCZmQA8PDwA344AAgAAPDw8/38ZPD0LQGB/QAsrG45/AQC8
PD0LQDwZEAA8PDgAPP9/GQBkHjw8PAEAjrB4jl0RPY7kf////wBA//9/GQBQjo6OZI6Oi46OXTw9
PED/jgACPDwZey2eQjw8PP9/GQBQjo6OZI6Om46OXTw9PEA8GQAAAQAEAI6O/37//46OPDwZEAA8
PDwA/I4AAhAAgAAASj0Z6wA8PDwg/I4AQQRAUB48PDw9C0COe108PTxIPBkAAAEABACOjv9+//+O
jjw8GZiYAm7yGwU=



==15156==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55ca690ab253 bp 0x7fff6227dc60 sp 0x7fff6227dc58
READ of size 4 at 0x619000002280 thread T0
    #0 0x55ca690ab252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55ca690a96ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55ca690723c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55ca6907279c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55ca690727b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55ca690727dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55ca69071e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55ca6902d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55ca6902aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55ca68f40c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55ca68f4289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55ca68f4011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55ca68f2df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55ca68f3682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55ca68f2ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55ca690180f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55ca68ef9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55ca68ef78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f04206342b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55ca68ef6749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f0420ea1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55ca69006d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55ca690a4960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55ca690a4c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55ca69072090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55ca690727d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55ca69071e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55ca6902d136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55ca6902aaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55ca68f40c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55ca68f4289f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55ca68f4011f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55ca68f2df42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55ca68f3682e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55ca68f2ed17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55ca690180f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55ca68ef9401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55ca68ef78da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f04206342b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==15156==ABORTING

INPUT
GyoV+P8AYGAbAK/obxAQEBAQEBAjTHZ/32FMJf+AWgAwUzwk9AAbBevjANDQ0NDQ0NDQ0NDQ0NCe
bwH4KCgoGSgoJB4nABn/AP9gBIBb/wD/Hh4e7zIeGZSU55SUlJSUlJSUlJQAAgAAOvq8PFtVGVbR
AByvBAAAHgRbHgA3AEUBF44AAZT/lJSUlJSUlJSUlAA3AEMBCI4AAQAAKCg9C0AACwD5/wAf+tE8
W1VhYWFhHK8igP8eBI0eGVYAGRUdeTwAIAALAAIAAB///wCCi5SUlJSUl5T/////lJSUlJSUqpSU
lAA8AEMA/I75+fn5+fn5+eT5+fn5+fn5+fn5+fn5+fk7+y4APP8qJDSOpFUZVkUBF44AAZT/lJSU
lJSUlJSUlAA3AEPRABzIBEAAGSQ0VjwoEK6urq6urq6urq6urq6urq6urgAQrq6urq6urq6urq4B
AAAoKCgoKCgLKCwZSQPoHmRaNhgZmmA8Iz0LQCYZEABkHjkA/B4eHhnS6+vr6+vr6+vr68vr6/wA
/HXIBgAAl6RUAgQDFTwAEI5rjo6OgKsA/wABAAA1AP9AADwZVgAZFR15PCjRL///AIAZENobBQ==



==18849==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fdb49d7b18c bp 0x7ffd45258550 sp 0x7ffd45257d00
WRITE of size 223 at 0x62100002e100 thread T0
    #0 0x7fdb49d7b18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x5599838c314a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x5599838c16ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x5599838c72c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x5599838dd7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x5599838dd929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x5599838ddb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55998388b30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55998388baef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55998388aee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55998388a727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55998388a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55998388a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x559983889e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x559983845136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x559983842aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x559983758c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55998375a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55998375811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x559983745f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55998374e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x559983746d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x5599838300f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x559983711401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55998370f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fdb4956d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55998370e749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fdb49ddb090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55998381ee00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x5599838bdb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55998388a3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55998388a79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55998388a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55998388a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x559983889e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x559983845136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x559983842aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x559983758c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55998375a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55998375811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x559983745f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55998374e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x559983746d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x5599838300f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x559983711401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55998370f8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fdb4956d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==18849==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAACA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3kBs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDdk
PDwBB44AEGQ9CxkQAGQ8PPUEACB//+ktGVY8sDx4qwD/AAB9BECLn477////C0A8GRAAZDw89QAA
GRAglI0DFRlWACMbGQgAA+g8OhkQBRkAAAPoPDoZPP8qJFMIAAB9BEAAQBsZAAAD6Dw6GRAFPAEA
JFMIGwU=



==19040==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x560c47a3e253 bp 0x7ffe1df962b0 sp 0x7ffe1df962a8
READ of size 4 at 0x619000002280 thread T0
    #0 0x560c47a3e252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x560c47a3c6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x560c47a053c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x560c47a0579c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x560c47a057b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x560c47a057dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x560c47a04e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560c479c0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x560c479bdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560c478d3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x560c478d589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x560c478d311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560c478c0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x560c478c982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560c478c1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x560c479ab0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x560c4788c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x560c4788a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdf4ba342b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x560c47889749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fdf4c2a1d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x560c47999d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x560c47a37960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x560c47a37c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x560c47a05090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x560c47a057d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x560c47a04e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x560c479c0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x560c479bdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x560c478d3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x560c478d589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x560c478d311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x560c478c0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x560c478c982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x560c478c1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x560c479ab0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x560c4788c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x560c4788a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fdf4ba342b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==19040==ABORTING

INPUT
GwMV9DoVPDw7IgCOwdDQ0P9/0HoA0P9/0HoAEKg8PDw8PCP5TwAAAAEuPICrC/+Nk2BWAAAAAAEA
PDw86WsZ908ePDw0GQEZGRkZFxkZGRkZGRkZGRmAFVlg6AwAAMwZGRkZRF+AAAcOTf8ZgBX+YNMM
AMcb908ePDw0GQEZGRkZFxkZGRkZGRkZGRmAFVkF



==19043==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7ff37041e18c bp 0x7ffca0ea9d50 sp 0x7ffca0ea9500
WRITE of size 186 at 0x62100002e100 thread T0
    #0 0x7ff37041e18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55b6ceb6d14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55b6ceb6b6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55b6ceb71214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55b6ceb871cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55b6ceb87902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55b6ceb87b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55b6ceb3530d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55b6ceb35aef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55b6ceb34ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55b6ceb34727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55b6ceb347b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55b6ceb347dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55b6ceb33e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55b6ceaef136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55b6ceaecaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55b6cea02c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55b6cea0489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55b6cea0211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55b6ce9eff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55b6ce9f882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55b6ce9f0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55b6ceada0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55b6ce9bb401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55b6ce9b98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7ff36fc102b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55b6ce9b8749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7ff37047e090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55b6ceac8e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55b6ceb67b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55b6ceb343c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55b6ceb3479c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55b6ceb347b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55b6ceb347dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55b6ceb33e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55b6ceaef136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55b6ceaecaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55b6cea02c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55b6cea0489f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55b6cea0211f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55b6ce9eff42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55b6ce9f882e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55b6ce9f0d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55b6ceada0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55b6ce9bb401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55b6ce9b98da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7ff36fc102b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==19043==ABORTING

INPUT
QCH/VQDo/wAAR2JbkWUenm8BADwoPIAA/v+qANqAABsF6+MBA5//kPo3kBspDDcDSBaQR/lIPjcD
kIADkP/0AAICDAACAh6trZAbNzg3kBs3DBQiIiIiIiI3eAv5+aioqKgAGzg4OE44ODg4ODg4ODg4
ODg4ODg4ODg4ODg4ODg4i3uqqqpgq6Ie+1+oqMqoqMGoqKioqKgnJx8nJyeqqmCrfzc4N5AbNwwU
IiIiIiIiNwD7X6moyqio+fn6EPn5+aioqJSoqCcnHycnJ6qqYKt/+fnr+fn5+fn5+fn5+fn5+fn5
AID//6ioqAAbBQ==



==20245==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d00001ca80 at pc 0x7fc83557d18c bp 0x7ffd61ccea10 sp 0x7ffd61cce1c0
WRITE of size 574 at 0x61d00001ca80 thread T0
    #0 0x7fc83557d18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x555d2af2214a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x555d2af206ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x555d2af26214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x555d2af14986 in rl_display_search (/home/dualbus/src/gnu/bash-build/bash+0x226986)
    #5 0x555d2af19c09 in rl_search_history (/home/dualbus/src/gnu/bash-build/bash+0x22bc09)
    #6 0x555d2af147ac in rl_reverse_search_history (/home/dualbus/src/gnu/bash-build/bash+0x2267ac)
    #7 0x555d2aeea30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x555d2aee9ee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #9 0x555d2aee9727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #10 0x555d2aee97b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #11 0x555d2aee97dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #12 0x555d2aee8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #13 0x555d2aea4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #14 0x555d2aea1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #15 0x555d2adb7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #16 0x555d2adb989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #17 0x555d2adb711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #18 0x555d2ada4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #19 0x555d2adad82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #20 0x555d2ada5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #21 0x555d2ae8f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #22 0x555d2ad70401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #23 0x555d2ad6e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #24 0x7fc834d6f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #25 0x555d2ad6d749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61d00001ca80 is located 0 bytes to the right of 2048-byte region [0x61d00001c280,0x61d00001ca80)
allocated by thread T0 here:
    #0 0x7fc8355dd090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x555d2ae7de00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x555d2af1cb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x555d2aee93c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x555d2aee979c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x555d2aee97b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x555d2aee97dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x555d2aee8e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x555d2aea4136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x555d2aea1aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x555d2adb7c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x555d2adb989f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x555d2adb711f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x555d2ada4f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x555d2adad82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x555d2ada5d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x555d2ae8f0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x555d2ad70401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x555d2ad6e8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fc834d6f2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c3a7fffb900: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb910: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb920: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb930: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c3a7fffb950:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb960: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb970: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb980: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffb990: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffb9a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==20245==ABORTING

INPUT
gm6CgqSCgoKCgqUAJiIbGx6QGzeQGzcbN/q6urq6uhADkP/5SCw3A5CADAAAAACAYCU8UZAAAAAQ
A5D/+UgsNwOQgAwAAPIAgGAlPFGPAAAEf4AAEI6Ojo5kYCU8UY6OXTw9CwDRPElSAI5kYCU8UY6O
XTx8C0DRjo6wjmQ8SVIA/AMVGVY8jo6wjmSOXTw9C0BSAPwDFRk+PI7gjo5kjqaOjqBdPD0LHjwl
/AAAAIAAGQIVGVY8SWzF0f///4DFosXF6B48PDwZsQw8El7/bvIbBQ==



==21207==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x56455c804253 bp 0x7fff05aa78c0 sp 0x7fff05aa78b8
READ of size 4 at 0x619000002280 thread T0
    #0 0x56455c804252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x56455c8026ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x56455c7cb3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x56455c7cb79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x56455c7cb7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x56455c7cb7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x56455c7cae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x56455c786136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x56455c783aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x56455c699c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56455c69b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56455c69911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x56455c686f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56455c68f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x56455c687d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x56455c7710f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x56455c652401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x56455c6508da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7fea3292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x56455c64f749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7f7feab96d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x56455c75fd95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x56455c7fd960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x56455c7fdc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x56455c7cb090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x56455c7cb7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x56455c7cae93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x56455c786136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x56455c783aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x56455c699c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x56455c69b89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x56455c69911f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x56455c686f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x56455c68f82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x56455c687d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x56455c7710f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x56455c652401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x56455c6508da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f7fea3292b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==21207==ABORTING

INPUT
GyoQExgaNUxSAAIAAAf/BwcZBwfojoCDYGBgAQCDEDw8PABTYC48i6sB//9/YEAAAAMbGTw8PDw8
PDw8//9///8ePDw8PDwBAI6Ojo6Ojo6OG46OpEM8PD0bjo6kQzw8AQCOjo4Ojo6OjhuOjqRDPDw9
Gz0LQGAEYAsrG46OIAC8PD0LQDwZEAA8PDwAPP9/GQBQHjw8PB48PDw8/38ZAFAePQtAYARACysb
ZI6OoY6OXTw9C0A8GfwbACAEAI6O/3///46Ojjw8GQAAAAE8APyOAAIAADw9C0A9GRAAPDw8APyO
ACsqjo6kPDx/AAAAAARAAAMVGVY8SQA8OwuUYARbHgRbHjw8PDz/fxkAUB48PDw9C0A8GRAAPIA8
APx3AAL6AAMVPAEAjo6Ojo6OqwD/AAB9BEAAAycnJycnJycnJycnJycnJxknJycnJycnGxkAAAAB
PDwZEAA8/yokbvIbBQ==



==22214==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000001d80 at pc 0x55931c893253 bp 0x7fff171dc540 sp 0x7fff171dc538
READ of size 4 at 0x619000001d80 thread T0
    #0 0x55931c893252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55931c8916ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55931c85a3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55931c85a79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55931c85a7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55931c85a7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55931c859e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55931c815136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55931c812aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55931c728c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55931c72a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55931c72811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55931c715f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55931c71e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55931c716d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55931c8000f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55931c6e1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55931c6df8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f9a177d32b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55931c6de749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000001d80 is located 0 bytes to the right of 1024-byte region [0x619000001980,0x619000001d80)
allocated by thread T0 here:
    #0 0x7f9a18040d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55931c7eed95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55931c88c9d9 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d9d9)
    #3 0x55931c88cc75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55931c85a090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55931c85a7d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55931c859e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55931c815136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55931c812aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55931c728c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55931c72a89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55931c72811f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55931c715f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55931c71e82e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55931c716d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55931c8000f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55931c6e1401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55931c6df8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f9a177d32b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8360: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8370: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8380: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8390: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff83a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff83b0:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83c0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff83d0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83e0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff83f0: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
  0x0c327fff8400: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22214==ABORTING

INPUT
GyoqLxs3AwMCGyYDGxrzJioFBAAWKgMyf/wZENoOBUQBAAAAAP+rAAAAARYEKgUDKQ4IKgUYEAAC
/xcAAAAg6+sAAQDr6/wg/PI8ABCAYY6OKiSN6AYAAI6WPBlRKBkZABAAfwtW0RDlZB45APzTHgCs
ACDr22D/fx4EBEAAAyD/YAAAODw9GQD80xcAAAAg6+sAAQDr6/wg/PI8AAAEYY6OKiSN/n8Ajo7o
AwsvPQAAf//8GxCgAAEvGzcZGRkZGRkZVtEQAGQexEn///wA/mAETR4AZAABfQQyfy8ZENoAAxUA
EDwoIxkZGRkZGRkZGRkZAEMA/AEAAAAdQf8qJFKOpDwLVtEQAGQeOQD80xcAAAAg6+sAAQDr6/wg
/PI8ABCAAH+OKiSN6ABAAI6WO+oEAvI8ABD///9/KiRSAAFJ////AP9gBE0eAGP//30EMn/8GRDa
GwU=



==22509==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d00001d480 at pc 0x7f966303d063 bp 0x7ffd61099390 sp 0x7ffd61098b40
READ of size 123 at 0x61d00001d480 thread T0
    #0 0x7f966303d062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
    #1 0x55f679fe9115 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234115)
    #2 0x55f679fe76ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55f679fb03c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55f679fb079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55f679fb07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55f679fb07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55f679fafe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55f679f6b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55f679f68aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55f679e7ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55f679e8089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55f679e7e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55f679e6bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55f679e7482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55f679e6cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55f679f560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55f679e37401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55f679e358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f96628552b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x55f679e34749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61d00001d480 is located 0 bytes to the right of 2048-byte region [0x61d00001cc80,0x61d00001d480)
allocated by thread T0 here:
    #0 0x7f96630c3090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55f679f44e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55f679fe3b2c in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb2c)
    #3 0x55f679fb03c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55f679fb079c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55f679fb07b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55f679fb07dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55f679fafe93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55f679f6b136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55f679f68aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55f679e7ec89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55f679e8089f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55f679e7e11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55f679e6bf42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55f679e7482e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55f679e6cd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55f679f560f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55f679e37401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55f679e358da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f96628552b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062) 
Shadow bytes around the buggy address:
  0x0c3a7fffba40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffba50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffba60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffba70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffba80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c3a7fffba90:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbaa0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbab0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbac0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c3a7fffbad0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c3a7fffbae0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22509==ABORTING

INPUT
GyoDAxYK+gIDAQMWChtTJC2WAAAAIFOALxR/ABsCG1MkKHkO/yL6DBSUCAQCG1Pilf2WEBsbGygA
oRQAAnt7e3veLxSWFBsbGynoA1T/GxsZYAR7e3t7e3t7EJYbGynoA1T/GxsZYAR7e3t7e3t7EJb8
AJYEmpqampoampoE3i8UAAAAgBs44p3xI4f9lhuAFP8bGxlU9t5m5yaH/xuMAAAAe3v6IANU/xsb
fwAbAhtTPCh5G//elhP6GhveLxSWFBsbG////39UABAAAJX9lhAbGxsoAKEUJHt7e3t73i8UAAD/
/xsqAKEUAn//GxuQGyT6IANU/xsbfwAbAhtTJCh5G/8a+gwUlAAEAhtT4pUbVATeLxS/FBsbAAL9
UxsvG1QEGxsbG1QAAP//GyoAoRRAAACX7ZYQGxsbIOp8fBr6fHxigH9o2QMbZFFRUVH9/xr6DBSU
AAQCG1PilRt5G/8aDBSUQAR7e3t7e/oMFJQABHt7e3t73oAUJIf9lvwAlgQbAv1TGxUbABsbGVT2
3i8+lgTelhQbGhveLxSWFBsbNRsBGxtUZucmh/8bjAAAAHt7+iADVP8bEH8AGwIbUyQoeRv/GgwU
lCgEe3t7e3v6DBSUAAR7e3t7e94vFJYUABsbKgChFAKAABsbGzgbHxsbBP//BQ==



==22586==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x619000002280 at pc 0x55b74d08c253 bp 0x7ffc298427e0 sp 0x7ffc298427d8
READ of size 4 at 0x619000002280 thread T0
    #0 0x55b74d08c252 in update_line (/home/dualbus/src/gnu/bash-build/bash+0x234252)
    #1 0x55b74d08a6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #2 0x55b74d0533c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #3 0x55b74d05379c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #4 0x55b74d0537b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #5 0x55b74d0537dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #6 0x55b74d052e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b74d00e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b74d00baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b74cf21c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b74cf2389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b74cf2111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b74cf0ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b74cf1782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b74cf0fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b74cff90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b74ceda401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b74ced88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbc1fcec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #19 0x55b74ced7749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x619000002280 is located 0 bytes to the right of 1024-byte region [0x619000001e80,0x619000002280)
allocated by thread T0 here:
    #0 0x7fbc20559d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55b74cfe7d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55b74d085960 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d960)
    #3 0x55b74d085c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55b74d053090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55b74d0537d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55b74d052e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55b74d00e136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55b74d00baa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55b74cf21c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55b74cf2389f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55b74cf2111f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55b74cf0ef42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55b74cf1782e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55b74cf0fd17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55b74cff90f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55b74ceda401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55b74ced88da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7fbc1fcec2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/home/dualbus/src/gnu/bash-build/bash+0x234252) in update_line
Shadow bytes around the buggy address:
  0x0c327fff8400: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8410: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8420: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8430: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8440: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff8450:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8460: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff8470: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8480: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff8490: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff84a0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22586==ABORTING

INPUT
GzxNGTw8JB4A5ikWCgCqqqqqqqqqIKqqqqqqqqqqqqo0NBGFBn///4AAAAHtEhISqWgABBISqWgA
BAAAZxYv/np/MDAwMDAwMDAwMBAwMDAwMDAwMDAwMDAcAzChQOUaLxykZLiFAAAA/wG4GzQ0NDQ0
hQZ///+AAAAB7YkAfAIBqQAA/+U3ZyMvFhv/5TdnNDQ0STQ0NDQ0GzQXNDQ0NDQAEAAAe3t7e3t7
e3t7e3t7e3t7ZXt7e3t7ezAwMDAwMDAwMDPnIUCaYGBgYG8Q/1sYAA==



==22797==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7fec5498e18c bp 0x7ffd5b73be60 sp 0x7ffd5b73b610
WRITE of size 194 at 0x62100002e100 thread T0
    #0 0x7fec5498e18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55d53b59614a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55d53b5946ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55d53b59a214 in rl_message (/home/dualbus/src/gnu/bash-build/bash+0x238214)
    #4 0x55d53b5b01cd in _rl_arg_getchar (/home/dualbus/src/gnu/bash-build/bash+0x24e1cd)
    #5 0x55d53b5b0902 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e902)
    #6 0x55d53b5b0b59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x55d53b55e30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x55d53b55eaef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x55d53b55dee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x55d53b55d727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x55d53b55d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x55d53b55d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x55d53b55ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x55d53b518136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x55d53b515aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x55d53b42bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x55d53b42d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x55d53b42b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x55d53b418f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x55d53b42182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x55d53b419d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x55d53b5030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x55d53b3e4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x55d53b3e28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7fec541802b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x55d53b3e1749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7fec549ee090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x55d53b4f1e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x55d53b590b99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x55d53b55d3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55d53b55d79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55d53b55d7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55d53b55d7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55d53b55ce93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55d53b518136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55d53b515aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55d53b42bc89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55d53b42d89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55d53b42b11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55d53b418f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55d53b42182e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55d53b419d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55d53b5030f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55d53b3e4401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55d53b3e28da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7fec541802b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==22797==ABORTING

INPUT
QCH/AADnCxUAR2JbkW8enm8BAP///4AASAOQR/lILDcDkIA3kBs3AAEDn/+Q+jeQGykMNwNIFpBH
+Ug+NwOQgAOQ//QAAgIMQAICHq2tkBs3ODeQGzcMNx6ebwEAPCg8gBs3ODeQGzcMNx6ebwEAPCg8
gAA24wD//3//Dk0=



==26489==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61900000ccbd at pc 0x7f47f7aea18c bp 0x7ffffdc438c0 sp 0x7ffffdc43070
WRITE of size 46 at 0x61900000ccbd thread T0
    #0 0x7f47f7aea18b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x55c13014e14a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x55c13014c6ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x55c1301153c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x55c13011579c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x55c1301157b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x55c1301157dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x55c130114e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x55c1300d0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x55c1300cdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x55c12ffe3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x55c12ffe589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x55c12ffe311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x55c12ffd0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x55c12ffd982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x55c12ffd1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x55c1300bb0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x55c12ff9c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x55c12ff9a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f47f72dc2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #20 0x55c12ff99749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x61900000ccbd is located 61 bytes to the right of 1024-byte region [0x61900000c880,0x61900000cc80)
allocated by thread T0 here:
    #0 0x7f47f7b49d28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c1300a9d95 in xmalloc (/home/dualbus/src/gnu/bash-build/bash+0x18fd95)
    #2 0x55c130147442 in init_line_structures (/home/dualbus/src/gnu/bash-build/bash+0x22d442)
    #3 0x55c130147c75 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22dc75)
    #4 0x55c130115090 in readline_internal_setup (/home/dualbus/src/gnu/bash-build/bash+0x1fb090)
    #5 0x55c1301157d8 in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7d8)
    #6 0x55c130114e93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #7 0x55c1300d0136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #8 0x55c1300cdaa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #9 0x55c12ffe3c89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #10 0x55c12ffe589f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #11 0x55c12ffe311f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #12 0x55c12ffd0f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #13 0x55c12ffd982e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #14 0x55c12ffd1d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #15 0x55c1300bb0f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #16 0x55c12ff9c401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #17 0x55c12ff9a8da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #18 0x7f47f72dc2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c327fff9940: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9950: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9960: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9970: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff9980: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c327fff9990: fa fa fa fa fa fa fa[fa]fa fa fa fa fa fa fa fa
  0x0c327fff99a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c327fff99b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c327fff99e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==26489==ABORTING

INPUT
Gy0Ct78A/xP1/yv8xR8QAQAT/wAA9gtQHtk8PDwyGzexlZWVlbWVlZXpf4iVlaUfEBstBCARGy0U
xR8QAQAT/yN/I0pQHtk8PDwyGziVlTwZlJTnlJSUlJSUlJSUlAACAAAfErw8W1UZVtEAHK8EQAAe
BFseADcAQwEXjgABlP+UlJSUlJSUlJSUADcAQwEIjgABAAAoKD0LQAALAPn/AB/60TxbVWFhYWEc
rwSA/x4EWx4ZVgAZFR15PAAgAAsAAgAAH///AIKLlJSUlJSXlJSUlP+UlJSUlJSqlJSUADwAQwD8
jvn5+fn5+fn5+fn5+fn5+fn5+fn5+fn5+Tv7LgA8/yokUo6kVRlW0QAcyARAABkkNFY8KBCurq6u
rq6urltbW1tbW1tbW1tbW1tbW1uurq6urq6uAQAAKCgoKCgoCygsGUkD6B5kHh4YGZpgPID/C0Am
GRAAZB45APweHh4Z6+vr6+vr6+vr6+vL6+v8APx1yAYAAJetVAIEAxU8ABCOa46OjoCrAP8AAQAA
QAD/QAA8GVYAGRUdeTwo0S///wCAGRDaGwU=



==26788==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x62100002e100 at pc 0x7f1b8d64318c bp 0x7ffdafe4a180 sp 0x7ffdafe49930
WRITE of size 222 at 0x62100002e100 thread T0
    #0 0x7f1b8d64318b in memmove (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b)
    #1 0x555b2fd5514a in update_line (/home/dualbus/src/gnu/bash-build/bash+0x23414a)
    #2 0x555b2fd536ab in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x2326ab)
    #3 0x555b2fd592c2 in rl_clear_message (/home/dualbus/src/gnu/bash-build/bash+0x2382c2)
    #4 0x555b2fd6f7bc in _rl_arg_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x24e7bc)
    #5 0x555b2fd6f929 in rl_digit_loop (/home/dualbus/src/gnu/bash-build/bash+0x24e929)
    #6 0x555b2fd6fb59 in rl_digit_argument (/home/dualbus/src/gnu/bash-build/bash+0x24eb59)
    #7 0x555b2fd1d30d in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fc30d)
    #8 0x555b2fd1daef in _rl_dispatch_subseq (/home/dualbus/src/gnu/bash-build/bash+0x1fcaef)
    #9 0x555b2fd1cee8 in _rl_dispatch (/home/dualbus/src/gnu/bash-build/bash+0x1fbee8)
    #10 0x555b2fd1c727 in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb727)
    #11 0x555b2fd1c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #12 0x555b2fd1c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #13 0x555b2fd1be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #14 0x555b2fcd7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #15 0x555b2fcd4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #16 0x555b2fbeac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #17 0x555b2fbec89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #18 0x555b2fbea11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #19 0x555b2fbd7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #20 0x555b2fbe082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #21 0x555b2fbd8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #22 0x555b2fcc20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #23 0x555b2fba3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #24 0x555b2fba18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #25 0x7f1b8ce352b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #26 0x555b2fba0749 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7f749)
0x62100002e100 is located 0 bytes to the right of 4096-byte region [0x62100002d100,0x62100002e100)
allocated by thread T0 here:
    #0 0x7f1b8d6a3090 in realloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc2090)
    #1 0x555b2fcb0e00 in xrealloc (/home/dualbus/src/gnu/bash-build/bash+0x18fe00)
    #2 0x555b2fd4fb99 in rl_redisplay (/home/dualbus/src/gnu/bash-build/bash+0x22eb99)
    #3 0x555b2fd1c3c6 in _rl_internal_char_cleanup (/home/dualbus/src/gnu/bash-build/bash+0x1fb3c6)
    #4 0x555b2fd1c79c in readline_internal_char (/home/dualbus/src/gnu/bash-build/bash+0x1fb79c)
    #5 0x555b2fd1c7b9 in readline_internal_charloop (/home/dualbus/src/gnu/bash-build/bash+0x1fb7b9)
    #6 0x555b2fd1c7dd in readline_internal (/home/dualbus/src/gnu/bash-build/bash+0x1fb7dd)
    #7 0x555b2fd1be93 in readline (/home/dualbus/src/gnu/bash-build/bash+0x1fae93)
    #8 0x555b2fcd7136 in edit_line (/home/dualbus/src/gnu/bash-build/bash+0x1b6136)
    #9 0x555b2fcd4aa4 in read_builtin (/home/dualbus/src/gnu/bash-build/bash+0x1b3aa4)
    #10 0x555b2fbeac89 in execute_builtin (/home/dualbus/src/gnu/bash-build/bash+0xc9c89)
    #11 0x555b2fbec89f in execute_builtin_or_function (/home/dualbus/src/gnu/bash-build/bash+0xcb89f)
    #12 0x555b2fbea11f in execute_simple_command (/home/dualbus/src/gnu/bash-build/bash+0xc911f)
    #13 0x555b2fbd7f42 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb6f42)
    #14 0x555b2fbe082e in execute_connection (/home/dualbus/src/gnu/bash-build/bash+0xbf82e)
    #15 0x555b2fbd8d17 in execute_command_internal (/home/dualbus/src/gnu/bash-build/bash+0xb7d17)
    #16 0x555b2fcc20f4 in parse_and_execute (/home/dualbus/src/gnu/bash-build/bash+0x1a10f4)
    #17 0x555b2fba3401 in run_one_command (/home/dualbus/src/gnu/bash-build/bash+0x82401)
    #18 0x555b2fba18da in main (/home/dualbus/src/gnu/bash-build/bash+0x808da)
    #19 0x7f1b8ce352b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
SUMMARY: AddressSanitizer: heap-buffer-overflow (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x6218b) in memmove
Shadow bytes around the buggy address:
  0x0c427fffdbd0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbe0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdbf0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x0c427fffdc10: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
=>0x0c427fffdc20:[fa]fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc30: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc40: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc50: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc60: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c427fffdc70: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==26788==ABORTING

INPUT
QCH/AADo/wAAR2JbkW8enm8BADwoPIAA/v+qANqAABsF6+MAAAA8KDyAAP7/qgA3A0gDkEf5SCw3
A5CAN5AbNwABA5//kPo3ghs3DDcDSBaQR/lIPjcDkIADkP/0AAICDAACAh6trZAbNzg3kBs3DDce
nm9ARk1NTU1NY03/JCg8TUtNYU0qAd/f/3U8Uv9NTWD9Ev36/f29/f39/R/+/f39/f1LPtk8TUsr
Ad/f/zU8Uv9NTWD9/f39/f0g/f39/fL9TTs7Ozs7hYWFhYWFhYWFhYWFhYWF/f07Ozs7Ozs7Ozs7
Ozv/kEpgPAAQAAA1PDIAAQAAGwBjTf9/JjxiYmJiYmJiYmJiYiAAGwU=



-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 11:02:54 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLWIQ-0000VL-5o
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 11:02:54 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45634)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLWIM-0000UK-Ha
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:02:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLWII-00049I-8J
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:02:50 -0400
Received: from mail-ot0-x22e.google.com ([2607:f8b0:4003:c0f::22e]:36799)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLWII-00048y-0y
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:02:46 -0400
Received: by mail-ot0-x22e.google.com with SMTP id s7so11588880otb.3
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 08:02:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=Rui4WWqTcZOwqVDfnRjtJRwmIrWSHr0WHVDcqASWnPo=;
	b=HrObECCNUiWwwb5YNgESLWIzClUr+uhS3/LTJD1LIz4IrT1mchZgxQW5r7NtdV3RNP
	RpB7JE1VVyG5qG7yXbrOrpHXp9P0pC6xO4uFZkGAqBHG3n6EqGMI7r+gNfsDcQ48zRNR
	TZdasA7P0H/H0iknBsIifoOwD1hIGBzWCgOskFrgJloajguoYoZApr1AHRxbGWr9063c
	DdavtrDLPYdzC+BlGrpltmGUQWWWv//JdKy9XEiRUFj5VM9pSX89FtM1289eipssdDeR
	R08G9dCY6aVL1K25ylDsL9DQ6/Qw4nebf61vj0kWHHltWFDGGffgwbbpVmLn0nhTp6qz
	vfHQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=Rui4WWqTcZOwqVDfnRjtJRwmIrWSHr0WHVDcqASWnPo=;
	b=ViDFC8v1T6SBTtTmE4TQ5rQw2Xa1IMOG60SZt2M3rwY5oUQGZceBbLAtgfxWF7Ak+F
	5AUQ85LkvlC0E8XDW0pq3xl4tftbybDukAQApFlXRPWM2+eOEmH96Tbp26jxTEhsYBBW
	UullGsDMiUPZ+CDgoQQsDhOGjWIXoh2x3fKhKNx1q04h3WuLUqA8ehd8yQ8Swa57bLFA
	kG5WcgfTxSXHi9UcFdp92JviB4p5w5qx+/X9g+nfrb1+yK2qC2ahu/Nxb+vEq8hRdWPs
	XiPFvmUf0LNAEPVRgdZ8ZlF9FqTOWG2MaKeSGmzRaAyCGTwLJrAw3USowfCoMZpueopk
	/Cvw==
X-Gm-Message-State: AKS2vOxiJ8rGSGErTsuLLHIbagAFnJh1q+9S5wZ+51bCgUveIHQqJBuS
	csuupnVLCN8EBA==
X-Received: by 10.157.14.36 with SMTP id c33mr3848435otc.204.1497538964833;
	Thu, 15 Jun 2017 08:02:44 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id d27sm180720ote.41.2017.06.15.08.02.43
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 15 Jun 2017 08:02:44 -0700 (PDT)
Date: Thu, 15 Jun 2017 10:02:42 -0500
From: Eduardo Bustamante <dualbus@gmail.com>
To: L A Walsh <bash@tlinx.org>
Cc: PePa <peterkelly@passchier.net>, bug-bash <bug-bash@gnu.org>
Subject: Re: Patch for unicode in varnames...
Message-ID: <20170615150242.6xh5u5j7eflvji7m@debian>
References: <CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org>
	<20170602045255.4uqtbnsxryrfc432@debian>
	<5930F4AE.1050308@tlinx.org>
	<20170602131846.rclunctr5ri2s4jr@debian>
	<59327149.6000007@tlinx.org>
	<1496512817.17253.69.camel@scope-eye.net>
	<b145a1ac-4381-eb20-7f6b-567df6778d52@passchier.net>
	<20170604074538.36cmislgervrqiqw@debian>
	<593455D1.9050706@tlinx.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <593455D1.9050706@tlinx.org>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22e
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 15:02:52 -0000

I'll leave my progress on the Unicode identifiers patch here (or the PR
in Github, if you fancy that:
https://github.com/dualbus/bash/pull/2/files).

I won't have much time to work on this for a few weeks, so it's up to
you all to complete it :-) It has markers on the places where it needs
work (mainly more `ifdef HANDLE_MULTIBYTE' and passing a wide character
instead of a single byte character to `legal_variable_starter').



diff --git a/expr.c b/expr.c
index fee7a4aa..c7b9dc7e 100644
--- a/expr.c
+++ b/expr.c
@@ -1286,6 +1286,7 @@ readtok ()
     }
   lasttp = tp = cp - 1;
 
+  /* XXX: Update */
   if (legal_variable_starter (c))
     {
       /* variable names not preceded with a dollar sign are shell variables. */
@@ -1293,6 +1294,7 @@ readtok ()
       EXPR_CONTEXT ec;
       int peektok;
 
+      /* XXX: Update */
       while (legal_variable_char (c))
 	c = *cp++;
 
@@ -1417,6 +1419,7 @@ readtok ()
 	  xp = cp;
 	  while (xp && *xp && cr_whitespace (*xp))
 	    xp++;
+          /* XXX: Update */
 	  if (legal_variable_starter ((unsigned char)*xp))
 	    c = (c == '-') ? PREDEC : PREINC;
 	  else
diff --git a/general.c b/general.c
index 584e7859..bf9d683b 100644
--- a/general.c
+++ b/general.c
@@ -214,18 +214,51 @@ int
 legal_identifier (name)
      const char *name;
 {
-  register const char *s;
-  unsigned char c;
+#ifdef HANDLE_MULTIBYTE
+  wchar_t *p, *s;
+  wchar_t c;
+  size_t n;
+#else
+  char *p, *s;
+  char c;
+#endif
+
+  if (!name || *name == '\0')
+    return (0);
+
+#ifdef HANDLE_MULTIBYTE
+  n = mbstowcs (NULL, name, 0);
+  if ((size_t) -1 == n)
+    return (0);
 
-  if (!name || !(c = *name) || (legal_variable_starter (c) == 0))
+  s = xmalloc (sizeof(wchar_t) * (n+1));
+  if (!s)
     return (0);
 
-  for (s = name + 1; (c = *s) != 0; s++)
+  n = mbstowcs(s, name, n+1);
+  if ((size_t) -1 == n)
+    goto illegal_name;
+#else
+  s = name;
+#endif
+
+  if (legal_variable_starter (*s) == 0)
+    goto illegal_name;
+
+  for (p = s + 1; (c = *p) != 0; p++)
     {
       if (legal_variable_char (c) == 0)
-	return (0);
+	goto illegal_name;
     }
+
   return (1);
+
+  illegal_name:
+#ifdef HANDLE_MULTIBYTE
+    if (s)
+      free (s);
+#endif
+    return (0);
 }
 
 /* Return 1 if NAME is a valid value that can be assigned to a nameref
@@ -349,6 +382,11 @@ legal_alias_name (string, flags)
   return 1;
 }
 
+#ifdef HANDLE_MULTIBYTE
+#define WC_OR_C(c) (L##c)
+#else
+#define WC_OR_C(c) (c)
+#endif
 /* Returns non-zero if STRING is an assignment statement.  The returned value
    is the index of the `=' sign.  If FLAGS&1 we are expecting a compound assignment
    and don't want an array subscript before the `='. */
@@ -357,27 +395,45 @@ assignment (string, flags)
      const char *string;
      int flags;
 {
-  register unsigned char c;
   register int newi, indx;
+#ifdef HANDLE_MULTIBYTE
+  wchar_t c;
+  wchar_t *ws;
+  int nb;
+  size_t n;
+#else
+  char c;
+  char *ws;
+#endif
+
+#ifdef HANDLE_MULTIBYTE
+  n = strlen(string);
+  nb = mbtowc (&c, &string[indx = 0], n);
+  if ((size_t) nb == -1)
+    return (0);
+
+  indx += nb; n -= nb;
+#else
+  indx++;
+#endif
 
-  c = string[indx = 0];
 
 #if defined (ARRAY_VARS)
-  if ((legal_variable_starter (c) == 0) && ((flags&1) == 0 || c != '[')) /* ] */
+  if ((legal_variable_starter (c) == 0) && ((flags&1) == 0 || c != WC_OR_C ('['))) /* ] */
 #else
   if (legal_variable_starter (c) == 0)
 #endif
     return (0);
 
-  while (c = string[indx])
+  while ((nb=mbtowc (&c, &string[indx], n)) > 0)
     {
       /* The following is safe.  Note that '=' at the start of a word
 	 is not an assignment statement. */
-      if (c == '=')
+      if (c == WC_OR_C ('='))
 	return (indx);
 
 #if defined (ARRAY_VARS)
-      if (c == '[')
+      if (c == WC_OR_C ('['))
 	{
 	  newi = skipsubscript (string, indx, (flags & 2) ? 1 : 0);
 	  if (string[newi++] != ']')
@@ -389,7 +445,7 @@ assignment (string, flags)
 #endif /* ARRAY_VARS */
 
       /* Check for `+=' */
-      if (c == '+' && string[indx+1] == '=')
+      if (c == WC_OR_C ('+') && string[indx+1] == '=')
 	return (indx + 1);
 
       /* Variable names in assignment statements may contain only letters,
@@ -397,7 +453,11 @@ assignment (string, flags)
       if (legal_variable_char (c) == 0)
 	return (0);
 
+#ifdef HANDLE_MULTIBYTE
+      indx += nb; n -= nb;
+#else
       indx++;
+#endif
     }
   return (0);
 }
diff --git a/general.h b/general.h
index d55f26bf..5452e956 100644
--- a/general.h
+++ b/general.h
@@ -103,8 +103,13 @@ extern char *strcpy __P((char *, const char *));
 
 
 /* Define exactly what a legal shell identifier consists of. */
+#ifdef HANDLE_MULTIBYTE
+#define legal_variable_starter(wc) (iswalpha(wc) || (L'_' == wc))
+#define legal_variable_char(wc) (iswalnum(wc) || (L'_' == wc))
+#else
 #define legal_variable_starter(c) (ISALPHA(c) || (c == '_'))
 #define legal_variable_char(c)	(ISALNUM(c) || c == '_')
+#endif
 
 /* Definitions used in subst.c and by the `read' builtin for field
    splitting. */
diff --git a/subst.c b/subst.c
index 3093309f..3bd399dd 100644
--- a/subst.c
+++ b/subst.c
@@ -6717,6 +6717,7 @@ parameter_brace_expand_rhs (name, value, op, quoted, pflags, qdollaratp, hasdoll
   free (t);
 
   /* bash-4.4/5.0 */
+  /* XXX: Update */
   vname = name;
   if (*name == '!' &&
       (legal_variable_starter ((unsigned char)name[1]) || DIGIT (name[1]) || VALID_INDIR_PARAM (name[1])))
@@ -7070,6 +7071,7 @@ get_var_and_type (varname, value, ind, quoted, flags, varp, valp)
   SHELL_VAR *v;
   arrayind_t lind;
 
+  /* XXX: Update */
   want_indir = *varname == '!' &&
     (legal_variable_starter ((unsigned char)varname[1]) || DIGIT (varname[1])
 					|| VALID_INDIR_PARAM (varname[1]));
@@ -8217,6 +8219,7 @@ parameter_brace_expand (string, indexp, quoted, pflags, quoted_dollar_atp, conta
   sindex = *indexp;
   t_index = ++sindex;
   /* ${#var} doesn't have any of the other parameter expansions on it. */
+  /* XXX: Update */
   if (string[t_index] == '#' && legal_variable_starter (string[t_index+1]))		/* {{ */
     name = string_extract (string, &t_index, "}", SX_VARNAME);
   else
@@ -8330,6 +8333,7 @@ parameter_brace_expand (string, indexp, quoted, pflags, quoted_dollar_atp, conta
   /* Indirect expansion begins with a `!'.  A valid indirect expansion is
      either a variable name, one of the positional parameters or a special
      variable that expands to one of the positional parameters. */
+  /* XXX: Update */
   want_indir = *name == '!' &&
     (legal_variable_starter ((unsigned char)name[1]) || DIGIT (name[1])
 					|| VALID_INDIR_PARAM (name[1]));
@@ -8388,6 +8392,7 @@ parameter_brace_expand (string, indexp, quoted, pflags, quoted_dollar_atp, conta
     }
 
   /* Process ${!PREFIX*} expansion. */
+  /* XXX: Update */
   if (want_indir && string[sindex - 1] == RBRACE &&
       (string[sindex - 2] == '*' || string[sindex - 2] == '@') &&
       legal_variable_starter ((unsigned char) name[1]))
@@ -9213,6 +9218,7 @@ comsub:
       /* Find the variable in VARIABLE_LIST. */
       temp = (char *)NULL;
 
+      /* XXX: Update */
       for (t_index = zindex; (c = string[zindex]) && legal_variable_char (c); zindex++)
 	;
       temp1 = (zindex > t_index) ? substring (string, t_index, zindex) : (char *)NULL;
diff --git a/variables.c b/variables.c
index a08313d7..a41f1ba0 100644
--- a/variables.c
+++ b/variables.c
@@ -4409,6 +4409,7 @@ valid_exportstr (v)
       internal_error (_("%s has null exportstr"), v->name);
       return (0);
     }
+  /* XXX: Update */
   if (legal_variable_starter ((unsigned char)*s) == 0)
     {
       internal_error (_("invalid character %d in exportstr for %s"), *s, v->name);
@@ -4418,6 +4419,7 @@ valid_exportstr (v)
     {
       if (*s == '=')
 	break;
+      /* XXX: Update */
       if (legal_variable_char ((unsigned char)*s) == 0)
 	{
 	  internal_error (_("invalid character %d in exportstr for %s"), *s, v->name);


-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 15 11:03:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLWJM-00019l-DJ
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 11:03:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45950)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLWJF-00019E-ND
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:03:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLWJA-0004bn-OO
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:03:45 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:62711
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLWJA-0004ax-Ij
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:03:40 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AME45215; Thu, 15 Jun 2017 11:03:35 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFY93006 (AUTH cpr);
	Thu, 15 Jun 2017 11:03:34 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: PePa <peterkelly@passchier.net>, "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
Date: Thu, 15 Jun 2017 11:03:34 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.15.142117:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_EURO, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_1700_1799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	__FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS, IN_REP_TO,
	MSG_THREAD, __FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 15:03:50 -0000

On 6/14/17 8:54 PM, PePa wrote:
> On 15/06/2560 07:13, Chet Ramey wrote:
>> A character that is classified as an alphanumeric in a particular locale,
>> but not in another, can lead to portability problems. That's what we're
>> debating here, not how something gets displayed in a text editor.
> 
> I don't think that exists in unicode or UTF-8 -- could you give an
> example of a character that is classified as an alphanumeric in a
> particular locale, but not in another?

I don't know other languages well enough to point one out, but I can easily
imagine that a particular character is an "alphabetic" in, say, Mandarin,
but doesn't exist in someone's en_US character set.

> 
> I think this whole discussion about alphanumerics in world languages is
> a red herring though. I don't see any objection in using any
> symbol/glyph as admissible in variable names, barring certain reserved
> ASCII ones, like space, comma, dot, dash, several kinds braces etc.
> It would also greatly simplify the whole implementation.

I see a number of problems with using non-alphanumerics in shell
identifiers.  The real advantage to allowing this is to allow users to
put alphabetics from their own locales into shell identifiers.  There's
little reason to do it otherwise, and plenty of complications.

As for the implementation, it's much easier to use isalpha/isdigit (and
their wide character equivalents) than to try and keep track of a blacklist
of characters across different locales.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 15 11:22:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLWbI-0002P0-Pp
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 11:22:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56161)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLWbG-0002Oj-9j
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:22:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLWbD-0006Sz-17
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:22:22 -0400
Received: from mail-pf0-x232.google.com ([2607:f8b0:400e:c00::232]:33302)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dLWbC-0006SV-RD
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:22:18 -0400
Received: by mail-pf0-x232.google.com with SMTP id 83so8906400pfr.0
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 08:22:17 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:from:subject:to:references:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=XCpqOHX81828g7zQ2qNNtYXhT11Wu1eUxbf2j7gx+Pw=;
	b=uoBVVVH61vVB50+7TDe9Pl4ltBjvNkZmGbeIOkTvJGqDE6es+iTsckI8PyxkqLjldI
	a8Xh8msh+VkOkwsH1tR7StI8f/oZlRRnLnqRbJ4OGpFT0EBw2dui/elPqXBQYQEtPPCK
	qlV5SEs3zpWNogK7WLNoeYp4Oxum/0U7tTdxWcAbDSO7290W63naCLCOfGu5cxcLmp9m
	CCglKeumttFlyFb6b5uRwUsK3+Fyw08vNQiYgCDuJZGYPF8otjWyF24ct1wjwXRCQLsZ
	EeuhabuLdLdxpqVcVIaXL4fcGw34bc+BbhLOd2eebQAwTqH+rzhKYMED5BOKSqeP9NHB
	a91Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:from:subject:to:references:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=XCpqOHX81828g7zQ2qNNtYXhT11Wu1eUxbf2j7gx+Pw=;
	b=VojICk9ruDzZAF9d423KLvnmh/qfpMLyzf0WCkiZeo/k4koJCMHlK2ZyMjAe7Rx9Kc
	v7Rkm+Etptoao7dMttIUDe3MDeI1MYRjIrbCipfKhsSZZBCI4F5nLa1XNi4A2NsU2m9P
	agyRg7TdcHsWEhIQx52u+7LUqVKgszp+bnAgIewidxmg7rJGSkPft4pb/8AsXxBzHFnn
	GQJqAy8vQxV+3gXGckwV2UJO4hxoDLoqYjlthubIsf1YMOJrByS/WSpJWxjvvBu207+s
	jnSrRNPuGC10nunI4PqqJeUC/kBegsVNtGNU/h/3nie8SMHAQZ8x+DGo8Il6vJFtgkJj
	W04A==
X-Gm-Message-State: AKS2vOzpcyEwogH5UUGdEc9DOI08Ls9MuBNMQyythsqpbC6GpTp5E6vK
	6r33/0oS5ZdZmORX
X-Received: by 10.84.174.1 with SMTP id q1mr6791537plb.8.1497540135865;
	Thu, 15 Jun 2017 08:22:15 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.61.201])
	by smtp.gmail.com with ESMTPSA id t9sm1017045pfj.77.2017.06.15.08.22.11
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 15 Jun 2017 08:22:12 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
From: PePa <peterkelly@passchier.net>
X-Google-Original-From: PePa <solusos@passchier.net>
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
	<3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
Message-ID: <7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
Date: Thu, 15 Jun 2017 22:22:09 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::232
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 15:22:23 -0000

On 15/06/2560 22:03, Chet Ramey wrote:
> I don't know other languages well enough to point one out, but I can easily
> imagine that a particular character is an "alphabetic" in, say, Mandarin,
> but doesn't exist in someone's en_US character set.

I though you were referring to a character existing in both sets.
This is the reason why I think you should only concern yourself with
characters that already have an established semantic in bash. Don't get
bogged down in distinguishing classes in myriads of character sets. Just
allow anything that isn't ASCII (but IS UTF-8 -- I'm talking about
UTF-8, otherwise this discussion becomes impossible).

> I see a number of problems with using non-alphanumerics in shell
> identifiers.  The real advantage to allowing this is to allow users to
> put alphabetics from their own locales into shell identifiers.  There's
> little reason to do it otherwise, and plenty of complications.

What are those problems and complications??

> As for the implementation, it's much easier to use isalpha/isdigit (and
> their wide character equivalents) than to try and keep track of a blacklist
> of characters across different locales.

I don't propose blacklists across locales, just blacklisting what
already has an established meaning in bash, ie. ASCII. All the rest is
just fair game, if someone insists on using a thumbs-up icon in a
variable name, why restrict that?? The restricting and policing is going
to make this costly in terms of developer time and CPU time.

Peter


From MAILER-DAEMON Thu Jun 15 11:36:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLWoy-0007nM-JC
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 11:36:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:32828)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dLWov-0007lH-6V
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:36:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dLWos-0003eR-2K
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:36:29 -0400
Received: from out01.mta.xmission.com ([166.70.13.231]:47472)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <gazelle@xmission.com>)
	id 1dLWor-0003b4-T5
	for bug-bash@gnu.org; Thu, 15 Jun 2017 11:36:25 -0400
Received: from mx04.mta.xmission.com ([166.70.13.214])
	by out01.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>) id 1dLWof-0008Dn-3Y
	for bug-bash@gnu.org; Thu, 15 Jun 2017 09:36:13 -0600
Received: from shell.xmission.com ([166.70.8.4])
	by mx04.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>) id 1dLWoe-0006kl-PI
	for bug-bash@gnu.org; Thu, 15 Jun 2017 09:36:12 -0600
Received: from gazelle by shell.xmission.com with local (Exim 4.86_2)
	(envelope-from <gazelle@xmission.com>) id 1dLWoe-0000mG-Aq
	for bug-bash@gnu.org; Thu, 15 Jun 2017 09:36:12 -0600
From: gazelle@xmission.com
To: bug-bash@gnu.org
Subject: Why does 'connect' take so long (sometimes) and can't be interrupted?
Message-Id: <E1dLWoe-0000mG-Aq@shell.xmission.com>
Date: Thu, 15 Jun 2017 09:36:12 -0600
X-XM-SPF: eid=1dLWoe-0006kl-PI; ; ; mid=<E1dLWoe-0000mG-Aq@shell.xmission.com>;
	; ; hst=mx04.mta.xmission.com; ; ; ip=166.70.8.4; ; ;
	frm=gazelle@xmission.com; ; ; spf=neutral
X-SA-Exim-Connect-IP: 166.70.8.4
X-SA-Exim-Mail-From: gazelle@xmission.com
X-SA-Exim-Scanned: No (on mx04.mta.xmission.com);
	SAEximRunCond expanded to false
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 166.70.13.231
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 15:36:30 -0000

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-unknown-linux-gnu' -DCONF_VENDOR='unknown' -DLOCALEDIR='/.../local/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H   -I.  -I. -I./include -I./lib   -g -O2 -Wno-parentheses -Wno-format-security
uname output: Linux shell 4.4.0-79-generic #100-Ubuntu SMP Wed May 17 19:58:14 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-unknown-linux-gnu

Bash Version: 4.4
Patch Level: 0
Release Status: release

Description:
	This is a little complicated and I can't give you full details on how to
	replicate it, since I don't fully understand it myself.  But under certain
	circumstances, the following line takes a very long time to execute:

	    exec 5<>/dev/tcp/localhost/12345

	My objections are twofold:
	    a) That it takes so long - it should either succeed or file (almost)
		immediately.
	    b) When it is running, it is uninterruptable.  None of ^C, ^\, or ^Z, nor
		any signal sent to the bash process (other than SIGKILL) will cause
		it to exit.  Effectively, the only escape is to SIGKILL the bash
		process, which causes the entire shell to be killed.

	More details below.

Repeat-By:
	I am using a bash script to communicate with a program that I wrote (in C)
	using TCPIP.  The C program listens on port 12345 (for example) and the bash
	script connects to it, using the command line shown above.  The actual lines
	in my script are now as follows:

	    printf "Elapsed time for this 'exec' ...\t";tme=$(date +%s)
	    exec 5<>/dev/tcp/localhost/12345
	    echo "$(($(date +%s) - $tme)) seconds."

	Normally, for almost all possible inputs (to the C program), this executes
	immediately (says "0 seconds" elapsed).  But, for one particular input, it
	takes a very long time - in my most recent test, it was 116 seconds (!).
	This problem is 100% repeatable (with the given specific input to the C
	program).

	Note, however, that it does eventually connect.  As far as I can tell, it
	does always eventually connect.

	Needless to say, when I first hit this problem, I assumed it had hung, and
	when I tried to kill it, I ran into the problems described above.

	Also note: In testing this, I found that if I do hit ^C while it is hung,
	then wait long enough, eventually it does exit as shown below:

Elapsed time for this 'exec' ...	^C^C^C^Cbash: connect: Connection refused
bash: /dev/tcp/localhost/12345: Connection refused

Fix:
	Well, I'd like to know why it (sometimes) takes so long.
	Amd it would be nice if you could interrupt it when it does hang.
	Or, alternatively, set a timelimit for the connect().



From MAILER-DAEMON Thu Jun 15 14:16:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLZJZ-0001Iy-QC
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 14:16:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46434)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <Jon.Morris@jbarisk.com>) id 1dLXf1-0005k0-2g
	for bug-bash@gnu.org; Thu, 15 Jun 2017 12:30:20 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <Jon.Morris@jbarisk.com>) id 1dLXex-0007rr-RI
	for bug-bash@gnu.org; Thu, 15 Jun 2017 12:30:19 -0400
Received: from mail-db5eur01on0040.outbound.protection.outlook.com
	([104.47.2.40]:39723
	helo=EUR01-DB5-obe.outbound.protection.outlook.com)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <Jon.Morris@jbarisk.com>)
	id 1dLXex-0007rG-7A
	for bug-bash@gnu.org; Thu, 15 Jun 2017 12:30:15 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jbarisk.com;
	s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; 
	bh=LndMsCoB6zRENCpG60Z0hI02btSJPffkcoSFLaa4NGo=;
	b=mio3BpDFwYFYFkW6tDowkwPX7DETHlePW61scKKltpmeBa8BopVLf+Jf8rDbLTgOx2KfRNZk2Y2+RqkHUSrn2plg5QKGEFll/+cwdhAmysIT8REu1/ZZL3A4GukUIIFkwsNkuJgOWbJYPFvozaCNPc646b0YNsSBk9QNgYiG9+U=
Received: from VI1PR0502MB3086.eurprd05.prod.outlook.com (10.175.20.12) by
	VI1PR0502MB3086.eurprd05.prod.outlook.com (10.175.20.12) with Microsoft
	SMTP Server (version=TLS1_2,
	cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id
	15.1.1157.12; Thu, 15 Jun 2017 16:30:11 +0000
Received: from VI1PR0502MB3086.eurprd05.prod.outlook.com
	([fe80::a9e8:7fda:30d3:6832]) by
	VI1PR0502MB3086.eurprd05.prod.outlook.com
	([fe80::a9e8:7fda:30d3:6832%16]) with mapi id 15.01.1157.017;
	Thu, 15 Jun 2017 16:30:11 +0000
From: Jon Morris <Jon.Morris@jbarisk.com>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: cygheap base mismatch detected 
Thread-Topic: cygheap base mismatch detected 
Thread-Index: AdLl9FW4fYUV8k0UTqO3y2pQLozfsA==
Date: Thu, 15 Jun 2017 16:30:11 +0000
Message-ID: <VI1PR0502MB3086D84D5E14BBCB79D68E3882C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
Accept-Language: en-GB, en-US
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
authentication-results: gnu.org; dkim=none (message not signed)
	header.d=none; gnu.org; dmarc=none action=none header.from=jbarisk.com; 
x-originating-ip: [146.90.234.239]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; VI1PR0502MB3086;
	20:gIJd99AglYiK+THGiMM4e5rvN3vFuFKoELaSTWGEXxVokS+fQCUQjb+KZyvVj/SyraK8RV9ljmHPHMcv9k5b9BNlDkBZZF7LwD1EypGVIaoXnpweGnS0zOg7CNSB+BC0BZAP3Gq+TL5w6tEnnNICl6Czu2xIEw+2yocSobDLqFQ=
x-ms-traffictypediagnostic: VI1PR0502MB3086:
x-ms-office365-filtering-correlation-id: 6f2eb0ab-d9cf-4651-b7d2-08d4b40bcb1d
x-microsoft-antispam: UriScan:; BCL:0; PCL:0;
	RULEID:(22001)(2017030254075)(201703131423075)(201703031133081)(201702281549075);
	SRVR:VI1PR0502MB3086; 
x-microsoft-antispam-prvs: <VI1PR0502MB3086F3457382FCA8CDF76E4782C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(148322886591682)(22074186197030)(31418570063057)(116415991822766)(128460861657000)(21748063052155)(81160342030619);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0;
	RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(93006095)(93001095)(10201501046)(3002001)(100000703101)(100105400095)(6041248)(201703131423075)(201703061421075)(20161123562025)(20161123560025)(20161123555025)(20161123558100)(20161123564025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);
	SRVR:VI1PR0502MB3086; BCL:0; PCL:0;
	RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);
	SRVR:VI1PR0502MB3086; 
x-forefront-prvs: 0339F89554
x-forefront-antispam-report: SFV:NSPM;
	SFS:(10009020)(39450400003)(39400400002)(50944005)(377424004)(5660300001)(50986999)(25786009)(38730400002)(189998001)(110136004)(6436002)(54356999)(236005)(53376002)(6506006)(790700001)(6306002)(33656002)(9686003)(102836003)(6116002)(81166006)(3480700004)(9326002)(54896002)(45080400002)(53546009)(5630700001)(8676002)(8936002)(2900100001)(2501003)(53936002)(14454004)(10126004)(2351001)(508600001)(3280700002)(99286003)(7906003)(3846002)(66066001)(5640700003)(7696004)(74316002)(7736002)(7066003)(55016002)(72206003)(5250100002)(2906002)(606005)(6916009)(3660700001)(86362001)(460985005);
	DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR0502MB3086;
	H:VI1PR0502MB3086.eurprd05.prod.outlook.com; FPR:; SPF:None;
	MLV:ovrnspm; PTR:InfoNoRecords; LANG:en; 
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
MIME-Version: 1.0
X-OriginatorOrg: jbarisk.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Jun 2017 16:30:11.0507 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 3131e85c-e560-4bb3-a82f-8b339ad41833
X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0502MB3086
X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy]
X-Received-From: 104.47.2.40
X-Mailman-Approved-At: Thu, 15 Jun 2017 14:16:16 -0400
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 16:30:20 -0000

Hi,

Just tried to submit a bug, but bashbug command failed, so here is the prob=
lem text.

Thanks,

Jon

From: jonmorris
To: bug-bash@gnu.org
Subject: cygheap base mismatch detected

Configuration Information [Automatically generated, do not change]:
Machine: i686
OS: msys
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM=3D'bash.exe' -DCONF_HOSTTYPE=3D'i686' -DCONF=
_OSTYPE=3D'msys' -DCONF_MACHTYPE=3D'i686-pc-msys' -DCONF_VENDOR=3D'pc' -DLO=
CALEDIR=3D'/usr/share/locale' -DPACKAGE=3D'bash' -DSHELL -DHAVE_CONFIG_H -D=
RECYCLES_PIDS   -I.  -I. -I./include -I./lib  -DWORDEXP_OPTION -march=3Di68=
6 -mtune=3Dgeneric -O2 -pipe -D_STATIC_BUILD
uname output: MSYS_NT-10.0-WOW SKI-748MRF2 2.6.0(0.304/5/3) 2016-09-09 09:3=
2 i686 Msys
Machine Type: i686-pc-msys

Bash Version: 4.3
Patch Level: 46
Release Status: release

Description:
                I'm using ConEmu 161206 and keep getting the following erro=
r, but have been unable to fix it. Searching for cygwin1.dll returns no res=
ults.

0 [main] sh (8992) C:\Program Files\Cmder\vendor\git-for-windows\usr\bin\sh=
.exe: *** fatal error - cygheap base mismatch detected - 0x642E6408/0x12164=
08. This problem is probably due to using incompatible versions of the cygw=
in DLL. Search for cygwin1.dll using the Windows Start->Find/Search facilit=
y and delete all but the most recent version.  The most recent version *sho=
uld* reside in x:\cygwin\bin, where 'x' is the drive on which you have inst=
alled the cygwin distribution.  Rebooting is also suggested if you are unab=
le to find another cygwin DLL.


Repeat-By:
                Problem is intermittent and cannot be reliably repeated.

Fix:
                [Description of how to fix the problem.  If you don't know =
a
                fix for the problem, don't include this section.]




Jon Morris
Software Developer

t: +44 (0) 1756 799919
Please click here<http://www.jbarisk.com/get-touch> if you would like to su=
bscribe to our email news


Find out more about us here: www.jbarisk.com<http://www.jbarisk.com/> and f=
ollow us on Twitter @JBARisk<http://twitter.com/JBARisk> and LinkedIn<https=
://www.linkedin.com/company/2370847?trk=3Dtyah&trkInfo=3DclickedVertical%3A=
company%2CclickedEntityId%3A2370847%2Cidx%3A2-1-2%2CtarId%3A1447414259786%2=
Ctas%3AJBA%20RISK%20MANAGEMENT>

The JBA Group supports the JBA Trust.

All JBA Risk Management's email messages contain confidential information a=
nd are intended only for the individual(s) named. If you are not the named =
addressee you should not disseminate, distribute or copy this e-mail.
Please notify the sender immediately by email if you have received this ema=
il by mistake and delete this email from your system.


JBA Risk Management Limited is registered in England, company number 077329=
46, South Barn, Broughton Hall, Skipton, North Yorkshire, BD23 3AE, Telepho=
ne: +441756799919



From MAILER-DAEMON Thu Jun 15 14:19:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLZN3-00035n-EC
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 14:19:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43215)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZN1-00032c-1k
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:19:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZN0-0000LV-C2
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:19:51 -0400
Received: from mail-qt0-x230.google.com ([2607:f8b0:400d:c0d::230]:34981)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLZN0-0000KM-8J
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:19:50 -0400
Received: by mail-qt0-x230.google.com with SMTP id w1so31119896qtg.2
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 11:19:48 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=DgA5T2is1qpav02sbXNkX3vhuzAWjEZjsnNJggJC05k=;
	b=q/zr0aDjgHGdB3UIV8E6rfFaylUrrCpWMjCZXgA8/M7qAedYvoosLJ+mVh+zp2wxms
	ls8gMhlLn28bfHAdrJVhfFXMKZyr6tMpX9oYNZnBwD+C9uw+8Npcxw69HRL4inILcWtY
	ZETwdr/0rOOh1spY09nEXqyTGHHBNNdvhhqUaCdOLhn/3Z6Xde0Pnmmjb6VcL8iNh6QO
	KP6hicuAWnpNjAEapZExWi86guk4OIE/sDqi52ijRZcwy4NgZysJ0OVirljZDPJYKrbz
	aV1/VKSbYregadmi6ZLSsJxwY8Mwebh/eJVHl6WYAbJXPO8jDchg6I/DAwKQHmwfhmNL
	hE0A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=DgA5T2is1qpav02sbXNkX3vhuzAWjEZjsnNJggJC05k=;
	b=Oig92c6GOc+q9Shkyysjjg262/Ff17u4y0FRr7niStHlSIzVVpDCCL56fVq22B/s2a
	KS7tdnhrPTZzzU2EBZnXl/HXS4YgHi/d0J9FeRztoBxbpe/Ghi8fvakLJyKS/zaiHkFj
	ypLv2VA8GD/tttupdLV4TxHq7GQOXdJLXNmZPzWkfkGKs/LUANdDIp7VJcsVKT+ivTlO
	PEsfYrWNOi5+ammHzRBCtfV5UH65wxVDGj/4xJMpBKo+ck6NQWmbJUvRlbgmBfdfMCsY
	WV4d48TmaBKFiWGuikfC1dNSVoywuZgBg9eyw5TZ/8E42YdCkoCkMBYVoA4mhgxVS9P7
	YWPg==
X-Gm-Message-State: AKS2vOxDLYmCeL2tIZPbjC22OQ8ctkvN253blG8QiOREJUXncQxtnblL
	8euHnmgRZwFDvVVt7ut1I7IfiGZ71g==
X-Received: by 10.55.22.71 with SMTP id g68mr8457149qkh.218.1497550788102;
	Thu, 15 Jun 2017 11:19:48 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Thu, 15 Jun 2017 11:19:27 -0700 (PDT)
In-Reply-To: <VI1PR0502MB3086D84D5E14BBCB79D68E3882C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
References: <VI1PR0502MB3086D84D5E14BBCB79D68E3882C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Thu, 15 Jun 2017 13:19:27 -0500
Message-ID: <CAOSMAutTsb-wC+ogeWbvnnS9Mq3zciFdAvutpL7BuuXLeD_hkw@mail.gmail.com>
Subject: Re: cygheap base mismatch detected
To: Jon Morris <Jon.Morris@jbarisk.com>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 18:19:52 -0000

On Thu, Jun 15, 2017 at 11:30 AM, Jon Morris <Jon.Morris@jbarisk.com> wrote:
> Hi,
>
> Just tried to submit a bug, but bashbug command failed, so here is the problem text.
>
> Thanks,
>
> Jon

Please report this to the Cygwin folks. This is not a bash issue.


From MAILER-DAEMON Thu Jun 15 14:22:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLZPG-00040w-Vf
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 14:22:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43682)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZPF-00040p-Pg
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:22:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZPF-0000xt-5A
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:22:09 -0400
Received: from mail-qt0-x22f.google.com ([2607:f8b0:400d:c0d::22f]:35907)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLZPF-0000xl-12
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:22:09 -0400
Received: by mail-qt0-x22f.google.com with SMTP id u19so31374404qta.3
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 11:22:08 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=SmFODMvOwuVZwl6RhQS987F8nHJYJIOpjXOaLF4TZBk=;
	b=LIwlC1JziP7xXtiL8d8+154G1k1eQPpaQi9HFSAK8CFqI3/1rzW1H6WyOaj9NsUEkT
	fvQJshbms4lrZdC9CedQbF22pi+SchgHkh/cpOysHE+R80PfpnF2ec9Rd8J+E8bdiwEG
	Fb8BGFBMsAgKMlVwOQGXqz1pM4ni/W9sjAWRZh7hliMgop52Bo27r8H3HtTIqTHq2Hof
	1l+tqQr+O7adr1q03F4J6gKM/Npx+xLcMuNlRWsghCa7KFxjHstYoN5vPLQ8P7hXbEN/
	IK++9fBnm6kSzue1kGvFcC1rAYbhMZLuGEKbeZpmhMH8oPPigP5HDyix7YkUmOncadrP
	OVVA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=SmFODMvOwuVZwl6RhQS987F8nHJYJIOpjXOaLF4TZBk=;
	b=bSMsYMg7o8qvlpuaDMt50k4ezIkpW7Fr4niTitn8rNjTSIaNVuLfVflpLAimAiBsGR
	BLbbGwCn7SKdCpITxeLYKeAjz2f83mVKRzvqVU29rd660eAD39WnHvRSKMm6IzZ/y6kq
	LY3sbN7ZVnW1+CaBUhr2G6CVJiaYHBt0btegSYQCu/bcxmbiXo8N16GMOielIG7Zb0xi
	iW4nxTJG2So/4Ye4HWfqkdabloF2uKlI+UzWf4a9+Eu6YRH1sW1tmRi9nHNx5Of0eqaX
	fQ7A6jmiK5+PpfjhjE3hwGlC3FqOCA0PgW+z7f0SC9Djmkaqp8KOtXMujD9s0aaV/yBf
	JJLw==
X-Gm-Message-State: AKS2vOwX5EK7Nk5hSLYQNXzZxQx+4QeGTMU9OgOekM+Fn+vpTbGViw8M
	ODOuWgIyGYBq2bnu2ID2Nc9TF7YgBA==
X-Received: by 10.237.50.71 with SMTP id y65mr8128050qtd.117.1497550928501;
	Thu, 15 Jun 2017 11:22:08 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Thu, 15 Jun 2017 11:21:48 -0700 (PDT)
In-Reply-To: <CAOSMAutTsb-wC+ogeWbvnnS9Mq3zciFdAvutpL7BuuXLeD_hkw@mail.gmail.com>
References: <VI1PR0502MB3086D84D5E14BBCB79D68E3882C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
	<CAOSMAutTsb-wC+ogeWbvnnS9Mq3zciFdAvutpL7BuuXLeD_hkw@mail.gmail.com>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Thu, 15 Jun 2017 13:21:48 -0500
Message-ID: <CAOSMAuvuU5jTAw6uAt6JLXXg3-MMM_vMagrESW0Wj4-AvbLYXg@mail.gmail.com>
Subject: Re: cygheap base mismatch detected
To: Jon Morris <Jon.Morris@jbarisk.com>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 18:22:10 -0000

On Thu, Jun 15, 2017 at 1:19 PM, Eduardo Bustamante <dualbus@gmail.com> wrote:
[..]
> Please report this to the Cygwin folks. This is not a bash issue.

Err, not the Cygwin folks. You seem to be using Cmder, so ask them.


From MAILER-DAEMON Thu Jun 15 14:24:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLZRe-0005DE-MN
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 14:24:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44418)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZRc-0005D7-Pp
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:24:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLZRc-0002Bb-2P
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:24:36 -0400
Received: from mail-qt0-x22c.google.com ([2607:f8b0:400d:c0d::22c]:36538)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLZRb-0002BS-T7
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:24:35 -0400
Received: by mail-qt0-x22c.google.com with SMTP id u19so31465959qta.3
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 11:24:35 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=FHoubfOfLnYBZNFoLv0hW5IxSfupXVAsEsMZM6udP9Y=;
	b=ulh+r+B6u9x2Lv40ciTGIRh3SwEsL4Ft/pBXItsyWHmPQUR7wOELirgGix7GIa4ldP
	RODItlBBK3V2vm7Y05jZyBmQAgm8z4Epvq6H1hqcNUh1P/qgNoRRbYP2Krgy3YbImDCj
	GKP9/zbEOuGlTm8bc+NK+c+AIo49Q+TrY4Ran7nZ1Hm/0HohIeLcW+6Oqp48Uxldst7h
	sZpml5W2aaYNbscJo9dQ4vRsiWM2AJV+fZjAf0w+o/TyskcxEXWeIbf8ZGHTUo7B9/z4
	/cUdTpluQDy6eDY3QdhMnyQ5qKlYucM6OE5t4+VXa4RyfB5TMHn100kGGyIcgWbW9JJX
	erww==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=FHoubfOfLnYBZNFoLv0hW5IxSfupXVAsEsMZM6udP9Y=;
	b=SWx0M914gOPLpWHbrQ4HiT7PiBSIZJwVTcl2PrQKWGF2wJV5AfPnMhGvvN6Aj4iScl
	uG6K4TKmnIaX/QrmJXHKYeR+BsDSbwQCgMLtNHOLnrrRNLKem6HDBhMzmTcR6/rqmnNJ
	lmUpJQboTfr5o+N2y9lxMTbvJU0+sErMNuXvO0R/80coUJNnJhDBk72lhfvuABlin4Si
	twjrzeUteDssFyrTMxm2cGzs0q/hmCE1IMlHirNEvo4IY4tOHNEny7NK3bIRbjZqeITA
	ENlmA1K7icnQmacgEs6+LMwOixmxdWPJHP92SrYq0wWSfYpSb6L+ZqLPujXMdzY9IVxX
	qEvg==
X-Gm-Message-State: AKS2vOxuEg5nvRWzvuOO2HSCIwRzt0/LbJ+5yv5UTn6vbU1uEZPFRo+0
	cqOBkYvSYEHL3tImcDHPO7uzvgxJMw==
X-Received: by 10.55.91.70 with SMTP id p67mr8213663qkb.237.1497551075328;
	Thu, 15 Jun 2017 11:24:35 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Thu, 15 Jun 2017 11:24:15 -0700 (PDT)
In-Reply-To: <E1dLWoe-0000mG-Aq@shell.xmission.com>
References: <E1dLWoe-0000mG-Aq@shell.xmission.com>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Thu, 15 Jun 2017 13:24:15 -0500
Message-ID: <CAOSMAuu2nhJkri=-qrRkXsZHfwqQLgF+fDvf8KKJKzc=FfpGWg@mail.gmail.com>
Subject: Re: Why does 'connect' take so long (sometimes) and can't be
	interrupted?
To: gazelle@xmission.com
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::22c
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 18:24:37 -0000

On Thu, Jun 15, 2017 at 10:36 AM,  <gazelle@xmission.com> wrote:
[...]
> Description:
>         This is a little complicated and I can't give you full details on how to
>         replicate it, since I don't fully understand it myself.  But under certain
>         circumstances, the following line takes a very long time to execute:
>
>             exec 5<>/dev/tcp/localhost/12345

Attach to the hanged process with gdb, print a backtrace and reply
back, so that we can see where it's stuck.


From MAILER-DAEMON Thu Jun 15 14:25:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLZSU-0005Tx-T0
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 14:25:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44596)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLZST-0005Tq-02
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:25:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLZSO-0002Qu-1B
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:25:28 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:36920
	helo=homiemail-a124.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dLZSN-0002Qc-LD
	for bug-bash@gnu.org; Thu, 15 Jun 2017 14:25:23 -0400
Received: from homiemail-a124.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a124.g.dreamhost.com (Postfix) with ESMTP id 8729760000D01;
	Thu, 15 Jun 2017 11:25:17 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=uGkV0K15eZVca19doUue8m+aj7w=; b=
	Ovu4pjT1ZYbHhDY5XgeH4Fs1gR7WwfxewvDEGDl8SKZ0Rt5r4ldJDEUBDBY8gSUb
	jLg6AetAI+fzcufwHkrBl0P9+F3P0/fWrw5k1/rVUIYLl0bb69u8HTJ2WcAAuJpq
	7vZxSAmO20J+uUuGaMAXn70LsBVhqdA/6X6XSxo63ks=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a124.g.dreamhost.com (Postfix) with ESMTPSA id
	7BBD160000D00; Thu, 15 Jun 2017 11:25:17 -0700 (PDT)
Message-Id: <8be06a1c8b5da858b4af640774a337f4e787191d@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: gazelle@xmission.com,
 bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <E1dLWoe-0000mG-Aq@shell.xmission.com>
Subject: Re: Why does 'connect' take so long (sometimes) and can't be
	interrupted?
Date: Thu, 15 Jun 2017 14:25:17 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 18:25:30 -0000

=0AI can't think of what could cause this problem. The TCP connection=0A=
code in Bash seems pretty straightforward, and in my experiments I was=
=0Aable to interrupt it even if it was waiting for the server to accept=
 a=0Aconnection, or waiting for an available slot in the listen queue. I=
t's=0Apossible the problem is in your C code. Would you be able to post=
 a=0Aversion of it that exhibits the problem?=0A=0A----- Original Messag=
e -----=0AFrom: gazelle@xmission.com=0ATo:<bug-bash@gnu.org>=0ACc:=0ASen=
t:Thu, 15 Jun 2017 09:36:12 -0600=0ASubject:Why does 'connect' take so l=
ong (sometimes) and can't be=0Ainterrupted?=0A=0ADescription:=0A This is=
 a little complicated and I can't give you full details on how=0Ato=0A r=
eplicate it, since I don't fully understand it myself. But under=0Acerta=
in=0A circumstances, the following line takes a very long time to execut=
e:=0A=0A exec 5<>/dev/tcp/localhost/12345=0A=0A My objections are twofol=
d:=0A a) That it takes so long - it should either succeed or file (almos=
t)=0A immediately.=0A b) When it is running, it is uninterruptable. None=
 of ^C, ^, or ^Z,=0Anor=0A any signal sent to the bash process (other th=
an SIGKILL) will cause=0A it to exit. Effectively, the only escape is to=
 SIGKILL the bash=0A process, which causes the entire shell to be killed=
.=0A=0A

From MAILER-DAEMON Thu Jun 15 15:04:34 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLa4H-0001gP-V9
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 15:04:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58564)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLa4F-0001f8-L7
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:04:33 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLa4C-0005Zy-Ea
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:04:31 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:34964
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dLa4C-0005Yo-1e
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:04:28 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5FJ4Jgc005684; Thu, 15 Jun 2017 12:04:21 -0700
Message-ID: <5942DA33.3030702@tlinx.org>
Date: Thu, 15 Jun 2017 12:04:19 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: char-class rules & please show examples of int. locales that
	use diff. char-class rules
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
In-Reply-To: <24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 19:04:33 -0000



Chet Ramey wrote:
> On 6/14/17 5:52 PM, L A Walsh wrote:
>
>   
>> Chet Ramey wrote: 
>>> But people don't work in Unicode. They work in their own locale.   
>> ----
>>    Ok, I have my locale set to latin9 (iso8859-15).
>> Attached is a pic ... 
>
> I am less concerned with how glyphs display in a console than how they
> are interpreted as alphanumerics given the C library interfaces that
> determine those character classes.  

-----

    In Unicode, how those characters are classified is _documented_.
(A Categorization of Unicode Characters <http://unicode.org/notes/tn36/>,
The Unicode Character Property Model <http://unicode.org/reports/tr23/> ). 

Two problems with locale-based rules are:

   1) they differ based on local convention, potentially,
even down to what "side of the street" you live on, and

   2) they don't account or allow for "data" (textual) outside
of a given locale.  For companies connected by an internet with
international customers, having a non-uniform standard is a
serious problem at best, and unworkable in practice.

    When Unicode first started becoming available in locales, many
people found themselves uncomfortably shoehorned into a locale that
wasn't their own.  I'd been using 'C' local for most things, but
with a CTYPE of UTF-8.  POSIX declared that C.UTF-8 wasn't a
valid locale (even though that's what many people wanted, and had
been using).  Next came en_US.iso8859-1 with some crap 8-bit
encoding that disallowed nearly all imported word and concept use.
While typical of POSIX, it was deemed unworkable and replaced with
en_US.UTF-8, in the next release.  en_US.UTF-8 is now the default
on all major linux distros. 
> Users expect alphanumerics in their own locale to be allowable as
> alphanumerics, and characters that are not to not be allowable as
> alphanumerics, and they expect that to be consistent across programs
> running on the same system using the same locale. That's the basis to use
> for determining whether or not a character is a valid part of a shell
> identifier.
>   
They are.  For a in-depth of the subtleties of property names
see the perlunicode(https://perldoc.perl.org/perlunicode.html) and
perlrecharclass (https://perldoc.perl.org/perlrecharclass.html).

The latter shows differences between classes that only
match ASCII or POSIX range chars vs. properties that match all
letters or numeric digits.

> A character that is classified as an alphanumeric in a particular locale,
> but not in another, can lead to portability problems. That's what we're
> debating here, not how something gets displayed in a text editor.
>   
That's already a problem in that I try to use a letter from
the Greek alphabet, in a var name, and it doesn't work.  The
current code doesn't recognize letters outside some limited
POSIX-defined range.  That's very constraining. 


>> How is having UTF-8 for files and text not showing
>> respect?  
> Look at the the issue with different locales classifying
> characters as alphanumerics differently, and how that would impact
> variable names incorporating locale-specific characters in `portable'
> scripts.
>   
---
    Can you give an example?  AFAIK, most locals that allow
international letters are already using the unicode definitions.  I
don't know of any locale that supports internationalized characters
that don't use the unicode rules.

    Do you have an example of different internationalized locales
that use different character-class rules, cuz I don't know of any.

Linda




From MAILER-DAEMON Thu Jun 15 15:33:42 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLaWU-0003Ey-HB
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 15:33:42 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41577)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLaWR-0003AV-Gq
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:33:41 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dLaWN-00058i-F6
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:33:39 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:60947
	helo=homiemail-a121.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dLaWN-000588-42
	for bug-bash@gnu.org; Thu, 15 Jun 2017 15:33:35 -0400
Received: from homiemail-a121.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a121.g.dreamhost.com (Postfix) with ESMTP id 896F760001100
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 12:33:33 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=o8rPyKm4boakdYhfDACn6+9x2YY=; b=
	Anwt8I5LZNCcG35WXfxt7CJHJ3T2sRTK2oVFevVRPw3tqu8GZ0GOYLkb8CzeF10S
	V48dRncXxoiXl5OPK7SPgwNwt0ix5tWq18oVU+BYNuFbGlqx5bmWWfI04QYlmYFR
	ssOgJsMAGEqHZYraaaj/tfRnAirXjO4hXa8FkiXwrkA=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a121.g.dreamhost.com (Postfix) with ESMTPSA id
	813BC60001A09
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 12:33:33 -0700 (PDT)
Message-Id: <260f639aaa4d057caf9f0337049df47014adfa49@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <E1dLWoe-0000mG-Aq@shell.xmission.com>
Subject: RFE: File Descriptor passing and socket pair creation
Date: Thu, 15 Jun 2017 15:33:33 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 19:33:41 -0000

=0ASince the subject's come up - difficulties with /dev/tcp, no timeout=
=0Afeature, somehow a failure to interrupt it, etc.=C2=A0 I want to sugg=
est=0Aan alternative.=C2=A0 I don't propose removing /dev/tcp from Bash=
 (since=0Ait's been there quite a long time, people use it and I'm sure=
 many=0Apeople like it), but I propose an alternative approach for provi=
ding=0Asimilar functionality in the future:=0A=0AIn Unix, there are what=
's known as "local" and "Unix Domain" sockets.=0AA nice feature of these=
 is the ability to pass open files between=0Aprocesses. Integrating that=
 functionality into the shell opens up a=0Alot of possibilities for inte=
grating other things into the shell=0Awithout having to write them as sh=
ell "builtin" libraries.=0ASpecifically, if you provide "socketpair" and=
 "recvmsg" as=0Ashell-built-ins, then processes for opening files and fi=
le-like=0Adevices can be implemented as external executables.=0A=0AI wro=
te an interface to socketpair(), sendmsg(), and recvmsg() as=0Ashell bui=
ltins (for Bash and ksh) as part of a library I'm working on=0Acalled "s=
hell-pepper". The library is like a platform for delivering=0Afunctional=
ity I want to see in the shell, but don't expect to be=0Aaccepted by the=
 upstream maintainers. :) With it you could write an=0Aexternal program=
 to handle the task of opening that TCP connection,=0Aand send the file=
 table entry for the connection over a local socket -=0Athen the connect=
ion process COULD run in the background, kind of like=0Athis:=0A=0A$ ena=
ble -f ./socketpair socketpair=0A$ enable -f ./recvmsg recvmsg=0A$ socke=
tpair s=C2=A0=C2=A0 # Create a socketpair, store the FDs in $s=0A$ tcp_c=
onnect localhost 12345 >&${s[1]}=C2=A0 &=C2=A0=C2=A0=C2=A0 # Run a progr=
am to=0Acreate a TCP connection=0A$ exec {s[1]}<&-=C2=A0=C2=A0=C2=A0 # C=
lose the socket we sent to tcp_connect, so=0Awe can tell when tcp_connec=
t is done with it=0A$ recvmsg msg tcp_fd <&${s[0]}=C2=A0=C2=A0 # Get a r=
esponse message, including=0Afile descriptors, from tcp_connect=0A$ exec=
 {s[0]}<&-=C2=A0=C2=A0=C2=A0 # Alas, attempting to use this syntax on Ba=
sh=0A4.2 will kill your shell!=0A=0AOf course all the above is way more=
 code than simply=0A=0A$ exec {fd}<>/dev/tcp/localhost/12345=0A=0AAnd mo=
st notably, it doesn't allow you to localize the open file=0Adescriptor=
 the way a redirect does:=0A=0A$ { cmd1; cmd2; etc; } <>/dev/tcp/localho=
st/49152=0A$ # TCP connection was closed automatically when the commands=
 above=0Awere finished.=0A=0AThe upshot is that it gives you flexibility=
: If you want different=0Atypes of connections (named socket, etc.), or=
 different connection=0Aoptions (datagram, timeout, etc.), or authentica=
tion as part of=0Acreating the connection, it can be implemented as part=
 of the=0Aexecutable. Then the whole ugly process of creating the socket=
pair,=0Arunning the command, receiving the message, etc. could be wrappe=
d in a=0Ashell function. =0A=0ABetter yet, look how this plays out in ks=
h:=0A=0A$ tcp_connect localhost 12345 | recvmsg msg tcp_fd=0A=0A...Becau=
se "pipes" in Korn Shell are actually socket pairs, (and=0Abecause it ha=
s the equivalent of shopt "lastpipe" on by default) you=0Acan receive fi=
le descriptors from external commands without having to=0Aexplicitly cre=
ate and destroy a socketpair. (Though the use of sockets=0Ain ksh has ne=
gative side-effects as well - for instance opening files=0Ain /dev/fd on=
 Linux works for pipes, but not for sockets. Maybe some=0Aalternative co=
uld be considered that lends comparable convenience?)=0A=0AI realize "so=
cketpair()" and FD passing are not universally supported=0Aover all the=
 platforms supported by Bash...=C2=A0 The feature goes back=0APOSIX-2001=
, so it should be pretty broadly supported at least.=0A=0A----- Original=
 Message -----=0AFrom: gazelle@xmission.com=0ATo:<bug-bash@gnu.org>=0ACc=
:=0ASent:Thu, 15 Jun 2017 09:36:12 -0600=0ASubject:Why does 'connect' ta=
ke so long (sometimes) and can't be=0Ainterrupted?=0A=0A Description:=0A=
 This is a little complicated and I can't give you full details on how=
=0Ato=0A replicate it, since I don't fully understand it myself. But und=
er=0Acertain=0A circumstances, the following line takes a very long time=
 to execute:=0A=0A exec 5<>/dev/tcp/localhost/12345=0A

From MAILER-DAEMON Thu Jun 15 16:11:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLb6z-000783-FQ
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 16:11:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57102)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLb6w-00077v-Ob
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:11:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLb6t-0002SQ-Jo
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:11:22 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:14325
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLb6t-0002Rw-Ci
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:11:19 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMJ66051; Thu, 15 Jun 2017 16:11:13 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFZ50468 (AUTH cpr);
	Thu, 15 Jun 2017 16:11:12 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: PePa <peterkelly@passchier.net>, "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
	<3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
	<7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
Date: Thu, 15 Jun 2017 16:11:12 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.15.194516:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_EURO, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_2000_2999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 20:11:24 -0000

On 6/15/17 11:22 AM, PePa wrote:
> On 15/06/2560 22:03, Chet Ramey wrote:
>> I don't know other languages well enough to point one out, but I can easily
>> imagine that a particular character is an "alphabetic" in, say, Mandarin,
>> but doesn't exist in someone's en_US character set.
> 
> I though you were referring to a character existing in both sets> This is the reason why I think you should only concern yourself with
> characters that already have an established semantic in bash. Don't get
> bogged down in distinguishing classes in myriads of character sets. Just
> allow anything that isn't ASCII (but IS UTF-8 -- I'm talking about
> UTF-8, otherwise this discussion becomes impossible).

Seriously: not everyone uses a UTF-8 locale. Something that uses an
approach along the lines of Eduardo's patch won't have the UTF-8-only
problem.  If I undertake the effort to put this into bash, and commit to
supporting it forever (which is how these things go), I'm not going to
orphan non-UTF-8 users.

And no matter which way we go here, I can't see any advantage in
allowing invalid multibyte sequences in identifier names.

The proposal to, essentially, use isw* functions instead of is* ctype
functions to determine whether a (now wide) character is a valid
identifier character is a straightforward enhancement. You have to look
at every character anyway no matter what.

> 
>> I see a number of problems with using non-alphanumerics in shell
>> identifiers.  The real advantage to allowing this is to allow users to
>> put alphabetics from their own locales into shell identifiers.  There's
>> little reason to do it otherwise, and plenty of complications.
> 
> What are those problems and complications??

Mostly portability across character sets and maintainability concerns
(which, admittedly, are nobody's problems but mine).


>> As for the implementation, it's much easier to use isalpha/isdigit (and
>> their wide character equivalents) than to try and keep track of a blacklist
>> of characters across different locales.
> 
> I don't propose blacklists across locales, just blacklisting what
> already has an established meaning in bash, ie. ASCII. All the rest is
> just fair game, if someone insists on using a thumbs-up icon in a
> variable name, why restrict that?? The restricting and policing is going
> to make this costly in terms of developer time and CPU time.

You still have to look at every character. The world isn't all UTF-8:
there are character sets where multibyte characters include characters
that are valid ascii (including, I suspect, `=').

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 15 16:18:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLbE5-0000pK-Bi
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 16:18:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59674)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLbE2-0000pD-TU
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:18:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLbDz-00077K-On
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:18:42 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:53645
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLbDz-00076p-Iu
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:18:39 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANJ68759; Thu, 15 Jun 2017 16:18:36 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFQ74254 (AUTH cpr);
	Thu, 15 Jun 2017 16:18:35 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: char-class rules & please show examples of int. locales that use
	diff. char-class rules
To: L A Walsh <bash@tlinx.org>, bug-bash <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<5942DA33.3030702@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <12fe7ec6-b4f0-0284-9dd0-66dae8dfe253@case.edu>
Date: Thu, 15 Jun 2017 16:18:35 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5942DA33.3030702@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.15.190016:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__INT_PROD_LOC, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_2000_2999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 20:18:44 -0000

On 6/15/17 3:04 PM, L A Walsh wrote:

> Two problems with locale-based rules are:
> 
>    1) they differ based on local convention, potentially,
> even down to what "side of the street" you live on, and

That's precisely what makes them valuable to users.

>    2) they don't account or allow for "data" (textual) outside
> of a given locale.  For companies connected by an internet with
> international customers, having a non-uniform standard is a
> serious problem at best, and unworkable in practice.

We're not talking about `data' here. We're talking about characters that
can appear in shell identifier names. Don't try to muddy the issue.


>> A character that is classified as an alphanumeric in a particular locale,
>> but not in another, can lead to portability problems. That's what we're
>> debating here, not how something gets displayed in a text editor.
>>   
> That's already a problem in that I try to use a letter from
> the Greek alphabet, in a var name, and it doesn't work.  The
> current code doesn't recognize letters outside some limited
> POSIX-defined range.  That's very constraining. 

Please. The entire scope of this discussion is how to lift that
constraint.

> 
> 
>>> How is having UTF-8 for files and text not showing
>>> respect?  
>> Look at the the issue with different locales classifying
>> characters as alphanumerics differently, and how that would impact
>> variable names incorporating locale-specific characters in `portable'
>> scripts.
>>   
> ---
>     Can you give an example?  AFAIK, most locals that allow
> international letters are already using the unicode definitions.  I
> don't know of any locale that supports internationalized characters
> that don't use the unicode rules.
> 
>     Do you have an example of different internationalized locales
> that use different character-class rules, cuz I don't know of any.

I said I didn't, since I'm not multi-lingual, but could imagine a scenario
where an "alphabetic" in, say, cyrillic is not an alphabetic in en_US.
That's a portability problem.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 15 16:50:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLbiy-0000gv-W7
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 16:50:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43762)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLbix-0000gp-6r
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:50:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLbit-0007fZ-V4
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:50:39 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:39390
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dLbit-0007et-Jt
	for bug-bash@gnu.org; Thu, 15 Jun 2017 16:50:35 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5FKoRxc014824; Thu, 15 Jun 2017 13:50:29 -0700
Message-ID: <5942F313.8090403@tlinx.org>
Date: Thu, 15 Jun 2017 13:50:27 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: PePa <peterkelly@passchier.net>, "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
References: <5930B488.7020605@tlinx.org>	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>	<5930EA1C.5090100@tlinx.org>
	<20170602121541.GP7764@eeg.ccf.org>	<5941B02B.7000801@tlinx.org>	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>	<3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>	<7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
	<82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
In-Reply-To: <82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 20:50:40 -0000

Chet Ramey wrote:
> On 6/15/17 11:22 AM, PePa wrote:
>   
>> On 15/06/2560 22:03, Chet Ramey wrote:
>>     
>>> I don't know other languages well enough to point one out, but 
>>> I can easily imagine that a particular character is an 
>>> "alphabetic" in, say, Mandarin, but doesn't exist in someone's 
>>> en_US character set.
>>>       
---
    Not if they are both Unicode encoded.  That's the point.  If they are
using an incompatible encoding like Shift-JIS or Big5, they already have
problems running today's scripts (they overwrite the ASCII range), but
computer HW & SW makers have moved away from those encodings to only
support UTF-8, with UTF-8 being the default (for pages with no explicit
encoding) in HTML5.
>
> Seriously: not everyone uses a UTF-8 locale. Something that uses an
> approach along the lines of Eduardo's patch won't have the UTF-8-only
> problem.  If I undertake the effort to put this into bash, and commit to
> supporting it forever (which is how these things go), I'm not going to
> orphan non-UTF-8 users.
>   
Then you are saying something along the lines of Eduardo's patch is
"fine"?  I, currently, don't see an issue with that.

However, those locales that do not *currently* support UTF-8 (nor ASCII)
have always been orphaned.  They would be no worse off than before, and,
likely, eventually better -- as it is the plan that Unicode contain all
characters and symbols from all languages past and present.

To add UTF-8 support today only allows for more choice -- it doesn't
limit anyone running the scripts they currently run today.

The work to support UTF-8 allows for ASCII compatibility (meaning 
today's scripts will still work tomorrow).


From MAILER-DAEMON Thu Jun 15 17:05:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLbxb-000589-2p
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 17:05:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49603)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLbxZ-000582-9g
	for bug-bash@gnu.org; Thu, 15 Jun 2017 17:05:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dLbxU-0006El-5H
	for bug-bash@gnu.org; Thu, 15 Jun 2017 17:05:45 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:39986
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dLbxT-0006DZ-T3
	for bug-bash@gnu.org; Thu, 15 Jun 2017 17:05:40 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5FL5XnZ016068; Thu, 15 Jun 2017 14:05:36 -0700
Message-ID: <5942F69D.7000004@tlinx.org>
Date: Thu, 15 Jun 2017 14:05:33 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: char-class rules & please show examples of int. locales that
	use diff. char-class rules
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<5942DA33.3030702@tlinx.org>
	<12fe7ec6-b4f0-0284-9dd0-66dae8dfe253@case.edu>
In-Reply-To: <12fe7ec6-b4f0-0284-9dd0-66dae8dfe253@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 15 Jun 2017 21:05:46 -0000


Chet Ramey wrote:
> On 6/15/17 3:04 PM, L A Walsh wrote:
>   
>> Two problems with locale-based rules are:
>>    1) they differ based on local convention, potentially,
>> even down to what "side of the street" you live on, and
>>     
> That's precisely what makes them valuable to users.
>   
---
    But such differences also make them incompatible with other
locales including ASCII -- which would prohibit them running
most programs today.
>   
>>    2) they don't account or allow for "data" (textual) outside
>> of a given locale.  For companies connected by an internet with
>> international customers, having a non-uniform standard is a
>> serious problem at best, and unworkable in practice.
>>     
>
> We're not talking about `data' here. We're talking about characters that
> can appear in shell identifier names. Don't try to muddy the issue.
>   
----
    That wasn't trying to muddy the issue, but clarify it -- all text,
is ultimately a type of data.  How it is interpreted is key.  HTML
text partially solved it's encoding problem by having a default and
headers to specify codepages.  The same is true in the future, but the
default has changed from a western-encoding-default to UTF-8-default.

    At this point, I'm proposing Bash allow a similar scheme -- of
allowing UTF-8.  It can be ***some*** extension to add a codepage
definition to bash-scripts if there is a demand for it.  Given that
ASCII has sufficed for nearly 2 decades, adding support for all of the
world's languages via a compatible encoding doesn't seem to be
a onerous restriction.  Less than 50% of the locales can use the
current ASCII, while less than 4%  do not, _today_ support UTF-8.


>> That's already a problem in that I try to use a letter from
>> the Greek alphabet, in a var name, and it doesn't work.  The
>> current code doesn't recognize letters outside some limited
>> POSIX-defined range.  That's very constraining. 
>>     
>
> Please. The entire scope of this discussion is how to lift that
> constraint.
>   
   And I proposed allowing a method that would not invalidate
current ASCII scripts.  Methods to run scripts under a non-ASCII
locale where bash applies locale-specific meanings to characters won't
run today's scripts -- they would *create* incompatibility.

    If those wanting to support incompatible locales want such support,
I don't see a future extension to support specifying a locale to be
a problem.  But that support shouldn't stop moving ahead with UTF-8
compatibility, as UTF-8 compatiblity won't conflict with such
an extension (or at least it hasn't in-regard to webpages).



From MAILER-DAEMON Thu Jun 15 21:01:55 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLfe7-0004jM-LK
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 21:01:55 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58903)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLfe6-0004jE-0G
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:01:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <peterpasschier@gmail.com>) id 1dLfe2-0006FY-Va
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:01:54 -0400
Received: from mail-pg0-x230.google.com ([2607:f8b0:400e:c05::230]:33254)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <peterpasschier@gmail.com>)
	id 1dLfe2-0006FG-PR
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:01:50 -0400
Received: by mail-pg0-x230.google.com with SMTP id f185so13737298pgc.0
	for <bug-bash@gnu.org>; Thu, 15 Jun 2017 18:01:50 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=sender:subject:to:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-language:content-transfer-encoding;
	bh=iQqTrY0U5yHXztB04m5J8UHsD4d2pWFIsR+zEIueYSY=;
	b=RSbmu4ujjLCTC4gOgYzJ/eT77huPHOThYtrqwqbdH8x8uPX7yfbj9zWZF3KJSC4USH
	dRBiNQZzxLX/GPjtoXUjrWM9IAr03Zq0AgVU1jEVl/M6u27qiafSIgroDXOrxmtLbyPb
	P+ceK+Llat/tnEVqnFxcERDayp+DODPrTrJtSshvaWa88uhNF1HwKLPv1oUb3LpHZn7s
	l+ODgT+vYVdVrFfAdza76fQvhOE5VicvEJQEfRaa0ntO8jp1vFtxGgqcE2Mgs58zgoRQ
	903IMWMgdQJiEw5RnbjOwxurQYcpo1nipTr5kGPl9E6tlhqehOlQxWtpD8qQXhjn0xG2
	D03g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:sender:subject:to:references:from:message-id
	:date:user-agent:mime-version:in-reply-to:content-language
	:content-transfer-encoding;
	bh=iQqTrY0U5yHXztB04m5J8UHsD4d2pWFIsR+zEIueYSY=;
	b=ihheXzaxeiSVvzLYsgAtqeLhEuvA/h6wdI2ISBZVLuYZ3g3zZPkaWS1aCrxmfmpKlg
	JOTQDTQzap+YGQ03GNKgCC+8CyGLqI8sgCBv7/0/CGOJhSAlfWXhpmiXsE70knQskPdt
	pAqhXvu7F2lPlvv1wP2jhXDzSIBEG2OLsycqD2nNhLbW9lc/r90o8dxfaijwy6MH8pTh
	pMbqVmOk8DdYwo7BlF46k+DE6KgzXIGN89VDxc8h5FNxpSjNLWoxWdoWqAlWn8O/Kxne
	H319OkNYuxUPnVIKD7zF40T9ny4TgAFa8nybpPpnozSlB07b2Xf2+hxn/ohtJe+SVJob
	jeLA==
X-Gm-Message-State: AKS2vOzDtxbkk6Q0kXo14OD4qioU79TauqPUWhmxIXFLntHCeF82tmBR
	I6qbgfdbZeIJfAff
X-Received: by 10.98.3.132 with SMTP id 126mr8223169pfd.133.1497574909464;
	Thu, 15 Jun 2017 18:01:49 -0700 (PDT)
Received: from [192.168.4.100] ([49.49.61.201])
	by smtp.gmail.com with ESMTPSA id 84sm774563pfq.125.2017.06.15.18.01.44
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Thu, 15 Jun 2017 18:01:45 -0700 (PDT)
Sender: Peter Passchier <peterpasschier@gmail.com>
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
	<3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
	<7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
	<82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
From: Peter & Kelly Passchier <peterkelly@passchier.net>
Message-ID: <ddd061bd-b3b4-a0aa-ee99-f1b06b526c9e@passchier.net>
Date: Fri, 16 Jun 2017 08:01:42 +0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-GB
Content-Transfer-Encoding: 8bit
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c05::230
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 01:01:54 -0000

On 16/06/2560 03:11, Chet Ramey wrote:
> You still have to look at every character. The world isn't all UTF-8:
> there are character sets where multibyte characters include characters
> that are valid ascii (including, I suspect, `=').

I think supporting all kinds of other encodings besides UTF-8 is
absolutely nuts. You not only have to look at every character, but you
first have to decide which encoding you're going to be in, and this
might be ambiguous (unless an encoding declaration becomes part of bash).

I think the overhead in code size and complexity will be too much. I
never thought you were thinking in this direction. I hope other people
will chime in about this approach.

Peter


From MAILER-DAEMON Thu Jun 15 21:06:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLfib-0005tO-5y
	for mharc-bug-bash@gnu.org; Thu, 15 Jun 2017 21:06:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60585)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLfiZ-0005tH-Gh
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:06:32 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLfiU-0000nM-HZ
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:06:31 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:17789
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLfiU-0000lk-Bx
	for bug-bash@gnu.org; Thu, 15 Jun 2017 21:06:26 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANO80641; Thu, 15 Jun 2017 21:06:21 -0400 (EDT)
Received: from h157.176.142.40.ip.windstream.net (EHLO _192.168.254.2_)
	([40.142.176.157])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQH97163 (AUTH cpr);
	Thu, 15 Jun 2017 21:06:21 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: people working in Greg's locale (+euro) & display of Unicode names
To: Peter & Kelly Passchier <peterkelly@passchier.net>,
	"bug-bash@gnu.org" <bug-bash@gnu.org>
References: <5930B488.7020605@tlinx.org>
	<CAOSMAuv3DJb3Awj7ZQ-u+L6_pZZbYO0Dhd-Y84qm7gQDz_Ykkw@mail.gmail.com>
	<5930EA1C.5090100@tlinx.org> <20170602121541.GP7764@eeg.ccf.org>
	<5941B02B.7000801@tlinx.org>
	<24a05fb6-0534-bff4-c301-42800a45bb9b@case.edu>
	<795c5046-0491-5f4c-2138-5922a8a57e44@passchier.net>
	<3430e03a-ae95-7599-11c0-184f5a9b80bc@case.edu>
	<7a6c1d7b-6c3b-12e9-4aac-52fa6626c782@passchier.net>
	<82caa0fe-1a7c-cac8-9557-bfd3e3c9dfe3@case.edu>
	<ddd061bd-b3b4-a0aa-ee99-f1b06b526c9e@passchier.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <a00613e8-092e-0176-55bc-e841ec01da66@case.edu>
Date: Thu, 15 Jun 2017 21:06:19 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <ddd061bd-b3b4-a0aa-ee99-f1b06b526c9e@passchier.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.917:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_EURO, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_900_999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 01:06:32 -0000

On 6/15/17 9:01 PM, Peter & Kelly Passchier wrote:
> On 16/06/2560 03:11, Chet Ramey wrote:
>> You still have to look at every character. The world isn't all UTF-8:
>> there are character sets where multibyte characters include characters
>> that are valid ascii (including, I suspect, `=').
> 
> I think supporting all kinds of other encodings besides UTF-8 is
> absolutely nuts. You not only have to look at every character, but you
> first have to decide which encoding you're going to be in, and this
> might be ambiguous (unless an encoding declaration becomes part of bash).

There's already an encoding declaration in bash: setting the locale using
the usual set of environment variables.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 16 05:34:20 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLne0-0003Fz-J3
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 05:34:20 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54227)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <Jon.Morris@jbarisk.com>) id 1dLndw-0003FF-Fi
	for bug-bash@gnu.org; Fri, 16 Jun 2017 05:34:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <Jon.Morris@jbarisk.com>) id 1dLndt-00067K-Az
	for bug-bash@gnu.org; Fri, 16 Jun 2017 05:34:16 -0400
Received: from mail-he1eur01on0089.outbound.protection.outlook.com
	([104.47.0.89]:20832
	helo=EUR01-HE1-obe.outbound.protection.outlook.com)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <Jon.Morris@jbarisk.com>)
	id 1dLnds-00065I-Q0
	for bug-bash@gnu.org; Fri, 16 Jun 2017 05:34:13 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jbarisk.com;
	s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; 
	bh=EsJ4rJqOE85AjVs0PnZUK1s8dZUCiztKB5yS0rw48xU=;
	b=fVclkSnfM+KBir6Vgb2XQmUJCIJnyhFrY0WqkQd/B8dDeoqrUuIb+fDyhjBV9mmoRFYlz7Bu+gS5yD3Nb4Xs1C1bp9eNhto3uYPTyQNiVk3ERjeVQ3tnmSYPm2wibA+qo1v+BLLdiAS2gEZJliji4Fdy7pnMTQjHx+7dcTpy3VI=
Received: from VI1PR0502MB3086.eurprd05.prod.outlook.com (10.175.20.12) by
	VI1PR0502MB3088.eurprd05.prod.outlook.com (10.175.20.14) with Microsoft
	SMTP Server (version=TLS1_2,
	cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id
	15.1.1178.14; Fri, 16 Jun 2017 09:34:09 +0000
Received: from VI1PR0502MB3086.eurprd05.prod.outlook.com
	([fe80::c823:72c6:442:7c7c]) by
	VI1PR0502MB3086.eurprd05.prod.outlook.com
	([fe80::c823:72c6:442:7c7c%14]) with mapi id 15.01.1178.018;
	Fri, 16 Jun 2017 09:34:09 +0000
From: Jon Morris <Jon.Morris@jbarisk.com>
To: Eduardo Bustamante <dualbus@gmail.com>
CC: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: RE: cygheap base mismatch detected
Thread-Topic: cygheap base mismatch detected
Thread-Index: AdLl9FW4fYUV8k0UTqO3y2pQLozfsAAD5aGAAAAVAwAAH9FTIA==
Date: Fri, 16 Jun 2017 09:34:09 +0000
Message-ID: <VI1PR0502MB30869A7C7DA491F31275F73582C10@VI1PR0502MB3086.eurprd05.prod.outlook.com>
References: <VI1PR0502MB3086D84D5E14BBCB79D68E3882C00@VI1PR0502MB3086.eurprd05.prod.outlook.com>
	<CAOSMAutTsb-wC+ogeWbvnnS9Mq3zciFdAvutpL7BuuXLeD_hkw@mail.gmail.com>
	<CAOSMAuvuU5jTAw6uAt6JLXXg3-MMM_vMagrESW0Wj4-AvbLYXg@mail.gmail.com>
In-Reply-To: <CAOSMAuvuU5jTAw6uAt6JLXXg3-MMM_vMagrESW0Wj4-AvbLYXg@mail.gmail.com>
Accept-Language: en-GB, en-US
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
authentication-results: gmail.com; dkim=none (message not signed)
	header.d=none; gmail.com; dmarc=none action=none header.from=jbarisk.com;
x-originating-ip: [212.250.89.36]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; VI1PR0502MB3088;
	20:NFO+8bMYJVmrXR7g62nKT660nJLhMxfmv9HOk/wbR7bPV5aAv8B8FCEIQE6TbhU2TCJYZ1BAlSafDdyT7KvpzMOnVc8sd1u5O3jbnhYYnNwuLplTVMGOHmm4weR/M4ypf1JEuBEuc7NeoW8eDohqWvqbbKlQRonoouUVTZDbml0=
x-ms-office365-filtering-correlation-id: aa42ab0f-44e9-4072-a7e8-08d4b49ad739
x-microsoft-antispam: UriScan:; BCL:0; PCL:0;
	RULEID:(22001)(2017030254075)(201703131423075)(201703031133081)(201702281549075);
	SRVR:VI1PR0502MB3088; 
x-ms-traffictypediagnostic: VI1PR0502MB3088:
x-microsoft-antispam-prvs: <VI1PR0502MB3088632FF7BB87CE31AFD07082C10@VI1PR0502MB3088.eurprd05.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(148322886591682)(22074186197030)(31418570063057)(116415991822766)(128460861657000)(81160342030619);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0;
	RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(10201501046)(100000703101)(100105400095)(93006095)(93001095)(3002001)(6041248)(20161123558100)(20161123560025)(20161123564025)(20161123562025)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);
	SRVR:VI1PR0502MB3088; BCL:0; PCL:0;
	RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);
	SRVR:VI1PR0502MB3088; 
x-forefront-prvs: 0340850FCD
x-forefront-antispam-report: SFV:NSPM;
	SFS:(10009020)(6009001)(39400400002)(39410400002)(39830400002)(39450400003)(377454003)(24454002)(13464003)(15974865002)(14454004)(53936002)(53546009)(45080400002)(305945005)(33656002)(5660300001)(4326008)(72206003)(2900100001)(74316002)(478600001)(68736007)(7696004)(54356999)(39060400002)(76176999)(50986999)(25786009)(38730400002)(53376002)(229853002)(110136004)(6246003)(6116002)(3846002)(102836003)(6306002)(9686003)(6506006)(6916009)(55016002)(2950100002)(99286003)(3660700001)(189998001)(3280700002)(8676002)(81166006)(8936002)(66066001)(2906002)(5250100002)(86362001)(3480700004)(1411001)(7736002)(97736004)(6436002);
	DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR0502MB3088;
	H:VI1PR0502MB3086.eurprd05.prod.outlook.com; FPR:; SPF:None;
	MLV:ovrnspm; PTR:InfoNoRecords; LANG:en; 
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: jbarisk.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 16 Jun 2017 09:34:09.2113 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 3131e85c-e560-4bb3-a82f-8b339ad41833
X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0502MB3088
X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy]
X-Received-From: 104.47.0.89
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 09:34:17 -0000

Tm8gcHJvYmxlbS4gSSBkb24ndCBoYXZlIGN5Z3dpbiBpbnN0YWxsZWQgc28gdGhlIHByb2JsZW0g
aXMgc29tZXRoaW5nIGlzIGxvb2tpbmcgZm9yIGl0LiBJJ3ZlIHJlaW5zdGFsbGVkIGdpdCBmb3Ig
d2luZG93cyBzbyBpZiB0aGUgcHJvYmxlbSBkb2Vzbid0IGdvIGF3YXksIEknbGwgcmFpc2UgYSBk
ZWZlY3Qgd2l0aCBDbWRlci4NCg0KVGhhbmtzLA0KDQpKb24NCg0KLS0tLS1PcmlnaW5hbCBNZXNz
YWdlLS0tLS0NCkZyb206IEVkdWFyZG8gQnVzdGFtYW50ZSBbbWFpbHRvOmR1YWxidXNAZ21haWwu
Y29tXQ0KU2VudDogMTUgSnVuZSAyMDE3IDE5OjIyDQpUbzogSm9uIE1vcnJpcyA8Sm9uLk1vcnJp
c0BqYmFyaXNrLmNvbT4NCkNjOiBidWctYmFzaEBnbnUub3JnDQpTdWJqZWN0OiBSZTogY3lnaGVh
cCBiYXNlIG1pc21hdGNoIGRldGVjdGVkDQoNCk9uIFRodSwgSnVuIDE1LCAyMDE3IGF0IDE6MTkg
UE0sIEVkdWFyZG8gQnVzdGFtYW50ZSA8ZHVhbGJ1c0BnbWFpbC5jb20+IHdyb3RlOg0KWy4uXQ0K
PiBQbGVhc2UgcmVwb3J0IHRoaXMgdG8gdGhlIEN5Z3dpbiBmb2xrcy4gVGhpcyBpcyBub3QgYSBi
YXNoIGlzc3VlLg0KDQpFcnIsIG5vdCB0aGUgQ3lnd2luIGZvbGtzLiBZb3Ugc2VlbSB0byBiZSB1
c2luZyBDbWRlciwgc28gYXNrIHRoZW0uDQpGaW5kIG91dCBtb3JlIGFib3V0IHVzIGhlcmU6IHd3
dy5qYmFyaXNrLmNvbTxodHRwOi8vd3d3LmpiYXJpc2suY29tLz4gYW5kIGZvbGxvdyB1cyBvbiBU
d2l0dGVyIEBKQkFSaXNrPGh0dHA6Ly90d2l0dGVyLmNvbS9KQkFSaXNrPiBhbmQgTGlua2VkSW48
aHR0cHM6Ly93d3cubGlua2VkaW4uY29tL2NvbXBhbnkvMjM3MDg0Nz90cms9dHlhaCZ0cmtJbmZv
PWNsaWNrZWRWZXJ0aWNhbCUzQWNvbXBhbnklMkNjbGlja2VkRW50aXR5SWQlM0EyMzcwODQ3JTJD
aWR4JTNBMi0xLTIlMkN0YXJJZCUzQTE0NDc0MTQyNTk3ODYlMkN0YXMlM0FKQkElMjBSSVNLJTIw
TUFOQUdFTUVOVD4NCg0KVGhlIEpCQSBHcm91cCBzdXBwb3J0cyB0aGUgSkJBIFRydXN0Lg0KDQpB
bGwgSkJBIFJpc2sgTWFuYWdlbWVudCdzIGVtYWlsIG1lc3NhZ2VzIGNvbnRhaW4gY29uZmlkZW50
aWFsIGluZm9ybWF0aW9uIGFuZCBhcmUgaW50ZW5kZWQgb25seSBmb3IgdGhlIGluZGl2aWR1YWwo
cykgbmFtZWQuIElmIHlvdSBhcmUgbm90IHRoZSBuYW1lZCBhZGRyZXNzZWUgeW91IHNob3VsZCBu
b3QgZGlzc2VtaW5hdGUsIGRpc3RyaWJ1dGUgb3IgY29weSB0aGlzIGUtbWFpbC4NClBsZWFzZSBu
b3RpZnkgdGhlIHNlbmRlciBpbW1lZGlhdGVseSBieSBlbWFpbCBpZiB5b3UgaGF2ZSByZWNlaXZl
ZCB0aGlzIGVtYWlsIGJ5IG1pc3Rha2UgYW5kIGRlbGV0ZSB0aGlzIGVtYWlsIGZyb20geW91ciBz
eXN0ZW0uDQoNCg0KSkJBIFJpc2sgTWFuYWdlbWVudCBMaW1pdGVkIGlzIHJlZ2lzdGVyZWQgaW4g
RW5nbGFuZCwgY29tcGFueSBudW1iZXIgMDc3MzI5NDYsIFNvdXRoIEJhcm4sIEJyb3VnaHRvbiBI
YWxsLCBTa2lwdG9uLCBOb3J0aCBZb3Jrc2hpcmUsIEJEMjMgM0FFLCBUZWxlcGhvbmU6ICs0NDE3
NTY3OTk5MTkNCg0KDQo=


From MAILER-DAEMON Fri Jun 16 10:27:50 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLsE1-0004O8-Sx
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 10:27:49 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42834)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsDy-0004Mt-RU
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:27:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsDv-0001cN-Nk
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:27:46 -0400
Received: from mail-oi0-x243.google.com ([2607:f8b0:4003:c06::243]:34651)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLsDv-0001c0-J4
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:27:43 -0400
Received: by mail-oi0-x243.google.com with SMTP id w127so3705977oiw.1
	for <bug-bash@gnu.org>; Fri, 16 Jun 2017 07:27:43 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=ATc0rFmZLCUnH8PvjXZnP+w7bFPrexcL6QIUvy9Tp64=;
	b=fDCggPULKH3yfCLsCt691N6E7d+jpmnUiaFKBelohmGYlltJHWMnO68Jt2WI0+n9Si
	2shzR9NCBxkI79HVIcu+GivVW5743RJ8A9xwlS3+thuDQIIwXxaYmD70ed3yUm2YEbx4
	0dLyinGZzUuEWyTpFI/DiMtxVEGbIU+mXJNzZEjMRkBiGpJljhF07xeaLxLEEcGBqmtL
	BQyoZaEhysPH2FQ045mqoMYueP0OIzSIg9bsdDVK96GNcckVXQjgci/b8oDFvnniDB6Q
	Rt8yvnF0F+vhsCLpu50bIZ3dVF9s65QbGieEUpKxj63TI40o3FdFY0kBks0QKhXakgOJ
	oPVw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=ATc0rFmZLCUnH8PvjXZnP+w7bFPrexcL6QIUvy9Tp64=;
	b=Lyy+ioDAhKQs1MJuVt0VHpQbAHQuwaGg0I6EcyMe2shvOU7rDDS4EQbLkUQZVCkurT
	6AeHSm48QJgekMKS1PWAL+VWcbZAtMsXDIlCkm31MUTjZdfMCTSq6FNq0v78XVs05DbC
	3jg5a8w1Iuh9ZP2QrSLLRInt9xbvylq+9zN8gHZWMC5j/W+exlE8FXN0A/2urtfBpdSm
	NobAwhBAIoiM6hBrzujosP2E4kiQ6WEMEjhOEw6trL4//R8YFI1moyXYU9JU47aGemhv
	gHU7rT/f0KAknu6Cs+gA+98gXI9rPSHSXIjvk5r3pgzJPmRPWo5CkGABTLZGs8/5VZJW
	JtIA==
X-Gm-Message-State: AKS2vOxv5AAAmxHy0WiSM/627RHxcblQYxPZLsCDY1XtAdrfie9QRYCO
	2oPncnpPb0hBwaSm
X-Received: by 10.202.80.145 with SMTP id e139mr5963095oib.55.1497623262709;
	Fri, 16 Jun 2017 07:27:42 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id 14sm1208728oth.10.2017.06.16.07.27.41
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Fri, 16 Jun 2017 07:27:41 -0700 (PDT)
Date: Fri, 16 Jun 2017 09:27:39 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_delete
Message-ID: <20170616142739.bdq25iebcfjgwpy4@debian>
References: <20170615143658.uluux6n27z4eix3t@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170615143658.uluux6n27z4eix3t@debian>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::243
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 14:27:48 -0000

On Thu, Jun 15, 2017 at 09:36:58AM -0500, Eduardo Bustamante wrote:
> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
> Sanitizer is followed by the base64 encoded crashing input.
> 
> 
> ==1736==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x611000009880 at pc 0x7f464da3a063 bp 0x7ffe86032fe0 sp 0x7ffe86032790
> READ of size 115 at 0x611000009880 thread T0
>     #0 0x7f464da3a062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
>     #1 0x5634e38634c3 in _rl_find_next_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d4c3)
>     #2 0x5634e3864375 in _rl_find_next_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e375)
>     #3 0x5634e3850c0e in rl_delete (/home/dualbus/src/gnu/bash-build/bash+0x24ac0e)

OK. Here's an easy way to reproduce this.

- Start on an empty rl_line_buffer
- Call `set-mark' with a numeric argument (a large number, e.g. 500, is better).
- Call `exchange-point-and-mark' so that now rl_point = 500
- Call `delete-char'
- Bash crashes

The _rl_set_mark_at_pos function already checks for `position > rl_end',
so I'm not sure how to fix this.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 16 10:43:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLsSy-0002gu-QT
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 10:43:16 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47391)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsSw-0002f3-DN
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:43:15 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsSt-0007fT-A0
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:43:14 -0400
Received: from mail-ot0-x242.google.com ([2607:f8b0:4003:c0f::242]:35206)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLsSt-0007ev-5T
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:43:11 -0400
Received: by mail-ot0-x242.google.com with SMTP id z48so4691028otz.2
	for <bug-bash@gnu.org>; Fri, 16 Jun 2017 07:43:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=byiOAiqgY2/5+Q3Yi60ZLng3izV4b8ii4FzShQE32Fw=;
	b=cEesSd6r+EKugXJoxB9XTFNkF6gZnd082a6vAEFOhOWS+xARdcmM1WRuqQHHgOe5XC
	YpmQwUddgO3Ip/GP2s+UUz1P0l0Zj4LPA4UfxuydngBcEmZ3olFSGtvRmSCD2+Aerr5E
	tIseIK2ej6kV+slDLY4D36nEIqbzWgwJtF+5oNFCdDKVwNS94kRhZ9GcXJZWslGGnKd3
	RmnF9TcByflEojrsTmkXtj61seem2ff4nxNfOUXNe6zkvnZ8y7BehWZ6EyoGdTiOAQCk
	5n166nXgXebA+y0qPpqNziRCMfPsszzzQdqw+wVzE1F+gjOySTmyvMcZtuolbMjagGgL
	c6MA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=byiOAiqgY2/5+Q3Yi60ZLng3izV4b8ii4FzShQE32Fw=;
	b=SaGLLRzHLpKzVLWO1HJMEopVgMuZFaBzse7iQHBYT+rVnu4YAfDMSmdeZ60/xSJg5o
	6n2Ewr5AR50atYWQjZHt/8ZUe5fBFlIKKVBtCxf4YkB1ZSrJ5kQAJzR0TlqpmzhvSfQQ
	2aeN7hAHutZ9s7mVljL/40GyCl/Nxk0gM5RSBL0ys/+ucpbW+bhzEHj0N1jRMN5mtgij
	vxHRqh1Wsw83z/dQdITMmNKTthXPhecySmGf5TuC21LLEa+AedFwMhCCcgQlkCaXzKZP
	KAGICjm5kOT+aQkubXqA1fxVYuEY/9mWuiL+FHSd1m/I1Y8ntC3xCnAx7S4LgTZWp9Pp
	D0qA==
X-Gm-Message-State: AKS2vOyQIjE1HxbA7l92/ua4zWyfEBD3F9HmujZQ/Jwy793OuEeDGYSl
	P37glgmNLwM8VpGW
X-Received: by 10.157.82.38 with SMTP id e38mr6717369oth.153.1497624190148;
	Fri, 16 Jun 2017 07:43:10 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	o184sm1107479oif.23.2017.06.16.07.43.09 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Fri, 16 Jun 2017 07:43:09 -0700 (PDT)
Date: Fri, 16 Jun 2017 09:43:07 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_tilde_expand
Message-ID: <20170616144307.47zo3kumzqgn46dr@debian>
References: <20170615143909.t2dy3xhcia5ufhry@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170615143909.t2dy3xhcia5ufhry@debian>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::242
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 14:43:15 -0000

On Thu, Jun 15, 2017 at 09:39:09AM -0500, Eduardo Bustamante wrote:
> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
> Sanitizer is followed by the base64 encoded crashing input.
> 
> 
> ==472==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x562befba4a14 bp 0x7ffdee172bb0 sp 0x7ffdee172ba8
> READ of size 1 at 0x61100000977f thread T0
>     #0 0x562befba4a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)

This one looks like an easy fix. When `start = 0', the loop ends up
dereferencing `rl_line_buffer[-1]'. Changing the order of the test does the trick.


dualbus@debian:~/src/gnu/bash$ git difftool -y -x 'diff -c' -- lib/readline/util.c 
*** /tmp/zFXFei_util.c  2017-06-16 09:34:03.958088209 -0500
--- lib/readline/util.c 2017-06-16 09:33:09.384638705 -0500
***************
*** 193,199 ****
      }
    else if (start >= 0 && rl_line_buffer[start] != '~')
      {
!       for (; !whitespace (rl_line_buffer[start]) && start >= 0; start--)
          ;
        start++;
      }
--- 193,199 ----
      }
    else if (start >= 0 && rl_line_buffer[start] != '~')
      {
!       for (; start >= 0 && !whitespace (rl_line_buffer[start]); start--)
          ;
        start++;
      }

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 16 10:57:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLsgm-0001jg-9Z
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 10:57:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53131)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsgj-0001jB-9w
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:57:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLsgg-00074T-8e
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:57:29 -0400
Received: from mail-oi0-x242.google.com ([2607:f8b0:4003:c06::242]:33046)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLsgg-00074I-3s
	for bug-bash@gnu.org; Fri, 16 Jun 2017 10:57:26 -0400
Received: by mail-oi0-x242.google.com with SMTP id k145so3791419oih.0
	for <bug-bash@gnu.org>; Fri, 16 Jun 2017 07:57:25 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=MR8P983ZcUM7PGXiDF1BDud+PPQJ2Xkl7J+dL1gpdrI=;
	b=LibMKXSElEPbEucZ2K2bx1K73nF2GqzD9uzMIYuZ5wdU0Jqt4R6ryMrH96PWW4H0vg
	xbHNkHMVES6wZ5eI2oDVTP1AORTw1s2/JYStl8vxmou1X8TafRPgd8AjWGgdXUvDOyMj
	ZQt+THCSR7ufdO4Sj9XJOvTWyXWbsw6HhOV6Jp2uSc04EckiN5ciQbd/hL7Tpn6TSE5V
	ZIgS/huKRBDt5pK7S90g9YGTQXIi7BW4nCHDvbbPeOAtlJMc6ISfgvFaYS5Hk0fHUjlu
	G2GnANMX4FBmHAItlbeOfC9ZMp6Z5izUTRG7Ys3rp3dLeYphS7VprXfuM7sGTJ3lz7Q1
	W2yA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=MR8P983ZcUM7PGXiDF1BDud+PPQJ2Xkl7J+dL1gpdrI=;
	b=rnp3f/r9mbbj2MMMjlVGoGwbAntyoPW1TIIwCkncYPCp0wOfT0ppkPH8SBrj74ESBf
	zBSrk46eY+/OyE+vLtkf/LAyJSG3EU9bYdHBKE/1bRRMOihNR1+4A88no9yICbd7TPWw
	DrssA1BwOROdqDZRC2xD6Xp/31+2fZiteVhoB2YtJOGZEbDHi1yMMWZqQPnrqrLS3hmY
	etFRiMDXow3bBKduYb5H5xBnil4Dr2YgKlCCFkx8VBLUDzHvKu/NbZmoDh9L9EzJ6zar
	nKlrWHAyPv8tImGvx+CnLDqMpLHSnoHwpdi4nxWDgIvDHdbKyYHfRzYDWzki6Ytzdlh2
	61Ig==
X-Gm-Message-State: AKS2vOyG4Ulo3nKiHki0M+N9HPAt23hQvwwxIWWPTk0jObGoHamuCYBS
	pMPUBVKn8gSQ+FBZ
X-Received: by 10.202.222.212 with SMTP id v203mr5532463oig.88.1497625044866; 
	Fri, 16 Jun 2017 07:57:24 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	o70sm1174163oik.30.2017.06.16.07.57.23 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Fri, 16 Jun 2017 07:57:24 -0700 (PDT)
Date: Fri, 16 Jun 2017 09:57:22 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: AddressSanitizer: global-buffer-overflow in
	rl_filename_completion_function
Message-ID: <20170616145722.ciynwsxqm6jkurga@debian>
References: <20170615144108.722izyafdxhycuez@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170615144108.722izyafdxhycuez@debian>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::242
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 14:57:30 -0000

On Thu, Jun 15, 2017 at 09:41:08AM -0500, Eduardo Bustamante wrote:
> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
> Sanitizer is followed by the base64 encoded crashing input.
> 
> 
> ==1098==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55e61a6b4c5c at pc 0x55e61a3426ca bp 0x7fff1820a300 sp 0x7fff1820a2f8
> READ of size 4 at 0x55e61a6b4c5c thread T0
>     #0 0x55e61a3426c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)

Easy fix. `p' is a signed char pointer, therefore when `*p = 255', it tries to
dereference `sh_syntaxtab[-1]'.

dualbus@debian:~/src/gnu/bash$ git difftool -y -x 'diff -c' -- bashline.c
*** /tmp/mVc4sH_bashline.c      2017-06-16 09:52:56.471508904 -0500
--- bashline.c  2017-06-16 09:48:55.706503276 -0500
***************
*** 3886,3892 ****
            *r++ = *p;
          /* Backslashes are preserved within double quotes unless the
             character is one that is defined to be escaped */
!         else if (quoted == '"' && ((sh_syntaxtab[p[1]] & CBSDQUOTE) == 0))
            *r++ = *p;
  
          *r++ = *++p;
--- 3886,3892 ----
            *r++ = *p;
          /* Backslashes are preserved within double quotes unless the
             character is one that is defined to be escaped */
!         else if (quoted == '"' && ((sh_syntaxtab[(unsigned char)p[1]] & CBSDQUOTE) == 0))
            *r++ = *p;
  
          *r++ = *++p;





Maybe it's a good idea to change these too. In locale.c there shouldn't be a
problem, because the loop is constrained to `x < sh_syntabsiz', but perhaps
just to silence compiler warnings :-)?

dualbus@debian:~/src/gnu/bash$ git difftool -y -x 'diff -c' -- locale.c parse.y 
*** /tmp/OyLWya_locale.c        2017-06-16 09:55:15.854368199 -0500
--- locale.c    2017-06-16 09:50:52.816950476 -0500
***************
*** 552,565 ****
    for (x = 0; x < sh_syntabsiz; x++)
      {
        if (isblank ((unsigned char)x))
!       sh_syntaxtab[x] |= CSHBRK|CBLANK;
        else if (member (x, shell_break_chars))
        {
!         sh_syntaxtab[x] |= CSHBRK;
!         sh_syntaxtab[x] &= ~CBLANK;
        }
        else
!       sh_syntaxtab[x] &= ~(CSHBRK|CBLANK);
      }
  }
  
--- 552,565 ----
    for (x = 0; x < sh_syntabsiz; x++)
      {
        if (isblank ((unsigned char)x))
!       sh_syntaxtab[(unsigned char)x] |= CSHBRK|CBLANK;
        else if (member (x, shell_break_chars))
        {
!         sh_syntaxtab[(unsigned char)x] |= CSHBRK;
!         sh_syntaxtab[(unsigned char)x] &= ~CBLANK;
        }
        else
!       sh_syntaxtab[(unsigned char)x] &= ~(CSHBRK|CBLANK);
      }
  }
  
*** /tmp/qKFxWa_parse.y 2017-06-16 09:55:15.862368362 -0500
--- parse.y     2017-06-16 09:52:22.522808775 -0500
***************
*** 4842,4848 ****
  
              /* If the next character is to be quoted, note it now. */
              if (cd == 0 || cd == '`' ||
!                 (cd == '"' && peek_char >= 0 && (sh_syntaxtab[peek_char] & CBSDQUOTE)))
                pass_next_character++;
  
              quoted = 1;
--- 4842,4848 ----
  
              /* If the next character is to be quoted, note it now. */
              if (cd == 0 || cd == '`' ||
!                 (cd == '"' && peek_char >= 0 && (sh_syntaxtab[(unsigned char)peek_char] & CBSDQUOTE)))
                pass_next_character++;
  
              quoted = 1;

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 16 11:10:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLstS-00021B-EC
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 11:10:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57108)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLstQ-000215-Dj
	for bug-bash@gnu.org; Fri, 16 Jun 2017 11:10:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dLstL-0003Ny-En
	for bug-bash@gnu.org; Fri, 16 Jun 2017 11:10:36 -0400
Received: from mail-ot0-x22d.google.com ([2607:f8b0:4003:c0f::22d]:35948)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dLstL-0003Nr-9G
	for bug-bash@gnu.org; Fri, 16 Jun 2017 11:10:31 -0400
Received: by mail-ot0-x22d.google.com with SMTP id s7so32160096otb.3
	for <bug-bash@gnu.org>; Fri, 16 Jun 2017 08:10:31 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=EWGnNmQSoNyyh2OzUL6lK3ajnBVGQDk3F7wSJqPjSZU=;
	b=M+nKp3EYx2GEIk41KjrmV+VMMRmKY7vMaAScYTqd/QJE27Dgck5X26I/2AIndVJrs3
	20KWahdH/PS1wzTYEatliAPKyjde771u7CKUVN03wt5RqkgusgcwpoWhdYAz6dSOEVc/
	eiMMWMSL79pZ839/lpFvMfBPASSpRqCNKyeH5kCpgQeNam5itWzcQP9C1d2EzWZwPq5d
	J72dbWSVkOqWF/xbERsAXfWi3yq1Hek72fPXusr9AlxadEi08+R99ifGDt+qSe/Z/VkJ
	iAptEs8LMDWSJIuSTT3TwtjFuBht0omUtUjj1ewXbWwJVZG0ziwX9CBWr9/ljQF3E0tZ
	cuPw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=EWGnNmQSoNyyh2OzUL6lK3ajnBVGQDk3F7wSJqPjSZU=;
	b=Qn51CcKHSnLIpqnOUeUX1O2TuGBi+rKI/nVasweGOabxH4jmkmGE3vZtJN1tsYHQG8
	B0e2Wrx9uezoU3SsDTzxIhBWtt01r5q+ZWLuXZJyFvIv5TcEuJC/MrTT89NNJLbDnFGn
	q7IFoYOoQKA3Z4eS8MNjySjTLiNejbZWNnzkUnWu4RoVRVULxcU0l/fXjiKbyTBVJDKN
	8mUhXaef8TsV6JHMJlexNXV9rRBMrRwcoujuqczY5SaCDOoz46IumN8003GUl2lhyvHc
	ISgWrqFqcuEt9QQfXHbwdJFTDjUIl6LXKHxcD0+ph3iSyWr1nr1aRqCnUmpepm2cm120
	ercA==
X-Gm-Message-State: AKS2vOz1nvKzU9BoDDNaQnijGGRTt9epJJFiyRDN2NMAAb2x/aBEVC8h
	PYmv0sDO3I2Tyd7Q
X-Received: by 10.157.45.169 with SMTP id g38mr6367228otb.73.1497625830519;
	Fri, 16 Jun 2017 08:10:30 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id p3sm1146125oia.24.2017.06.16.08.10.29
	for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Fri, 16 Jun 2017 08:10:29 -0700 (PDT)
Date: Fri, 16 Jun 2017 10:10:28 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_kill_text
Message-ID: <20170616151028.lj4t2gmxkao5c2ni@debian>
References: <20170615144241.jxvplir4wsbau42f@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <20170615144241.jxvplir4wsbau42f@debian>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 15:10:37 -0000

On Thu, Jun 15, 2017 at 09:42:41AM -0500, Eduardo Bustamante wrote:
> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
> Sanitizer is followed by the base64 encoded crashing input.
> 
> 
> ==11018==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x559bb60f1be7 bp 0x7ffc36ec8710 sp 0x7ffc36ec8708
> READ of size 8 at 0x60700000ccc0 thread T0
>     #0 0x559bb60f1be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)

Easy fix. When `rl_kill_ring_length == rl_max_kills (10)', all of the entries
in the kill ring are shifted. The loop has an off-by-one error though.

I also think that using `rl_max_kills' in the loop instead of `slot' makes the
code easier to read.

dualbus@debian:~/src/gnu/bash$ git difftool -y -x 'diff -c' -- lib/readline/kill.c 
*** /tmp/uLCFvH_kill.c  2017-06-16 10:04:43.472930262 -0500
--- lib/readline/kill.c 2017-06-16 10:04:20.048344312 -0500
***************
*** 113,119 ****
            {
              register int i;
              xfree (rl_kill_ring[0]);
!             for (i = 0; i < slot; i++)
                rl_kill_ring[i] = rl_kill_ring[i + 1];
            }
          else
--- 113,119 ----
            {
              register int i;
              xfree (rl_kill_ring[0]);
!             for (i = 0; i < rl_max_kills - 1; i++)
                rl_kill_ring[i] = rl_kill_ring[i + 1];
            }
          else

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Fri Jun 16 12:05:50 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLtks-0008Uo-2k
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 12:05:50 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51812)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLtkp-0008Su-LF
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:05:48 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLtkk-0000HM-IT
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:05:47 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:59486
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLtkk-0000Gt-DO
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:05:42 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANP09364; Fri, 16 Jun 2017 12:05:40 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFR74266 (AUTH cpr);
	Fri, 16 Jun 2017 12:05:37 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_delete
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170615143658.uluux6n27z4eix3t@debian>
	<20170616142739.bdq25iebcfjgwpy4@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <428925e5-9d05-74d5-e6f7-26fe720a1e71@case.edu>
Date: Fri, 16 Jun 2017 12:05:29 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170616142739.bdq25iebcfjgwpy4@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.145715:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_1500_1599, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 16:05:48 -0000

On 6/16/17 10:27 AM, Eduardo A. Bustamante López wrote:
> On Thu, Jun 15, 2017 at 09:36:58AM -0500, Eduardo Bustamante wrote:
>> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
>> Sanitizer is followed by the base64 encoded crashing input.
>>
>>
>> ==1736==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x611000009880 at pc 0x7f464da3a063 bp 0x7ffe86032fe0 sp 0x7ffe86032790
>> READ of size 115 at 0x611000009880 thread T0
>>     #0 0x7f464da3a062  (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x3c062)
>>     #1 0x5634e38634c3 in _rl_find_next_mbchar_internal (/home/dualbus/src/gnu/bash-build/bash+0x25d4c3)
>>     #2 0x5634e3864375 in _rl_find_next_mbchar (/home/dualbus/src/gnu/bash-build/bash+0x25e375)
>>     #3 0x5634e3850c0e in rl_delete (/home/dualbus/src/gnu/bash-build/bash+0x24ac0e)
> 
> OK. Here's an easy way to reproduce this.
> 
> - Start on an empty rl_line_buffer
> - Call `set-mark' with a numeric argument (a large number, e.g. 500, is better).
> - Call `exchange-point-and-mark' so that now rl_point = 500
> - Call `delete-char'
> - Bash crashes

I can't reproduce this using the current development version. Its failure
depends on rl_end already being wrong.  I've already fixed that particular
problem; it was a problem with the isearch code that requires the obscure
circumstances fuzzing brings to reproduce.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 16 12:10:43 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLtpb-00037N-DZ
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 12:10:43 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53947)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLtpZ-00037G-99
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:10:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLtpV-0001g6-78
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:10:41 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:23094
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLtpV-0001ft-2H
	for bug-bash@gnu.org; Fri, 16 Jun 2017 12:10:37 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMF07609; Fri, 16 Jun 2017 12:10:35 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGA47044 (AUTH cpr);
	Fri, 16 Jun 2017 12:10:33 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_tilde_expand
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170615143909.t2dy3xhcia5ufhry@debian>
	<20170616144307.47zo3kumzqgn46dr@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <a2b6a68b-48b1-2cd8-9a94-0b4cd4605645@case.edu>
Date: Fri, 16 Jun 2017 12:10:26 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170616144307.47zo3kumzqgn46dr@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.151516:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 16:10:42 -0000

On 6/16/17 10:43 AM, Eduardo A. Bustamante López wrote:
> On Thu, Jun 15, 2017 at 09:39:09AM -0500, Eduardo Bustamante wrote:
>> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
>> Sanitizer is followed by the base64 encoded crashing input.
>>
>>
>> ==472==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61100000977f at pc 0x562befba4a14 bp 0x7ffdee172bb0 sp 0x7ffdee172ba8
>> READ of size 1 at 0x61100000977f thread T0
>>     #0 0x562befba4a13 in rl_tilde_expand (/home/dualbus/src/gnu/bash-build/bash+0x23ba13)
> 
> This one looks like an easy fix. When `start = 0', the loop ends up
> dereferencing `rl_line_buffer[-1]'. Changing the order of the test does the trick.

This is indeed the right fix.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 16 14:07:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLveJ-0005ac-Ev
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 14:07:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33622)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLveH-0005aU-UX
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:07:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLveE-0003TO-Nj
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:07:09 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:15520
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLveE-0003Sn-IJ
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:07:06 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANP15400; Fri, 16 Jun 2017 14:07:02 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFR92668 (AUTH cpr);
	Fri, 16 Jun 2017 14:07:01 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: global-buffer-overflow in
	rl_filename_completion_function
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170615144108.722izyafdxhycuez@debian>
	<20170616145722.ciynwsxqm6jkurga@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <736e682b-7ce3-bfa9-8680-091934a9cffb@case.edu>
Date: Fri, 16 Jun 2017 14:06:53 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170616145722.ciynwsxqm6jkurga@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.170018:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_800_899,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 18:07:11 -0000

On 6/16/17 10:57 AM, Eduardo A. Bustamante López wrote:
> On Thu, Jun 15, 2017 at 09:41:08AM -0500, Eduardo Bustamante wrote:
>> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
>> Sanitizer is followed by the base64 encoded crashing input.
>>
>>
>> ==1098==ERROR: AddressSanitizer: global-buffer-overflow on address 0x55e61a6b4c5c at pc 0x55e61a3426ca bp 0x7fff1820a300 sp 0x7fff1820a2f8
>> READ of size 4 at 0x55e61a6b4c5c thread T0
>>     #0 0x55e61a3426c9 in bash_dequote_filename (/home/dualbus/src/gnu/bash-build/bash+0x17a6c9)
> 
> Easy fix. `p' is a signed char pointer, therefore when `*p = 255', it tries to
> dereference `sh_syntaxtab[-1]'.

This is right.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 16 14:11:13 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLviD-0007I4-37
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 14:11:13 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34594)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLviB-0007Hy-BY
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:11:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLvi6-00054c-9d
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:11:11 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:16229
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLvi6-00054I-4C
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:11:06 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANP15605; Fri, 16 Jun 2017 14:11:04 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFR93484 (AUTH cpr);
	Fri, 16 Jun 2017 14:11:03 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: heap-buffer-overflow in rl_kill_text
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170615144241.jxvplir4wsbau42f@debian>
	<20170616151028.lj4t2gmxkao5c2ni@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <12b67411-30b7-2b68-1378-8731f2672048@case.edu>
Date: Fri, 16 Jun 2017 14:11:02 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170616151028.lj4t2gmxkao5c2ni@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.170018:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 18:11:12 -0000

On 6/16/17 11:10 AM, Eduardo A. Bustamante López wrote:
> On Thu, Jun 15, 2017 at 09:42:41AM -0500, Eduardo Bustamante wrote:
>> Found by fuzzing `read -e' with AFL. The stacktrace reported by Address
>> Sanitizer is followed by the base64 encoded crashing input.
>>
>>
>> ==11018==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60700000ccc0 at pc 0x559bb60f1be7 bp 0x7ffc36ec8710 sp 0x7ffc36ec8708
>> READ of size 8 at 0x60700000ccc0 thread T0
>>     #0 0x559bb60f1be6 in _rl_copy_to_kill_ring (/home/dualbus/src/gnu/bash-build/bash+0x23cbe6)
> 
> Easy fix. When `rl_kill_ring_length == rl_max_kills (10)', all of the entries
> in the kill ring are shifted. The loop has an off-by-one error though.

This is one possible fix. There is also the asymmetry in the xrealloc
below.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 16 14:35:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dLw69-0005Er-D1
	for mharc-bug-bash@gnu.org; Fri, 16 Jun 2017 14:35:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39643)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLw66-0005EC-FF
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:35:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dLw62-0003Cs-9p
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:35:54 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:47414
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dLw62-0003CY-3Y
	for bug-bash@gnu.org; Fri, 16 Jun 2017 14:35:50 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMF14900; Fri, 16 Jun 2017 14:35:23 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFR97390 (AUTH cpr);
	Fri, 16 Jun 2017 14:35:22 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Why does 'connect' take so long (sometimes) and can't be
	interrupted?
To: gazelle@xmission.com, bug-bash@gnu.org
References: <E1dLWoe-0000mG-Aq@shell.xmission.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <1ae0c480-0839-f5e1-0797-aa83897d7897@case.edu>
Date: Fri, 16 Jun 2017 14:35:21 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <E1dLWoe-0000mG-Aq@shell.xmission.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.16.172116:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_1100_1199,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, __SINGLE_URI_TEXT, SINGLE_URI_IN_BODY,
	__PHISH_SPEAR_STRUCTURE_1, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 16 Jun 2017 18:35:55 -0000

On 6/15/17 11:36 AM, gazelle@xmission.com wrote:

> 	Note, however, that it does eventually connect.  As far as I can tell, it
> 	does always eventually connect.
> 
> 	Needless to say, when I first hit this problem, I assumed it had hung, and
> 	when I tried to kill it, I ran into the problems described above.

It's all system calls. If it hangs in `connect', bash has to wait until
the system call returns one way or another.  There is no provision for a
timeout with connect, and any signal (e.g., SIGALRM) that bash tries to
set for a timeout will be deferred until connect completes or fails
anyway.

> 
> 	Also note: In testing this, I found that if I do hit ^C while it is hung,
> 	then wait long enough, eventually it does exit as shown below:
> 
> Elapsed time for this 'exec' ...	^C^C^C^Cbash: connect: Connection refused
> bash: /dev/tcp/localhost/12345: Connection refused

If that's a legit error, the problem might be with the server.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 17 04:41:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dM9Il-0004Yg-Kz
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 04:41:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37072)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dM9Ij-0004YZ-FX
	for bug-bash@gnu.org; Sat, 17 Jun 2017 04:41:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dM9Ig-0004y1-Bn
	for bug-bash@gnu.org; Sat, 17 Jun 2017 04:41:49 -0400
Received: from mail-ot0-x243.google.com ([2607:f8b0:4003:c0f::243]:35798)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dM9Ig-0004xa-6v
	for bug-bash@gnu.org; Sat, 17 Jun 2017 04:41:46 -0400
Received: by mail-ot0-x243.google.com with SMTP id z48so6716410otz.2
	for <bug-bash@gnu.org>; Sat, 17 Jun 2017 01:41:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=KIw2FDQUFzUqGwBFx7nIp9OfjxLYg3NtnmZkX9owo+o=;
	b=KZVZWlHftyLLof47Wh+HsxJG5ujIpiUdzKe/lHgjjUIjaXmO/BO5GoOecvfHvOMas1
	J/J4/kW6AOyrssXfnTM3F0pW5iMUf0kyr8pTBfj+UwjFOhDnMwPThX5QPN/pmvhtOSrb
	0NbZc3zHK9PZVSOdI5yn0nyB0VM9chIiGMMbrD3ofXybLyJj8wizErp+nyBavA3NNtlK
	tJN4y3G//1ofYOqqrTcskP2w9mwJ/Xar+VuXxUQT83MGRTVOGVsGnk1ryCOs6qgr9TRN
	TmregwgIIxn0GohqDnqoRGFUlvORc/tcqsSoyHNTuyYvR9WK0Ylz5+7nw4ZuE396QyVo
	h0rg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=KIw2FDQUFzUqGwBFx7nIp9OfjxLYg3NtnmZkX9owo+o=;
	b=nZ3SJnyXq0KTRrt4IwXFRAZPnOVzzhDIJQZfbeTjDe3l+SrsNtO8ZKyUKhE2Fmh+vq
	yCgFmB3QzbVJNC7bU3sqbLAQ/Kjgev4so4B3NAxGVVXNXl8B1YrJGCRpeh4m804iLaHl
	rWWppkkvs79lYiMBiMcaGpOHpcZwRe60zQZBLPXDfclrCDB7S7mN/VEPxKaAQ/UEWvK4
	iftAyj2D4DvfbQ+NAwH2at4I8xWwBDHT8iA/0cqoBNoYbXmDe9EpVY7kmh7Vm7SDXICy
	6YMJN8gUqibBPo/75AUsLRUQa+9Mmy6zzFNdEQ2fStgqTCh7JZW8U+IyDb8udtvHW2LE
	Xrkw==
X-Gm-Message-State: AKS2vOzUkhKez5Jn21FRoQWVRRzllNexX5PtMzaEt2QZInxlIXtFYcWp
	zIwBbV1XYN/LEE/n
X-Received: by 10.157.27.47 with SMTP id l44mr7369161otl.241.1497688904990;
	Sat, 17 Jun 2017 01:41:44 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	c42sm2515242otc.58.2017.06.17.01.41.43
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 17 Jun 2017 01:41:44 -0700 (PDT)
Date: Sat, 17 Jun 2017 03:41:42 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Return code of coproc when NAME is not a legal_identifier
Message-ID: <20170617084142.64655pqqk2eexena@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::243
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 17 Jun 2017 08:41:50 -0000

The manual is clear on this:

  Since the coprocess is created as an asynchronous command, the coproc
  command always returns success

I'd argue that it should return an error code for this particular case
though:

  $ bash -c 'coproc % { :; }; echo $?'
  bash: `%': not a valid identifier
  0


The `execute_coproc' function _seems_ to try to return an error code for this
case (by the way, the value of `invert' is undefined at this point):

  2301   /* XXX - expand coproc name without splitting -- bash-5.0 */
  2302   /* could make this dependent on a shopt option */
  2303   name = expand_string_unsplit_to_string (command->value.Coproc->name, 0);
  2304   /* Optional check -- bash-5.0. */
  2305   if (legal_identifier (name) == 0)
  2306     {
  2307       internal_error (_("`%s': not a valid identifier"), name);
  2308       return (invert ? EXECUTION_SUCCESS : EXECUTION_FAILURE);
  2309     }
  2310   else
  2311     {
  2312       free (command->value.Coproc->name);
  2313       command->value.Coproc->name = name;
  2314     }


The following patch fixes this (coproc returns $? = 1 when `NAME' is not a
legal identifier), although I'm not convinced about the quality of this patch.


dualbus@debian:~/src/gnu/bash$ git diff
diff --git a/execute_cmd.c b/execute_cmd.c
index 0183a105..ab022bdb 100644
--- a/execute_cmd.c
+++ b/execute_cmd.c
@@ -597,8 +597,9 @@ execute_command_internal (command, asynchronous, pipe_in, pipe_out,
     return (execute_in_subshell (command, asynchronous, pipe_in, pipe_out, fds_to_close));
 
 #if defined (COPROCESS_SUPPORT)
-  if (command->type == cm_coproc)
-    return (execute_coproc (command, pipe_in, pipe_out, fds_to_close));
+  if (command->type == cm_coproc) {
+    return (last_command_exit_value = execute_coproc (command, pipe_in, pipe_out, fds_to_close));
+  }
 #endif
 
   user_subshell = command->type == cm_subshell || ((command->flags & CMD_WANT_SUBSHELL) != 0);
@@ -2298,6 +2299,8 @@ execute_coproc (command, pipe_in, pipe_out, fds_to_close)
   coproc_init (&sh_coproc);
 #endif
 
+  invert = (command->flags & CMD_INVERT_RETURN) != 0;
+
   /* XXX - expand coproc name without splitting -- bash-5.0 */
   /* could make this dependent on a shopt option */
   name = expand_string_unsplit_to_string (command->value.Coproc->name, 0);
@@ -2313,7 +2316,6 @@ execute_coproc (command, pipe_in, pipe_out, fds_to_close)
       command->value.Coproc->name = name;
     }
 
-  invert = (command->flags & CMD_INVERT_RETURN) != 0;
   command_string_index = 0;
   tcmd = make_command_string (command);




This came up as a warning from cppcheck:

  [../bash/execute_cmd.c:2308]: (error) Uninitialized variable: invert

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 17 05:10:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dM9kr-0002dy-0T
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 05:10:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39979)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dM9ko-0002de-LQ
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:10:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dM9kl-0005BK-Gt
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:10:50 -0400
Received: from mail-oi0-x241.google.com ([2607:f8b0:4003:c06::241]:34284)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dM9kl-0005B1-3P
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:10:47 -0400
Received: by mail-oi0-x241.google.com with SMTP id w127so5400097oiw.1
	for <bug-bash@gnu.org>; Sat, 17 Jun 2017 02:10:47 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=P6ETylMCJ1cr7iiYVFK2MZ9DrXy/372Tl6vfmW3XWdY=;
	b=jYW6JpRuIx7r931riqheSISpDE6AItxCZ1OjrrBtVEvUGV35FNarqCZ79hQ8YDKEcu
	ejL/jIsDE1m3MkqXjd7wuG2TAPHzq+ochewAnJwYdmCJjJCW9knSid4TC77yR0o3cGJO
	j8tCQadnQHEGZZUmZqLpqCdu4S26etRJovf79jWR212UcJiwIxdxujMtUkszUTsdOaYN
	AwHiSTUO7aaWaTIwuI7ivTZ6TAYpyIdW3fiIbttfkLhrbH4H3dZ6vE1d5/T6le38VQtz
	w4KsN8Sm83GczCKOzAHR+53qbmciI/OGRgA9/LaLHn0GjJIL48Vui+fewDco9v2RUPpc
	vltg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=P6ETylMCJ1cr7iiYVFK2MZ9DrXy/372Tl6vfmW3XWdY=;
	b=ibzuZqY7opKTzdOLVeqnY1b3HgzvqH7mnmc2auobQKbk7rbt1f7p1XCUFYMzQLfmAV
	81FpTQjzQaYthB0juioWhbrFHgx+Y3Aj3ThrpuLlr4UTSlfeKO7hyNVGlISElTJ8zcAk
	Pnn6c3o6FcARKI1Vo5GGu32VYLzGPZkClDqJBEYjTiaio1aJnk5aI/XNZQVgBgTVTDFk
	Bxqr1CrBJewOeByThcJXzMmWj5lOgivGH4hta1TZImdUsqNRhxaSgZ8CgYfFWIALln/T
	uOiezniDAi3Ills6807m3AIpIF+9OnTY6JLj280Q8grxZQM0gsAf7Wytgd9J857F5yy5
	ffsg==
X-Gm-Message-State: AKS2vOyHg6O/sfbmqcQ4sKSbFbiTNCnY061osyCqgwjDP5NlxbWxUzKA
	eKRxErjGneNXyG1f
X-Received: by 10.202.222.212 with SMTP id v203mr7194082oig.88.1497690646340; 
	Sat, 17 Jun 2017 02:10:46 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	r45sm2625937ota.37.2017.06.17.02.10.45
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 17 Jun 2017 02:10:45 -0700 (PDT)
Date: Sat, 17 Jun 2017 04:10:43 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: [PATCH] Bash does not build when --disable-multibyte due to missing
	HAVE_MULTIBYTE guard in display.c
Message-ID: <20170617091043.s6hic2k6qwhazme7@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::241
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 17 Jun 2017 09:10:51 -0000

dualbus@debian:~/src/gnu/bash$ git diff -- lib/readline/display.c 
diff --git a/lib/readline/display.c b/lib/readline/display.c
index d5536211..1f281cd3 100644
--- a/lib/readline/display.c
+++ b/lib/readline/display.c
@@ -2127,7 +2127,7 @@ dumb_update:
                      cpos_adjusted = 1;
                    }
 
-#if 1
+#ifdef HAVE_MULTIBYTE
                  /* If we write a non-space into the last screen column,
                     remove the note that we added a space to compensate for
                     a multibyte double-width character that didn't fit, since

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 17 05:27:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMA14-00064P-Kd
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 05:27:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41661)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMA12-000649-75
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:27:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMA0x-0007GG-9V
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:27:36 -0400
Received: from mail-ot0-x234.google.com ([2607:f8b0:4003:c0f::234]:36054)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dMA0x-0007GC-2N
	for bug-bash@gnu.org; Sat, 17 Jun 2017 05:27:31 -0400
Received: by mail-ot0-x234.google.com with SMTP id s7so43802491otb.3
	for <bug-bash@gnu.org>; Sat, 17 Jun 2017 02:27:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:content-transfer-encoding:user-agent;
	bh=mHkLaBM69FXZfGIckJN24fDmvTZerGU5Olp/plaNpKc=;
	b=KHwuU9Sh0vpJGWDcVobDSAE0zKSqneqfEfZFc1SYg2/eCHZvnAdeoSbSOtArQopqJn
	Q6gCmNq+w/fBwK0iJaa/0PGuCrWgYQR6PY9Nq3Ub9JW5wuXXLfL23+eX2HMgd7LDxIkr
	T71vuPjuO9Y00Ut6Y7VU2Kd8PYAfyzHzCx7axYA1nMhyFetLReZX+6Z6lbz0+3jvKGL9
	1oCycF5jT+JMCPSvXGv0225KaT26wYxYoDPAnOlpnPG+SZB6zPumJwOHr0RRewn7EQYX
	/juaHz59LZglweyAzqpem1dhJJ76tOQDviM9LYIm1pj8nfNM7IMrtX99qNNhDmsT6bxl
	YKzQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:content-transfer-encoding:user-agent;
	bh=mHkLaBM69FXZfGIckJN24fDmvTZerGU5Olp/plaNpKc=;
	b=LWU68KVslz+lHvwe/+fexln2f4Xv8j0VJvnzEK7iQ7zC8YeX7gKFXLEsjac6n7hR4X
	mQEYM3yW7RSGmlVvdmEZ0mjr5LrpIPLDJHuC6vhpOzVsRaiXp+pGypc5pd9+FXAVqCZ5
	HOHypVsRLmbeQAFkqNpOUYcQrCtJELtjKA//gGr2Dx3RrfzoDQF+KNX0zOVeMmFJbh+W
	kxJ3AlwszJU37ExkmJYuq9xKpD4oOr1ldR/vlv+uW/fftIFalIkeczq8S1FPUqFIV2iP
	/AhpV+9iiXYMs4rwoh/OwzJkJsZD5YM2z+9WF359//HL6dW0SdhIyDU1xdfjAxTncrbn
	clVA==
X-Gm-Message-State: AKS2vOyvYL3r2Vm55eeE+Ld6B3QAjI+DNxHUwOVC80GyRTZfTytEXNuD
	VzWH9kBd4pTyn1DE
X-Received: by 10.157.31.25 with SMTP id x25mr5399670otd.148.1497691650054;
	Sat, 17 Jun 2017 02:27:30 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	u78sm2240446oie.15.2017.06.17.02.27.29
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 17 Jun 2017 02:27:29 -0700 (PDT)
Date: Sat, 17 Jun 2017 04:27:28 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Issues with `rl_vi_change_char' function in combination with
	`_rl_vi_redoing = 1'
Message-ID: <20170617092728.mwm5fr4uyk7bqs67@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 17 Jun 2017 09:27:38 -0000

# When bash is compiled with multibyte support, the following happens:

- set -o vi
- Type: <a><ESC><r><ñ><.>
- Bash writes \261 to `mb[0]' and '\0' to `mb[1]' (ñ is U+00F1, or in
  UTF-8, \303\261)
- `mb' is of type signed char, and not really suitable to store a wide
  character.

  dualbus@debian:~$ set -o vi
  dualbus@debian:~$ �
  bash: $'\261': command not found


# When bash is compiled w/o multibyte support, the following happens:

  1948 int
  1949 rl_vi_change_char (int count, int key)
  1950 {
  1951   int c;
  1952   char mb[MB_LEN_MAX]; /* MB_LEN_MAX == 1 */
  1953 
  1954   if (_rl_vi_redoing)
  1955     {
  1956       c = _rl_vi_last_replacement;
  1957       mb[0] = c;
  1958       mb[1] = '\0'; /* out of bounds write */
  1959     }

Reproduce with:

- set -o vi
- Type: <a><ESC><r><b><.>
- Bash writes '\0' to `mb[1]', which is out of bounds.

  dualbus@debian:~/src/gnu/bash-build$ ./bash
  bash-4.4$ set -o vi
  bash-4.4$ =================================================================
  ==7881==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7ffe8416f471 at pc 0x55e4ba75d81a bp 0x7ffe8416f420 sp 0x7ffe8416f418
  WRITE of size 1 at 0x7ffe8416f471 thread T0
      #0 0x55e4ba75d819 in rl_vi_change_char ../../../bash/lib/readline/vi_mode.c:1959
      #1 0x55e4ba74fe3d in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
      #2 0x55e4ba74fa18 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
      #3 0x55e4ba752a41 in rl_vi_redo ../../../bash/lib/readline/vi_mode.c:285
      #4 0x55e4ba74fe3d in _rl_dispatch_subseq ../../../bash/lib/readline/readline.c:851
      #5 0x55e4ba74fa18 in _rl_dispatch ../../../bash/lib/readline/readline.c:797
      #6 0x55e4ba74f257 in readline_internal_char ../../../bash/lib/readline/readline.c:629
      #7 0x55e4ba74f2e9 in readline_internal_charloop ../../../bash/lib/readline/readline.c:656
      #8 0x55e4ba74f30d in readline_internal ../../../bash/lib/readline/readline.c:670
      #9 0x55e4ba74e9c3 in readline ../../../bash/lib/readline/readline.c:374
      #10 0x55e4ba5ffd01 in yy_readline_get ../bash/parse.y:1464
      #11 0x55e4ba5ffed9 in yy_readline_get ../bash/parse.y:1495
      #12 0x55e4ba5ffb64 in yy_getc ../bash/parse.y:1397
      #13 0x55e4ba601ea4 in shell_getc ../bash/parse.y:2297
      #14 0x55e4ba6048d0 in read_token ../bash/parse.y:3146
      #15 0x55e4ba6032ad in yylex ../bash/parse.y:2683
      #16 0x55e4ba5f7f31 in yyparse /home/dualbus/src/gnu/bash-build/y.tab.c:1821
      #17 0x55e4ba5f7102 in parse_command ../bash/eval.c:294
      #18 0x55e4ba5f7357 in read_command ../bash/eval.c:338
      #19 0x55e4ba5f6593 in reader_loop ../bash/eval.c:140
      #20 0x55e4ba5f1d3d in main ../bash/shell.c:794
      #21 0x7ff2e9a7d2b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
      #22 0x55e4ba5f0939 in _start (/home/dualbus/src/gnu/bash-build/bash+0x7b939)
  
  Address 0x7ffe8416f471 is located in stack of thread T0 at offset 33 in frame
      #0 0x55e4ba75d72f in rl_vi_change_char ../../../bash/lib/readline/vi_mode.c:1950
  
    This frame has 1 object(s):
      [32, 33) 'mb' <== Memory access at offset 33 overflows this variable
  HINT: this may be a false positive if your program uses some custom stack unwind mechanism or swapcontext
        (longjmp and C++ exceptions *are* supported)
  SUMMARY: AddressSanitizer: stack-buffer-overflow ../../../bash/lib/readline/vi_mode.c:1959 in rl_vi_change_char
  Shadow bytes around the buggy address:
    0x100050825e30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825e40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825e50: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825e60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825e70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  =>0x100050825e80: 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1[01]f4
    0x100050825e90: f4 f4 f3 f3 f3 f3 00 00 00 00 00 00 00 00 00 00
    0x100050825ea0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825eb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825ec0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
    0x100050825ed0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  Shadow byte legend (one shadow byte represents 8 application bytes):
    Addressable:           00
    Partially addressable: 01 02 03 04 05 06 07 
    Heap left redzone:       fa
    Heap right redzone:      fb
    Freed heap region:       fd
    Stack left redzone:      f1
    Stack mid redzone:       f2
    Stack right redzone:     f3
    Stack partial redzone:   f4
    Stack after return:      f5
    Stack use after scope:   f8
    Global redzone:          f9
    Global init order:       f6
    Poisoned by user:        f7
    Container overflow:      fc
    Array cookie:            ac
    Intra object redzone:    bb
    ASan internal:           fe
    Left alloca redzone:     ca
    Right alloca redzone:    cb
  ==7881==ABORTING


Issue found with cppcheck:

  [../bash/lib/readline/vi_mode.c:1958]: (error) Array 'mb[1]' accessed at index 1, which is out of bounds.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 17 14:50:30 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMInm-0001cl-Mq
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 14:50:30 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45168)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMInh-0001ca-Kw
	for bug-bash@gnu.org; Sat, 17 Jun 2017 14:50:29 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMInd-0002LY-Ps
	for bug-bash@gnu.org; Sat, 17 Jun 2017 14:50:25 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:53191
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMInd-0002Ko-KE
	for bug-bash@gnu.org; Sat, 17 Jun 2017 14:50:21 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMF51317; Sat, 17 Jun 2017 14:50:19 -0400 (EDT)
Received: from h251.16.30.71.dynamic.ip.windstream.net (EHLO jenna.local)
	([71.30.16.251]) by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQG79599 (AUTH cpr);
	Sat, 17 Jun 2017 14:50:16 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: =?UTF-8?Q?Re:_Issues_with_`rl=5fvi=5fchange=5fchar'_function_in_com?=
	=?UTF-8?Q?bination_with_`=5frl=5fvi=5fredoing_=3d_1'=1b?=
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170617092728.mwm5fr4uyk7bqs67@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <7aaf5c0c-0bbf-7561-2da1-5af52d2a1fe0@case.edu>
Date: Sat, 17 Jun 2017 14:50:15 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170617092728.mwm5fr4uyk7bqs67@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.17.181516:17:8.129, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __UTF8_SUBJ,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG, __HAS_HTML,
	HTML_NO_HTTP, BODY_SIZE_600_699, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 17 Jun 2017 18:50:29 -0000

On 6/17/17 5:27 AM, Eduardo A. Bustamante López wrote:
> # When bash is compiled with multibyte support, the following happens:
> 
> - set -o vi
> - Type: <a><ESC><r><ñ><.>
> - Bash writes \261 to `mb[0]' and '\0' to `mb[1]' (ñ is U+00F1, or in
>   UTF-8, \303\261)

This needs changes similar to _rl_vi_last_search_char.

> - `mb' is of type signed char, and not really suitable to store a wide
>   character.

This doesn't really matter, since that's not the intent.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 17 18:54:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMMbn-00046o-DJ
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 18:54:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51707)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMMbk-00046E-7N
	for bug-bash@gnu.org; Sat, 17 Jun 2017 18:54:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMMbg-0002bF-Tw
	for bug-bash@gnu.org; Sat, 17 Jun 2017 18:54:20 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:15106
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMMbg-0002b6-Ni
	for bug-bash@gnu.org; Sat, 17 Jun 2017 18:54:16 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMK55229; Sat, 17 Jun 2017 18:54:14 -0400 (EDT)
Received: from h251.16.30.71.dynamic.ip.windstream.net (EHLO jenna.local)
	([71.30.16.251]) by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQH73590 (AUTH cpr);
	Sat, 17 Jun 2017 18:54:14 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, Eduardo Bustamante <dualbus@gmail.com>,
	bug-bash@gnu.org, George <tetsujin@scope-eye.net>
Subject: Re: Buffer corruption when the terminal is resized.
To: Paul Peet <peetpaul69@gmail.com>
References: <CALfJGG-075Nap0vYTxwv_LmmbR=1hB5omsOxF5Dnw2wqf-2GyQ@mail.gmail.com>
	<CALfJGG_L=6-5QWd=vT=B0hLs2vWGA3_xJRgYcR2T-u-4mXvVpA@mail.gmail.com>
	<20170610165803.iyoc4qlsuzxux5tj@debian>
	<CALfJGG_WLwGd4XDxjpeZbLBh+hYKwKVBzBYEtNq8Byc=g4Bk+g@mail.gmail.com>
	<20170610212056.iphrgnrccux2cqx3@debian>
	<CALfJGG97u02ZzUrWW2Qs6Hmmh_E=TAZPf2eVOS17AZbsdgJjvA@mail.gmail.com>
	<20170612043549.k25sr26l24ge6so5@debian>
	<CALfJGG8NG_Pfx5n2tEOzzD2Ap8kFeNXnniOfdTYj4Jh6m3PcsQ@mail.gmail.com>
	<a0580df4-8965-36f6-bd11-d2c0312ffdd8@case.edu>
	<CALfJGG9mYpYN0YMTj6Gb8zHSvOXqSUVUUgDo7oEYEdByJLV3jQ@mail.gmail.com>
	<6ceb7dae-66db-1f7a-0e35-fc1ed5fc6457@case.edu>
	<CALfJGG_ZNNLkyiCvFWM_J7XLJirBrOAsdDwvxgs99Tdbv1dnyg@mail.gmail.com>
	<aaef7361-cf95-fe51-b6a3-44691a2175c0@case.edu>
	<CALfJGG86G-wwPV0zudr4v21Ji9+CbmojDO+eWs6bwSbAxtRmdw@mail.gmail.com>
	<5d26ea59-2047-fd94-0f06-fb64755c22a3@case.edu>
	<70fb6400-d848-d3e7-99cd-d83b41ef073a@case.edu>
	<CALfJGG_7b8BMJ-ZT-NrWbcRYDEW-7naRg-GDB1C3BWeiKYHGFQ@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <928edef8-ef62-e0af-75d3-04e8f27b41a6@case.edu>
Date: Sat, 17 Jun 2017 18:54:13 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <CALfJGG_7b8BMJ-ZT-NrWbcRYDEW-7naRg-GDB1C3BWeiKYHGFQ@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.17.213916:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __HTTPS_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__MULTIPLE_URI_TEXT, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__TO_REAL_NAMES, __CC_REAL_NAMES, MULTIPLE_REAL_RCPTS,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 17 Jun 2017 22:54:21 -0000

On 6/12/17 9:49 PM, Paul Peet wrote:

> Yes, indeed, rewrapping the contents on resize breaks this assumption.
> 
> Given that in a(n obviously non-representative) poll about 1.5 years
> ago at https://opensource.com/life/15/11/top-open-source-terminal-emulators,
> terminal emulators that now (not at the time of the poll) rewrap on
> resize got around 50-60% of the votes, maybe it's time for
> readline/bash to reconsider their assumptions.

The problem with reconsidering this assumption is that it leaves you with
no recourse but to move to a new line (and who knows, it may be a line
containing newly-wrapped text) and just do a fresh redraw when you get a
SIGWINCH.  That's going to leave even more text on the screen than now, for
gains only in pathological cases.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 17 20:23:19 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMNzq-0005F3-Tv
	for mharc-bug-bash@gnu.org; Sat, 17 Jun 2017 20:23:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58748)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMNzo-0005Et-D0
	for bug-bash@gnu.org; Sat, 17 Jun 2017 20:23:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMNzl-0006cr-8S
	for bug-bash@gnu.org; Sat, 17 Jun 2017 20:23:16 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:62509
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMNzl-0006bB-2d
	for bug-bash@gnu.org; Sat, 17 Jun 2017 20:23:13 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANK59063; Sat, 17 Jun 2017 20:23:08 -0400 (EDT)
Received: from h251.16.30.71.dynamic.ip.windstream.net (EHLO jenna.local)
	([71.30.16.251]) by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQU83864 (AUTH cpr);
	Sat, 17 Jun 2017 20:23:07 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
To: tetsujin@scope-eye.net, Greg Wooledge <wooledg@eeg.ccf.org>,
	bug-bash <bug-bash@gnu.org>
References: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <e92913a1-faf5-8589-0d9b-493b48652ff9@case.edu>
Date: Sat, 17 Jun 2017 20:23:06 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.17.230015:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NO_NAME,
	__TO_NAME, __TO_NAME_DIFF_FROM_ACC, __REFERENCES,
	__HAS_FROM, FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID,
	DATE_TZ_NA, __USER_AGENT, __MOZILLA_USER_AGENT,
	__MIME_VERSION, __IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __STOCK_PHRASE_7,
	__OEM_PRICE, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1800_1899,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 00:23:17 -0000

On 6/14/17 12:04 PM, tetsujin@scope-eye.net wrote:
> 
> This is relevant to my interests!
> 
> So first off, the circular reference problem with "declare -n"
> apparently doesn't exist in Korn Shell: If you "typeset -n x=$1", and
> $1 is "x", it's not a circular reference. The nameref seems to take
> the origin of the name into account when creating the nameref: If $1
> is used to provide the name for a nameref within a function, then the
> nameref refers to a variable in the scope of the function's caller.
> But if the name for the nameref is taken from another parameter, or a
> string literal, then the variable is drawn from the scope of the
> function itself. It seems a little "black magic" in a way but it has
> the benefit of neatly matching some important common use-cases. I
> think Bash should either adopt something similar, or provide another
> mechanism to exclude function-local variables from nameref
> construction.

I've gotten a suggestion that function-scope circular references should
always be resolved beginning at the previous scope, but I haven't done
anything to implement that yet.

There are a couple of problems that make it less clean to implement the
Korn shell mechanism. First, declare is a shell builtin, which means that
its arguments are expanded before it sees them. x=$1 and x=x both look
the same to declare when it sees them. The second is dynamic scoping,
which makes resolution tricker. The korn shell uses static scoping, so it
only has to look at the current scope and the global scope (which makes
the x=$1 case even more irregular).

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 18 17:02:19 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMhKt-0004At-MY
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 17:02:19 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51467)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMhKq-0003zQ-ER
	for bug-bash@gnu.org; Sun, 18 Jun 2017 17:02:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMhKn-0000nQ-CM
	for bug-bash@gnu.org; Sun, 18 Jun 2017 17:02:16 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:57358
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dMhKn-0000n5-51
	for bug-bash@gnu.org; Sun, 18 Jun 2017 17:02:13 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5IL25vO099522
	for <bug-bash@gnu.org>; Sun, 18 Jun 2017 14:02:08 -0700
Message-ID: <5946EA4D.8030004@tlinx.org>
Date: Sun, 18 Jun 2017 14:02:05 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: bug-bash <bug-bash@gnu.org>
Subject: Regression -- can't read input w/stderr redirect
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 21:02:17 -0000

I think I've found why I keep getting random values for
my DPI on my X-server starting from **Cygwin**.

I read a binary value in the low byte in
the registry Dword (broken apart due to line length):

  my -r HKLM='HKEY_LOCAL_MACHINE'
  my -r MsWinNT='SOFTWARE/Microsoft/Windows NT'
  my -r DPI_Px='FontDPI/LogPixels'
  my -r proc_reg='/proc/registry'

  my -r pixels_key="$HKLM/$MsWinNT/CurrentVersion/$DPI_Px"
  my -r pixels_path="$proc_reg/$pixels_key"

  int dpi=$(ord $(<"$pixels_path" 2>/dev/null))


This used to work but now works _unreliably_.

(NOTE: I know that function won't work for values over 255,
but hasn't been a problem yet, so haven't needed to fix it).

Tried running it interactively, and got:

  > int dpi=$(ord $(<"$pixels_path" ))          
  -bash: warning: command substitution: ignored null byte in input

I've always expected the '0' bytes to terminate input so
my "ord" only picked up the 1st character, but I know
about the added message.

Side question: Why display that message if there are only
NUL's at the end?  I would think it normal for bash to
use and read NUL terminated strings.  So why the err message
in that case?  FWIW, if the null bytes are anywhere BUT
the end, then I'd see that as an error, but usually with
C and bash, a NUL-byte terminating a string seems a bit
"unremarkable". (no?)

Nevertheless, even with the warning, dpi returned with the
correct value:

  > echo $dpi
  120

But the warning looks sloppy, so tried:

  int dpi=$(ord $(<"$pixels_path" 2>/dev/null))
  # no error message, but also got (in my script):

  ./get_NT_DPI: line 13: $1: unbound variable

Line 13 is the 'ord' function which doesn't get a param:

  function ord() { printf "%d" "'$1" ; }


So why do I get no output when I redirect the error
message?

Easy to dup:

echo -n >/tmp/x x
#working:
a=$(ord $(</tmp/x))
echo $a
120
#not working
a=$(ord $(</tmp/x 2>/dev/null))
echo $a
0


p.s. - maybe ignoring NUL's at end of input would be a
good thing?










From MAILER-DAEMON Sun Jun 18 18:05:56 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMiKS-000392-41
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 18:05:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35663)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMiKP-00037R-6E
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:05:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMiKK-0003nN-5j
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:05:53 -0400
Received: from mail-ot0-x22f.google.com ([2607:f8b0:4003:c0f::22f]:33001)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dMiKK-0003mm-0n
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:05:48 -0400
Received: by mail-ot0-x22f.google.com with SMTP id y47so35006686oty.0
	for <bug-bash@gnu.org>; Sun, 18 Jun 2017 15:05:47 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=uV5SgwqS8LFcLVdjTaV9oV5def2n+NCcaem4ajoVoNE=;
	b=Gj0RoJtV3xLXvagESL/cAkAL/FJgBFjybEt7YZVhXTeA/74uq4YcgUu62n3tIvinR2
	CBH/Zbrns+O0gpRwVkJr9tpFxGWbq70dn+osUfi5YcniNQmSItE8qfn3NAJkn0MrURWj
	eNluNyStFKEpYNRfS7hQptbVID4WS0oF+F4zksYvbbkH4IzBqGB37bRu+vJxXZ0FI3//
	+CcoVI06SFt6+ER/1ddY+CKxFlGlLnwCPzWfjNmuyIJIkBbnOOrSR9rOuQfaBOnph5xn
	J2uOioln3G4eHAWx0nOX1e5ZG2GcmwHWZtJI2oMedCShbypXePcXNdeVYqFx04Tvtye1
	IlnQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=uV5SgwqS8LFcLVdjTaV9oV5def2n+NCcaem4ajoVoNE=;
	b=TBzxjx1v2XBUyOJivGYIYvCkN7pfbyPDWWmDEhr57Vapr3ws8vitENSzhoH8AUyFyP
	92+y9GTwZC3C+CgsXhWxxFgANntzdQRb4Vm2fe6VxSCw6G5rw/dmlw9FJmAE9PXv+4cp
	lj8FN9hB0WHd1Wiv9mRMKAEMcX+XlcjsOR+o+HvRZyPrkV8PU4f/ONLG+RxyN9XUC5M3
	zMab5MoX0ZREZOAk7YYlj6vfzK+IpzjDVOwb+2jdKocbyslQpk++fMfnFce6hQy4z+xe
	wNlxJJV0U8ahoFp56Vqv8UagiTJ/Q7B/zH4nj0OJd+CB6icks63syWbSv30UMmjivpLx
	FMmg==
X-Gm-Message-State: AKS2vOxZ5Vq/AX8jwBqntWzwLTpLyFJ06m+GBlY+7ausTcfFqsd9i/tU
	2c4uNkjJfDNsjCkM
X-Received: by 10.157.0.73 with SMTP id 67mr12268431ota.112.1497823546904;
	Sun, 18 Jun 2017 15:05:46 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id f24sm4944250otc.1.2017.06.18.15.05.45
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 18 Jun 2017 15:05:46 -0700 (PDT)
Date: Sun, 18 Jun 2017 17:05:39 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: L A Walsh <bash@tlinx.org>
Cc: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
Message-ID: <20170618220539.22orzggpp2avhclc@debian>
References: <5946EA4D.8030004@tlinx.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <5946EA4D.8030004@tlinx.org>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 22:05:54 -0000

On Sun, Jun 18, 2017 at 02:02:05PM -0700, L A Walsh wrote:
[...]
>  int dpi=$(ord $(<"$pixels_path" 2>/dev/null))
> 
> This used to work but now works _unreliably_.

In what version does this used to work?

I tested on a couple of versions, and the behavior you describe didn't work:

  dualbus@debian:~/src/gnu/bash-builds$ for b in bash-*/; do $b/bash -c 'echo $(< <(echo x)) $BASH_VERSION'; done
  x 3.2.57(1)-release
  x 4.2.0(1)-release
  x 4.2.53(1)-release
  x 4.3.30(1)-release
  
  dualbus@debian:~/src/gnu/bash-builds$ for b in bash-*/; do $b/bash -c 'echo $(< <(echo x) >/dev/stdout) $BASH_VERSION'; done
  3.2.57(1)-release
  4.2.0(1)-release
  4.2.53(1)-release
  4.3.30(1)-release


And if you inspect the source code, you'll notice that this the command
substitution "cat file" functionality is implemented in here:

builtins/evalstring.c:

  413               /* See if this is a candidate for $( <file ). */
  414               if (startup_state == 2 &&
  415                   (subshell_environment & SUBSHELL_COMSUB) &&
  416                   *bash_input.location.string == '\0' &&
  417                   command->type == cm_simple && !command->redirects &&
  418                   (command->flags & CMD_TIME_PIPELINE) == 0 &&
  419                   command->value.Simple->words == 0 &&
  420                   command->value.Simple->redirects &&
  421                   command->value.Simple->redirects->next == 0 &&
  422                   command->value.Simple->redirects->instruction == r_input_direction &&
  423                   command->value.Simple->redirects->redirector.dest == 0)
  424                 {
  425                   int r;
  426                   r = cat_file (command->value.Simple->redirects);
  427                   last_result = (r < 0) ? EXECUTION_FAILURE : EXECUTION_SUCCESS;
  428                 }

It's clear that the following conditions must be met:

- The redirection must be performed inside a command substitution (ln.
  415)
- The command substitution must be a simple command (ln. 417)
- The simple command must consist of a single input redirection (ln.
  420), i.e. no words (ln. 419), no "next" redirection (ln. 421), input
  redirection (ln. 422), and the target being file descriptor 0 (ln.
  423).

So that means that `echo $(<X 2>Y)' is not a valid "cat file" command
substitution.

I think that you're looking for:

  $ bash -c 'printf "x\0y" > f; { a=$(<f); } 2>/dev/null; declare -p a'
  declare -- a="xy"

Instead.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sun Jun 18 18:37:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMipF-0002GE-3g
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 18:37:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41592)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMipC-0002G3-9S
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:37:43 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMip9-0001lu-2J
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:37:42 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:32850
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dMip8-0001kb-RL
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:37:38 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5IMbVct061665; Sun, 18 Jun 2017 15:37:34 -0700
Message-ID: <594700AB.6070109@tlinx.org>
Date: Sun, 18 Jun 2017 15:37:31 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: =?UTF-8?B?IkVkdWFyZG8gQS4gQnVzdGFtYW50ZSBMw7NwZXoi?= <dualbus@gmail.com>,
	bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
References: <5946EA4D.8030004@tlinx.org>
	<20170618220539.22orzggpp2avhclc@debian>
In-Reply-To: <20170618220539.22orzggpp2avhclc@debian>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v5IMbVct061665
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 22:37:43 -0000



Eduardo A. Bustamante L=C3=B3pez wrote:
> On Sun, Jun 18, 2017 at 02:02:05PM -0700, L A Walsh wrote:
> [...]
>  =20
>>  int dpi=3D$(ord $(<"$pixels_path" 2>/dev/null))
>> This used to work but now works _unreliably_.
>>    =20
>
> In what version does this used to work?
>  =20
----
It used to work when "2>/dev/null" wasn't required to
silence unwanted error messages.


> It's clear that the following conditions must be met:
>
> - The redirection must be performed inside a command substitution (ln.
>   415)
> - The command substitution must be a simple command (ln. 417)
> - The simple command must consist of a single input redirection (ln.
>   420), i.e. no words (ln. 419), no "next" redirection (ln. 421), input
>   redirection (ln. 422), and the target being file descriptor 0 (ln.
>   423).
>  =20
----
    Seems unnecessarily limited.  If bash is going to emit out
warnings, then it seems allowing them to be silenced at the point
where they come out would be reasonable, though in this case,
see further on...


> I think that you're looking for:
>
>   $ bash -c 'printf "x\0y" > f; { a=3D$(<f); } 2>/dev/null; declare -p =
a'
>   declare -- a=3D"xy"
> Instead.
>  =20
Not really -- I hadn't thought about the impact of of NUL's
other than at the end.  For example, if I tried to create a
workaround but tried to read 256, which would have been
encoded as "0x00 0x01 0x00 0x00" -- even in UTF-16:

printf  "\0\001\0\0" >/tmp/f  =20
...> a=3D$(</tmp/f)
bash: warning: command substitution: ignored null byte in input
...> echo "$a"|hexdump -C
00000000  01 0a
>  echo $LC_CTYPE
en_US.UTF-16

(0x100 =3D a cap A with a line over it (=C4=80)).

I'd prefer to see the warning if the NUL byte was other than
at the end. The case with NUL at the end is a standard
string terminator.  I think the warning message wouldn't have been
seen by as many people if it only complained about NUL's in the
middle (vs. as a string-terminator).  No?




From MAILER-DAEMON Sun Jun 18 18:39:15 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMiqh-0002WA-Cy
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 18:39:15 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41820)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMiqe-0002Vy-NG
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:39:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMiqb-0002fM-Ft
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:39:12 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:23946
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMiqb-0002eI-Al
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:39:09 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANP85520; Sun, 18 Jun 2017 18:39:03 -0400 (EDT)
Received: from h200.223.21.98.dynamic.ip.windstream.net (EHLO _192.168.254.9_)
	([98.21.223.200])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQM35542 (AUTH cpr);
	Sun, 18 Jun 2017 18:39:02 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Regression -- can't read input w/stderr redirect
To: L A Walsh <bash@tlinx.org>, bug-bash <bug-bash@gnu.org>
References: <5946EA4D.8030004@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
Date: Sun, 18 Jun 2017 18:39:01 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <5946EA4D.8030004@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.18.220016:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1400_1499, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 22:39:14 -0000

On 6/18/17 5:02 PM, L A Walsh wrote:

>  int dpi=$(ord $(<"$pixels_path" 2>/dev/null))
> 
> 
> This used to work but now works _unreliably_.
> 
> (NOTE: I know that function won't work for values over 255,
> but hasn't been a problem yet, so haven't needed to fix it).
> 
> Tried running it interactively, and got:
> 
>  > int dpi=$(ord $(<"$pixels_path" ))           -bash: warning: command
> substitution: ignored null byte in input

These are not the same command. Eduado explained why this matters.

> 
> I've always expected the '0' bytes to terminate input so
> my "ord" only picked up the 1st character, but I know
> about the added message.

Bash has always stripped NULL bytes. Now it tells you it's doing it.

> 
> Side question: Why display that message if there are only
> NUL's at the end?  I would think it normal for bash to
> use and read NUL terminated strings.  

This is very uncommon. Most Unix utilities use newline-terminated
lines.


> So why the err message
> in that case?  FWIW, if the null bytes are anywhere BUT
> the end, then I'd see that as an error, but usually with
> C and bash, a NUL-byte terminating a string seems a bit
> "unremarkable". (no?)

Internally, maybe, but not when dealing with external utilities.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 18 18:59:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMjAe-0007HE-Sw
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 18:59:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44194)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMjAd-0007H4-8Z
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:59:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMjAa-0001wB-7c
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:59:51 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:33710
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dMjAZ-0001vE-RC
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:59:48 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5IMxetv063403; Sun, 18 Jun 2017 15:59:42 -0700
Message-ID: <594705DC.6000300@tlinx.org>
Date: Sun, 18 Jun 2017 15:59:40 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
In-Reply-To: <6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 22:59:52 -0000



Chet Ramey wrote:
> Bash has always stripped NULL bytes. Now it tells you it's doing it.
Why?  Did I toggle a flag asking for the warning?  Seems like it
was sorta sprung on users w/no way to disable it.
>   
>> Side question: Why display that message if there are only
>> NUL's at the end?  I would think it normal for bash to
>> use and read NUL terminated strings.  
>>     
>
> This is very uncommon. Most Unix utilities use newline-terminated
> lines.
>   
----
    But things are changing -- people have asked for zero-terminated read's
and readarrays.  More unix utils are offering NUL termination as an option
because newlines alone don't cut it in some instances.

    Also, Bash is being used on windows: in cygwin and natively.
It's not uncommon for NUL's to be in input on windows --
its VERY common if you read something from the registry (as I've
done for over a decade), or if you read something with UTF-16
in it as I just tried to do.  Bash mangles the locale's strings.
In UTF-16, 0x0000 (16-bits) of zero are an eoln. 
> Internally, maybe, but not when dealing with external utilities.
>   
Dealing with the registry is pretty common on Windows.
You don't want to stick with a solution that will orphan
all those windows users do you?

:-)






From MAILER-DAEMON Sun Jun 18 20:02:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMk99-0001mN-Vy
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 20:02:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50473)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMk98-0001eI-34
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:02:23 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMk93-0000wk-89
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:02:22 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:30639
	helo=mpv1-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMk93-0000wf-23
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:02:17 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANP87408; Sun, 18 Jun 2017 20:02:13 -0400 (EDT)
Received: from h200.223.21.98.dynamic.ip.windstream.net (EHLO _192.168.254.9_)
	([98.21.223.200])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQZ90781 (AUTH cpr);
	Sun, 18 Jun 2017 20:02:12 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
To: L A Walsh <bash@tlinx.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
Date: Sun, 18 Jun 2017 20:02:11 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <594705DC.6000300@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.18.230016:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1200_1299,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 00:02:23 -0000

On 6/18/17 6:59 PM, L A Walsh wrote:
> 
> 
> Chet Ramey wrote:
>> Bash has always stripped NULL bytes. Now it tells you it's doing it.
> Why?  Did I toggle a flag asking for the warning?  Seems like it
> was sorta sprung on users w/no way to disable it.

Users asked why bash transformed input without warning, even though it
had been doing that it's entire lifetime. A warning is appropriate.

>>  
>>> Side question: Why display that message if there are only
>>> NUL's at the end?  I would think it normal for bash to
>>> use and read NUL terminated strings.      
>>
>> This is very uncommon. Most Unix utilities use newline-terminated
>> lines.
>>   
> ----
>    But things are changing -- people have asked for zero-terminated read's
> and readarrays.  More unix utils are offering NUL termination as an option
> because newlines alone don't cut it in some instances.

And bash provides mechanisms to deal with the relatively few use cases
where it is a problem.

Recall that the only thing that has changed is that bash now provides a
warning about what it's doing.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 18 20:06:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMkDb-0002C0-RT
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 20:06:59 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51028)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <martijn@inlv.org>) id 1dMkDZ-0002Bt-DG
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:06:58 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <martijn@inlv.org>) id 1dMkDU-0002ue-E8
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:06:57 -0400
Received: from kahlil.inlv.org ([37.59.109.123]:52604)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <martijn@inlv.org>) id 1dMkDU-0002uD-5L
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:06:52 -0400
Received: from breedzicht.local
	(host86-187-167-0.range86-187.btcentralplus.com [86.187.167.0])
	(authenticated bits=0)
	by kahlil.inlv.org (8.14.9/8.14.4) with ESMTP id v5J06kkS008960
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO)
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 02:06:49 +0200
From: Martijn Dekker <martijn@inlv.org>
Subject: devel: 'eval' returns 0 upon syntax error
To: bug-bash@gnu.org
Message-ID: <cc14921d-a1a9-776a-4b03-6bb39aad679f@inlv.org>
Date: Mon, 19 Jun 2017 01:06:44 +0100
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Language: nl
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy]
X-Received-From: 37.59.109.123
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 00:06:58 -0000

bash-snap-20170616

$ (eval '(');echo $?
bash: eval: line 2: syntax error: unexpected end of file
0

The exit status is 0, but should be 1.

As far as I can trace it, this bug seems to have been introduced in
bash-20170511 snapshot.

- M.


From MAILER-DAEMON Sun Jun 18 20:22:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMkSx-0005Ze-Gn
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 20:22:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53695)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMkSv-0005ZY-7J
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:22:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMkSr-0001gu-9B
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:22:49 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:5113
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMkSr-0001gX-3E
	for bug-bash@gnu.org; Sun, 18 Jun 2017 20:22:45 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMK85750; Sun, 18 Jun 2017 20:22:41 -0400 (EDT)
Received: from h200.223.21.98.dynamic.ip.windstream.net (EHLO _192.168.254.9_)
	([98.21.223.200])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HQM76446 (AUTH cpr);
	Sun, 18 Jun 2017 20:22:41 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: devel: 'eval' returns 0 upon syntax error
To: Martijn Dekker <martijn@inlv.org>, bug-bash@gnu.org
References: <cc14921d-a1a9-776a-4b03-6bb39aad679f@inlv.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <123dd353-d0d4-dcb5-64bf-1f3a9997a69e@case.edu>
Date: Sun, 18 Jun 2017 20:22:40 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <cc14921d-a1a9-776a-4b03-6bb39aad679f@inlv.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.18.233916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_400_LESS, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_300_399, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 00:22:50 -0000

On 6/18/17 8:06 PM, Martijn Dekker wrote:
> (eval '(');echo $?

Thanks for the report.  The parse error followed by EOF needs to call
YYABORT when the shell isn't reading input interactively.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 18 21:39:22 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMlf0-0001yf-I5
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 21:39:22 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60807)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMlex-0001y3-WA
	for bug-bash@gnu.org; Sun, 18 Jun 2017 21:39:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMleu-0004RA-T7
	for bug-bash@gnu.org; Sun, 18 Jun 2017 21:39:20 -0400
Received: from mail-oi0-x231.google.com ([2607:f8b0:4003:c06::231]:35284)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dMleu-0004Qp-NV
	for bug-bash@gnu.org; Sun, 18 Jun 2017 21:39:16 -0400
Received: by mail-oi0-x231.google.com with SMTP id c189so23862526oia.2
	for <bug-bash@gnu.org>; Sun, 18 Jun 2017 18:39:16 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=b67i/tVq+I/+p0wNNmB5OctH2TNZ6kRfJZPSUM+FVxc=;
	b=aUTwMhDVqKZ/qI7q48ZuzbQJwzZaObBFYmB1cVKGv//4AaVS4+zUuMiTlFQAnBqXDA
	+MGiSlfSHGE5AvtfQYSdkAke2x0xhGjoMRCj95ef0FZ8XeP0OTluMM9hR596LsB77nM0
	2u+6B7toLjjFasckvBn1Cv8ll9dKBFopsWMWpaBoxqRppS6w8JQQznO/T8yNmnTzQ2+j
	YuVQcMRy3gKNnOODtrbo8xncd/vyU1udA9acVBZ673tHchE72xqvaBGVoRqHzQScM2wM
	9OS8KrF3Or0pl5DJ6hI/zti+4VxNh2bdWKzHveOUt3f6C0zOYNxcjw9/fYVgwJ0yDKRc
	ECyQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=b67i/tVq+I/+p0wNNmB5OctH2TNZ6kRfJZPSUM+FVxc=;
	b=KIWtV5s+LFq0y/SNisAbDJhspgKnFkhEWr+KnPuimvV5MEKV4mUshAuLvnu5/t7BWI
	GRGWkuCt4eiBVezmB4l0+sYA4bOaibIdx8NRYpifju/ZJwoolIGcuv2j8hdTyys2CiEl
	F36qrpdAWzcMAA2WvKwSYNDBy1WkCwQTa1USaJ/tzWhO3KBhdkBN8xbhX8S70GWvbiKu
	DVotO4xoCBEMbtTfJ7YUt71PGFeCoy24kRbq0+HZgorp3VbTaPtlbKFT1vZBI8BszfZ2
	crpuhuvTjjf3OVksy5TcBB94+RlHfOVR2avlfp+KSQc7nsVU4/ua2ggeOln8WsWVHjdf
	pSmg==
X-Gm-Message-State: AKS2vOxTU7OgUhgMgKCiwz+etC/P0XIX0rVBhmskCFgOFDGTXCyVP5yd
	vR9YmaorSocO+XVg
X-Received: by 10.202.237.205 with SMTP id l196mr5896060oih.167.1497836355573; 
	Sun, 18 Jun 2017 18:39:15 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	f41sm1098085ote.29.2017.06.18.18.39.14
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sun, 18 Jun 2017 18:39:15 -0700 (PDT)
Date: Sun, 18 Jun 2017 20:39:08 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Read builtin -e (readline) oddities
Message-ID: <20170619013908.x6gqolm7nv7noxmx@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::231
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 01:39:21 -0000

I'm trying to figure out a way to fuzz >>read -e -d ""<<, without having the
fuzzer break due to the temporary files created by fc.

While doing this, I noticed the oddities described below.


#1
Hit `C-x C-e' twice.  The value of PATH seems to be ignored for the second
line.

  dualbus@debian:~$ PATH= read -e
  
  bash: vim: No such file or directory
  
  echo hi
  hi


#2
Spurious `;'s are inserted into the history.

  dualbus@debian:~$ history -c
  dualbus@debian:~$ PATH= read -e
  
  bash: vim: No such file or directory
  
  echo hi
  hi
  
  dualbus@debian:~$ history
      1  PATH= read -e; ; 
      2  echo hi
      3  history


#3
Hit `C-x C-e' thrice. Also, the mapping of `\C-m' became `self-insert' instead
of `accept-line'.

  dualbus@debian:~$ PATH= EDITOR=: read -e -d ''
  
  PATH= EDITOR=: read -e -d ''; 
  
  fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
  : /tmp/bash-fc.IZAzmF
  PATH= EDITOR=: read -e -d ''; ; 
  bash: syntax error near unexpected token `;'
  
  fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
  vim /tmp/bash-fc.35ePED
  ^M^M^C
  dualbus@debian:~$ ^M^M^M^M^M^M^M^M



In relation to my fuzzing goal, it seems this is what I wanted:

  dualbus@debian:~$ (enable -n fc; read -e -d '')
  
  bash: fc: command not found
  
  bash: fc: command not found
  
  bash: fc: command not found
  
  bash: fc: command not found
  
  bash: fc: command not found
  ^C

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sun Jun 18 22:18:00 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMmGO-000165-Ke
	for mharc-bug-bash@gnu.org; Sun, 18 Jun 2017 22:18:00 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36712)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMmGM-00015y-PW
	for bug-bash@gnu.org; Sun, 18 Jun 2017 22:17:59 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dMmGI-0006OU-NG
	for bug-bash@gnu.org; Sun, 18 Jun 2017 22:17:58 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:41262
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dMmGI-0006Kx-FN
	for bug-bash@gnu.org; Sun, 18 Jun 2017 22:17:54 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5J2HkZd078621; Sun, 18 Jun 2017 19:17:48 -0700
Message-ID: <5947344A.7020805@tlinx.org>
Date: Sun, 18 Jun 2017 19:17:46 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: chet.ramey@case.edu
CC: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
In-Reply-To: <d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 02:17:59 -0000



Chet Ramey wrote:
> On 6/18/17 6:59 PM, L A Walsh wrote:
>   
>> Chet Ramey wrote:
>>     
>>> Bash has always stripped NULL bytes. Now it tells you it's doing it.
>>>       
>> Why?  Did I toggle a flag asking for the warning?  Seems like it
>> was sorta sprung on users w/no way to disable it.
>>     
>
> Users asked why bash transformed input without warning, even though it
> had been doing that it's entire lifetime. A warning is appropriate.
>   
Maybe - but links to, at least, 2-3 users who filed bug reports about this
problem in bug-bash would be appropriate as well to justify the inclusion
of the text.

I don't recall it ever coming up until the warning message was discussed 
as being unwelcome.  So please, I'd like to see the bug-report filings 
where this
happened.


>> ----
>>    But things are changing -- people have asked for zero-terminated read's
>> and readarrays.  More unix utils are offering NUL termination as an option
>> because newlines alone don't cut it in some instances.
>>     
>
> And bash provides mechanisms to deal with the relatively few use cases
> where it is a problem.
>
> Recall that the only thing that has changed is that bash now provides a
> warning about what it's doing.
>   
Oh?  I want to read in a value from the registry where something may 
have zeros
after the data.  Please tell me the mechanism to read this in w/no warnings
that won't silence more serious cases of zero's other than at the end of 
line.

I want to see the hyperlinks to archived bug-discussions on bug-bash where
users complained about this and where it was at the end of a string where
they expected to be able to read past a binary-0 in the input.

I know I would have like the ability to read binary data into to a var that
might "include a NUL", but I don't recall ever complaining about 
end-of-string
NUL's being trimmed -- and it was drummed home to me how the null's were the
end of the string -- not how bash read everything but nulls from input.









From MAILER-DAEMON Mon Jun 19 00:07:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMnyX-0007gW-OO
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 00:07:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53427)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dMnyV-0007g3-7V
	for bug-bash@gnu.org; Mon, 19 Jun 2017 00:07:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dMnyS-0008Jp-15
	for bug-bash@gnu.org; Mon, 19 Jun 2017 00:07:39 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:48937
	helo=homiemail-a42.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dMnyR-0008JH-M7
	for bug-bash@gnu.org; Mon, 19 Jun 2017 00:07:35 -0400
Received: from homiemail-a42.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a42.g.dreamhost.com (Postfix) with ESMTP id D837A9017274; 
	Sun, 18 Jun 2017 21:07:32 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=cTc+4cM2mB2ypkG8
	qhVnFraI2R0=; b=foummTSb9bPjoDr1REL48XUhGLITsBA6hfvdtmTWyNsJZDux
	+FSf31Gj6sL8Bl1XY9gRzkliur9E2Ow64pH1GThWiyKt156pFal8eBUvNYSFEI3x
	EOPgFWOG3CIsZPA5Tfb+7e/wCkSTx6r0qrJ+VcPcU8n6JZcVdl63xi9vVzA=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a42.g.dreamhost.com (Postfix) with ESMTPSA id 537DD9017273;
	Sun, 18 Jun 2017 21:07:32 -0700 (PDT)
Message-ID: <1497845251.17253.555.camel@scope-eye.net>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
From: George <tetsujin@scope-eye.net>
To: chet.ramey@case.edu, Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash
	<bug-bash@gnu.org>
Date: Mon, 19 Jun 2017 00:07:31 -0400
In-Reply-To: <e92913a1-faf5-8589-0d9b-493b48652ff9@case.edu>
References: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
	<e92913a1-faf5-8589-0d9b-493b48652ff9@case.edu>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 04:07:40 -0000

On Sat, 2017-06-17 at 20:23 -0400, Chet Ramey wrote:
> On 6/14/17 12:04 PM, tetsujin@scope-eye.net wrote:
> >=20
> >=20
> > This is relevant to my interests!
> >=20
> > So first off, the circular reference problem with "declare -n"
> > apparently doesn't exist in Korn Shell: If you "typeset -n x=3D$1", a=
nd
> > $1 is "x", it's not a circular reference. The nameref seems to take
> > the origin of the name into account when creating the nameref: If $1
> > is used to provide the name for a nameref within a function, then the
> > nameref refers to a variable in the scope of the function's caller.
> > But if the name for the nameref is taken from another parameter, or a
> > string literal, then the variable is drawn from the scope of the
> > function itself. It seems a little "black magic" in a way but it has
> > the benefit of neatly matching some important common use-cases. I
> > think Bash should either adopt something similar, or provide another
> > mechanism to exclude function-local variables from nameref
> > construction.
> I've gotten a suggestion that function-scope circular references should
> always be resolved beginning at the previous scope, but I haven't done
> anything to implement that yet.
>=20
> There are a couple of problems that make it less clean to implement the
> Korn shell mechanism. First, declare is a shell builtin, which means th=
at
> its arguments are expanded before it sees them. x=3D$1 and x=3Dx both l=
ook
> the same to declare when it sees them. The second is dynamic scoping,
> which makes resolution tricker. The korn shell uses static scoping, so =
it
> only has to look at the current scope and the global scope (which makes
> the x=3D$1 case even more irregular).
>=20
The functionality is the important thing here, not the specific semantics=
. Personally I wouldn't want to emulate the semantics ksh uses to trigger
this behavior anyway. It's the sort of thing that kind of makes sense in =
some ways (i.e. the variable name comes from the caller... =C2=A0So the v=
ariable
ultimately identified in the nameref also comes from the caller) but the =
inconsistency there, of "typeset -n" behaving differently depending on wh=
ere
the name comes from, is very unappealing to me. I'd much rather see this =
behavior activated by an explicit argument to declare, like this:
declare --caller-scope-nameref result_var=3D$whatever
Or this:
declare -n --scope=3Dcaller result_var=3D$whatever
I think switching the behavior in a clear-cut way like that is much prefe=
rable anyway. The fact that it's also easier to implement than the "black
magic" is like a bonus.
This also shouldn't be triggered by circular references: I think it's jus=
t more "black magic" and it's still an incomplete solution to the problem=
:
- Caller has locally-declared $x and $y, calls "f x" to modify its $x
- Function "f" internally creates a nameref "declare -n caller_var=3D$1" =
but it also has $x as a local variable, so $caller_var refers to that one=
.
(It's not a circular reference, but it's not the right variable either.)
My understanding of Bash's variable scoping implementation is a bit limit=
ed at the moment, I think there are still some gaps in my understanding o=
f
it, but I'm pretty sure the approach I described would still work.

From MAILER-DAEMON Mon Jun 19 02:54:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMqaQ-0002YH-Jl
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 02:54:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43424)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dMj3Y-0006Hm-69
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:52:33 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dMj3X-0007zc-8G
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:52:32 -0400
Received: from [2001:3c8:9009:181::2] (port=51786 helo=munnari.OZ.AU)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <kre@munnari.OZ.AU>) id 1dMj3W-0007wE-AI
	for bug-bash@gnu.org; Sun, 18 Jun 2017 18:52:31 -0400
Received: from andromeda.noi.kre.to (localhost [IPv6:::1]) by munnari.OZ.AU
	with ESMTP id v5IMEDuY003963; Mon, 19 Jun 2017 05:14:16 +0700 (ICT)
Received: from andromeda.noi.kre.to (localhost [127.0.0.1])
	by andromeda.noi.kre.to (8.15.1/8.14.2) with ESMTP id v5IME0T3001262;
	Mon, 19 Jun 2017 05:14:01 +0700 (ICT)
From: Robert Elz <kre@munnari.OZ.AU>
To: L A Walsh <bash@tlinx.org>
cc: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
In-Reply-To: <5946EA4D.8030004@tlinx.org>
References: <5946EA4D.8030004@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Mon, 19 Jun 2017 05:14:00 +0700
Message-ID: <29575.1497824040@andromeda.noi.kre.to>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2001:3c8:9009:181::2
X-Mailman-Approved-At: Mon, 19 Jun 2017 02:54:57 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 18 Jun 2017 22:52:33 -0000

    Date:        Sun, 18 Jun 2017 14:02:05 -0700
    From:        L A Walsh <bash@tlinx.org>
    Message-ID:  <5946EA4D.8030004@tlinx.org>


  | Side question: Why display that message if there are only
  | NUL's at the end?  I would think it normal for bash to
  | use and read NUL terminated strings.

Files with nuls are not normal, they're usually some kind of binary
(a.out, jpeg, ...) which most of the time you don't want to read in
a sh script.


  |   int dpi=$(ord $(<"$pixels_path" 2>/dev/null))
  |   # no error message, but also got (in my script):

I think you'll find that's because the $(<file) hack (and a hack it is)
only works when that is the *only* thing in the comamnd substitution, put
anything else at all in there, and you just get a regular command sub
which does exactly what you asked it to (in this case, open a couple of
files, do nothing with them, and then exit, with no output).

Apart from that, the stderr redirection isn't in the right place anyway.
If the elided cat was there, that would remove messages from cat (about
not being able to open the file) but it is in the wrong place to handle
the error about the result of the $( ) having a nul in it.   That would
need to be more like

	int dpi=$(ord $(<"$pixels_path")) 2>/dev/null

I suspect (though I haven't bothered to check it - redirecting errs
from the sh running the script itself has typically been difficult to
achieve.)

kre

ps: I see Eduardo Bustamante has just said almost the same thing with
more detail...



From MAILER-DAEMON Mon Jun 19 03:00:04 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMqfM-0004BX-P1
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 03:00:04 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50687)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dMqfJ-0004BD-PK
	for bug-bash@gnu.org; Mon, 19 Jun 2017 03:00:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <pierre.gaston@gmail.com>) id 1dMqfI-00082n-Jh
	for bug-bash@gnu.org; Mon, 19 Jun 2017 03:00:01 -0400
Received: from mail-qk0-x233.google.com ([2607:f8b0:400d:c09::233]:36709)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <pierre.gaston@gmail.com>)
	id 1dMqfI-00082S-E4
	for bug-bash@gnu.org; Mon, 19 Jun 2017 03:00:00 -0400
Received: by mail-qk0-x233.google.com with SMTP id g83so26634239qkb.3
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 00:00:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=mf/p0oGL5fMnPo+xy8uwpuziSa06t66ZhiDXDtB2JEY=;
	b=BRyNdXLDx3l/HSPMF0FxMDk3cR1ZDLCgwNCr0esXGyUK7BpmU8DhyFEtJ9w40IaFR1
	iEsTFnbKufGcqKD2M0rOA+Q3g884icHDxkEj8AMXPSLxDdzNb6HCavcTVn87KeFAkF5P
	55z0i3AvqmWj2AUf1I35DY44IIDreCEJ0xSiNAgt5D7QrOksVR8AdNfCLAyYog0Z+CNM
	bPTrxkIuT+lInXeU7JsL+Lm4rdpchM9WZpqKH/i7LlxMNFUfQH34hVvKkb79+aQ4ZCyg
	+q+ADjNoAnezFbPFN7oP1/xUdUK1VbefXXiq7xg5U+hHQajWnclyjU9ZWN0X+v4Ne65K
	Mirg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=mf/p0oGL5fMnPo+xy8uwpuziSa06t66ZhiDXDtB2JEY=;
	b=ADsfQle9Jo+Vt/LoDFHnAYW/RQZhWUBa0nPPlt9t58BmHNYdk8wBn3yEZWaMRk30Ai
	vpDmS6e9+w+aAka4Tia3PoyOaACvSC1ckABeRlE+r+4UZVL07iC8Y/+n4rpoIQh3LR6u
	qNq0liMQh1P6prAQa3qwIHnghVLGleIiWHyT+QiGHGnMj2KGq/EvwZoZHAuz/Uh2EbtE
	EIh33f2xPSNjfN9t65lcFtZgYVAqsCDW7lkGeN5TuPbUXV+usked16cdcFpqhB6w9xTI
	MAQyYMEa64buq72PBap16AUQPQj/YpzTFXUBE3mT759NFd1Bm4Tk3xMn6qDKL/BDwhus
	ULYA==
X-Gm-Message-State: AKS2vOxseL+9U5g8ExacS0NVOSzAXqtvkL2NxJrzTL4UMDIk6uPweUPC
	klJ55yENJZadfbPm00vAoSC+hoqvmg==
X-Received: by 10.55.215.80 with SMTP id m77mr26261321qki.186.1497855599599;
	Sun, 18 Jun 2017 23:59:59 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.166.9 with HTTP; Sun, 18 Jun 2017 23:59:39 -0700 (PDT)
In-Reply-To: <5947344A.7020805@tlinx.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
From: Pierre Gaston <pierre.gaston@gmail.com>
Date: Mon, 19 Jun 2017 09:59:39 +0300
Message-ID: <CAPSX3sRFiC+DNce7-oXnS-UkdyEgf0C1Zr0j97e1xNr5n54u=w@mail.gmail.com>
Subject: Re: Regression -- can't read input w/stderr redirect
To: L A Walsh <bash@tlinx.org>
Cc: Chet Ramey <chet.ramey@case.edu>, bug-bash <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::233
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 07:00:03 -0000

On Mon, Jun 19, 2017 at 5:17 AM, L A Walsh <bash@tlinx.org> wrote:

>
>
> Chet Ramey wrote:
>
>> On 6/18/17 6:59 PM, L A Walsh wrote:
>>
>>
>>> Chet Ramey wrote:
>>>
>>>
>>>> Bash has always stripped NULL bytes. Now it tells you it's doing it.
>>>>
>>>>
>>> Why?  Did I toggle a flag asking for the warning?  Seems like it
>>> was sorta sprung on users w/no way to disable it.
>>>
>>>
>>
>> Users asked why bash transformed input without warning, even though it
>> had been doing that it's entire lifetime. A warning is appropriate.
>>
>>
> Maybe - but links to, at least, 2-3 users who filed bug reports about this
> problem in bug-bash would be appropriate as well to justify the inclusion
> of the text.
>
> I don't recall it ever coming up until the warning message was discussed
> as being unwelcome.  So please, I'd like to see the bug-report filings
> where this
> happened.
>
>
> ----
>>>    But things are changing -- people have asked for zero-terminated
>>> read's
>>> and readarrays.  More unix utils are offering NUL termination as an
>>> option
>>> because newlines alone don't cut it in some instances.
>>>
>>>
>>
>> And bash provides mechanisms to deal with the relatively few use cases
>> where it is a problem.
>>
>> Recall that the only thing that has changed is that bash now provides a
>> warning about what it's doing.
>>
>>
> Oh?  I want to read in a value from the registry where something may have
> zeros
> after the data.  Please tell me the mechanism to read this in w/no warnings
> that won't silence more serious cases of zero's other than at the end of
> line.
>
> I want to see the hyperlinks to archived bug-discussions on bug-bash where
> users complained about this and where it was at the end of a string where
> they expected to be able to read past a binary-0 in the input.
>
> I know I would have like the ability to read binary data into to a var that
> might "include a NUL", but I don't recall ever complaining about
> end-of-string
> NUL's being trimmed -- and it was drummed home to me how the null's were
> the
> end of the string -- not how bash read everything but nulls from input.
>
>
I'm sorry  to say that your behavior on this list is just not acceptable.

If you were on IRC I would have banned you much earlier, yet after all
these years of trolling the list, Chet is going to great length to
explain the rationale of his choices while you keep whining for the
shell to just do what you want in the random particular case you
happen to work at the moment.

Your response: you accuse him to lie to you.

I don't think this is constructive in any way and I'm sure
that, even if Chet has probably experienced this kind of online
situation more than most, it's not a pleasant one.

Pierre.

From MAILER-DAEMON Mon Jun 19 08:18:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMvdr-0005mr-I6
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 08:18:51 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35101)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMvdp-0005mY-Si
	for bug-bash@gnu.org; Mon, 19 Jun 2017 08:18:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMvdk-0003LE-Tt
	for bug-bash@gnu.org; Mon, 19 Jun 2017 08:18:49 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:39170 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMvdk-00034w-Lk
	for bug-bash@gnu.org; Mon, 19 Jun 2017 08:18:44 -0400
Received: (qmail 62987 invoked from network); 19 Jun 2017 12:18:14 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Mon, 19 Jun 2017 08:18:14 -0400
Received: (qmail 3847 invoked by uid 563); 19 Jun 2017 12:18:14 -0000
Date: Mon, 19 Jun 2017 08:18:14 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
Message-ID: <20170619121814.GO22519@eeg.ccf.org>
References: <34a012cb21375e7cb3a55ab0123c5015c1887b1a@webmail.scope-eye.net>
	<e92913a1-faf5-8589-0d9b-493b48652ff9@case.edu>
	<1497845251.17253.555.camel@scope-eye.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <1497845251.17253.555.camel@scope-eye.net>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 12:18:50 -0000

On Mon, Jun 19, 2017 at 12:07:31AM -0400, George wrote:
> ultimately identified in the nameref also comes from the caller) but the inconsistency there, of "typeset -n" behaving differently depending on where
> the name comes from, is very unappealing to me. I'd much rather see this behavior activated by an explicit argument to declare, like this:
> declare --caller-scope-nameref result_var=$whatever
> Or this:
> declare -n --scope=caller result_var=$whatever

Or this:
upvar "$1" myvar

~50% joking...


From MAILER-DAEMON Mon Jun 19 09:13:04 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMwUK-0003PM-0T
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:04 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50498)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dMwUH-0003NE-4R
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:02 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dMwUE-000237-0A
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:01 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:60187
	helo=homiemail-a45.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dMwUD-00021v-P1
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:12:57 -0400
Received: from homiemail-a45.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a45.g.dreamhost.com (Postfix) with ESMTP id 22DB64A0E;
	Mon, 19 Jun 2017 06:12:53 -0700 (PDT)
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a45.g.dreamhost.com (Postfix) with ESMTPSA id 176E04A0D;
	Mon, 19 Jun 2017 06:12:53 -0700 (PDT)
Message-Id: <5fcd830c0f2f59c4d4280a6263fbecfd3df6638b@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Greg Wooledge" <wooledg@eeg.ccf.org>,
 "bug-bash" <bug-bash@gnu.org>
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <20170619121814.GO22519@eeg.ccf.org>
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
Date: Mon, 19 Jun 2017 09:12:53 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 13:13:03 -0000

=0A=0AAs a bonus you'd be able to lure the uninitiated into asking quest=
ions=0Alike "What's upvar?"=0A=0A----- Original Message -----=0AFrom: "G=
reg Wooledge" <wooledg@eeg.ccf.org>=0ATo:"bug-bash" <bug-bash@gnu.org>=
=0ACc:=0ASent:Mon, 19 Jun 2017 08:18:14 -0400=0ASubject:Re: RFE: Fix the=
 name collision issues and typing issues with=0Anamerefs, improve variou=
s issues for function libraries=0A=0A On Mon, Jun 19, 2017 at 12:07:31AM=
 -0400, George wrote:=0A > ultimately identified in the nameref also com=
es from the caller)=0Abut the inconsistency there, of "typeset -n" behav=
ing differently=0Adepending on where=0A > the name comes from, is very u=
nappealing to me. I'd much rather see=0Athis behavior activated by an ex=
plicit argument to declare, like this:=0A > declare --caller-scope-namer=
ef result_var=3D$whatever=0A > Or this:=0A > declare -n --scope=3Dcaller=
 result_var=3D$whatever=0A=0A Or this:=0A upvar "$1" myvar=0A=0A ~50% jo=
king...=0A=0A

From MAILER-DAEMON Mon Jun 19 09:13:44 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMwUy-00041O-Jq
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:44 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50751)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMwUv-0003ze-Rd
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:43 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMwUs-0002Hv-O5
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:41 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:26827
	helo=mpv3-2015.case.edu) by eggs.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMwUs-0002Hm-Hz
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:13:38 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AML09775; Mon, 19 Jun 2017 09:13:35 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGC69917 (AUTH cpr);
	Mon, 19 Jun 2017 09:13:34 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
To: L A Walsh <bash@tlinx.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <7eae448b-d2b0-390d-5b08-13beb14b5de3@case.edu>
Date: Mon, 19 Jun 2017 09:13:34 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <5947344A.7020805@tlinx.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.19.124816:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __CC_NAME_DIFF_FROM_ACC,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_900_999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, __CC_REAL_NAMES,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 13:13:43 -0000

On 6/18/17 10:17 PM, L A Walsh wrote:
> 
> 
> Chet Ramey wrote:
>> On 6/18/17 6:59 PM, L A Walsh wrote:
>>  
>>> Chet Ramey wrote:
>>>    
>>>> Bash has always stripped NULL bytes. Now it tells you it's doing it.
>>>>       
>>> Why?  Did I toggle a flag asking for the warning?  Seems like it
>>> was sorta sprung on users w/no way to disable it.

I was wondering why you chose this hill to die on, but then I remembered
you've chosen so many in the past.

The worst part is that you could have spent all this time developing a
patch for the behavior you want, but you chose to spend it complaining.

There is (once again) no path forward for this conversation that isn't
a huge waste of time. I don't plan to continue it.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 19 09:18:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMwZE-0001C1-Dm
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 09:18:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51962)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMwZ7-00017D-Ky
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:18:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMwZ4-0004ft-IE
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:18:01 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:1380
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMwZ4-0004fV-Cc
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:17:58 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANL11521; Mon, 19 Jun 2017 09:17:53 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFU18365 (AUTH cpr);
	Mon, 19 Jun 2017 09:17:52 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: RFE: Fix the name collision issues and typing issues with
	namerefs, improve various issues for function libraries
To: tetsujin@scope-eye.net, Greg Wooledge <wooledg@eeg.ccf.org>,
	bug-bash <bug-bash@gnu.org>
References: <5fcd830c0f2f59c4d4280a6263fbecfd3df6638b@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <52e8a3b5-9f09-f5f9-970f-f843c578fb43@case.edu>
Date: Mon, 19 Jun 2017 09:17:52 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <5fcd830c0f2f59c4d4280a6263fbecfd3df6638b@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.19.120916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NO_NAME,
	__TO_NAME, __TO_NAME_DIFF_FROM_ACC, __REFERENCES,
	__HAS_FROM, FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID,
	DATE_TZ_NA, __USER_AGENT, __MOZILLA_USER_AGENT,
	__MIME_VERSION, __IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_400_LESS,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_300_399,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 13:18:06 -0000

On 6/19/17 9:12 AM, tetsujin@scope-eye.net wrote:
> 
> 
> As a bonus you'd be able to lure the uninitiated into asking questions
> like "What's upvar?"

The same old, what's up with you?

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 19 09:22:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMwdt-0003l3-8y
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 09:22:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53178)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMwdq-0003ku-MN
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:22:55 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMwdl-0008Dx-Pa
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:22:54 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:39195 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dMwdl-0008D4-J0
	for bug-bash@gnu.org; Mon, 19 Jun 2017 09:22:49 -0400
Received: (qmail 63461 invoked from network); 19 Jun 2017 13:22:48 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Mon, 19 Jun 2017 09:22:48 -0400
Received: (qmail 4045 invoked by uid 563); 19 Jun 2017 13:22:47 -0000
Date: Mon, 19 Jun 2017 09:22:47 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
Message-ID: <20170619132247.GS22519@eeg.ccf.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5947344A.7020805@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 13:22:55 -0000

On Sun, Jun 18, 2017 at 07:17:46PM -0700, L A Walsh wrote:
> Oh?  I want to read in a value from the registry where something may 
> have zeros
> after the data.  Please tell me the mechanism to read this in w/no warnings
> that won't silence more serious cases of zero's other than at the end of 
> line.

IFS= read -rd '' regvalue < <(regcommand)

This will read the content from the stream provided by regcommand, up
to the first NUL, where it will stop.  This is the general method used
to read a NUL-delimited value from a command or pseudo-file.  A command
substitution is NOT preferred, because it converts the stream to a
string (by dropping all NUL bytes, including those that are in between
two separate values).

An analogous common use-case on Linux:

wooledg:~$ hd /proc/$$/cmdline
00000000  62 61 73 68 00                                    |bash.|
00000005
wooledg:~$ IFS= read -rd '' foo < /proc/$$/cmdline
wooledg:~$ declare -p foo
declare -- foo="bash"

If your regcommand produces a stream with multiple items in it, like
this:

foo\0bar\0quux\0

Then the IFS= read -rd '' regvalue command will read "foo" (the first
value) and stop, whereas a command substitution will give you the string
"foobarquux" which is nonsense.  (And in bash 4.4, you also get a
warning, because doing that is bad.  You should stop doing that.)

Now, most of us on this mailing list do not use Microsoft Windows, and
do not know what commands you are using, or what output they produce.
So, if you want any more specific advice, you'll have to go back a step
and explain what you're doing, what input you're dealing with, and what
results you expect to achieve.

It also helps if you use standard bash commands, and not your
idiosyncratic aliases like "my" and "int".  Some of us may remember
that you do things like alias my=declare, but others will not.  When
reporting a bug, you want your report to be easily understandable and
reproducible, without external references or guessing.


From MAILER-DAEMON Mon Jun 19 10:08:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMxM8-0005uG-Pu
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 10:08:40 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35948)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMxM6-0005sw-Ik
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:08:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMxM1-0000ZO-Cb
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:08:38 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:34931
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMxM1-0000YY-6Y
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:08:33 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AML12268; Mon, 19 Jun 2017 10:08:31 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGC78288 (AUTH cpr);
	Mon, 19 Jun 2017 10:08:30 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Read builtin -e (readline) oddities
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170619013908.x6gqolm7nv7noxmx@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <cb77236a-8560-0bd1-e416-9d8ff15b091b@case.edu>
Date: Mon, 19 Jun 2017 10:08:30 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170619013908.x6gqolm7nv7noxmx@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.19.134816:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_700_799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 14:08:39 -0000

On 6/18/17 9:39 PM, Eduardo A. Bustamante López wrote:
> I'm trying to figure out a way to fuzz >>read -e -d ""<<, without having the
> fuzzer break due to the temporary files created by fc.
> 
> While doing this, I noticed the oddities described below.
> 
> 
> #1
> Hit `C-x C-e' twice.  The value of PATH seems to be ignored for the second
> line.

I can't reproduce this.  I suspect one of your startup files is somehow
being read and setting PATH. It may also be an interaction with the
command-not-found hook.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 19 10:58:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMy83-00007z-Ca
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 10:58:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48988)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMy7z-00006K-QO
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:58:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMy7v-0002lP-RJ
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:58:07 -0400
Received: from mail-ot0-x236.google.com ([2607:f8b0:4003:c0f::236]:35854)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dMy7v-0002lA-I4
	for bug-bash@gnu.org; Mon, 19 Jun 2017 10:58:03 -0400
Received: by mail-ot0-x236.google.com with SMTP id s7so69814918otb.3
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 07:58:03 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=hsdnX1Z1L5Ym5Dq2WQDlVrlkajVqZgA9yHLAeTK+DKI=;
	b=JNwqa0ZuQjp968TL8fGOiNVgolVJBmcHXa5y0M2MtXPLh5mpuJaVQD/IJPMOp93rau
	XNO2/qO6bbWhV3BTG4B1aBnnaHr/M1rmjd/qk6xwV42CLLIUNoxMcCdKw0iE/IIJ379C
	ri0lMVs2n9kvlldL48oaK+C3VtnnUzvzTmIqTlzhljhfA3ud7xNdhUDyqcBPe7Pqq6l4
	OkuAZ21wR60zlMblXa5R/mqGfM0qJbDnpLF2AsH72umXCQNN/9phVhiZ8KBdX+M2nmtZ
	fMClXbBOZN0uAXYdPmvADbn9fLCyC22oIu1eARw4SCwcqmfZlnFuCZHemnxLDyNZ+EN3
	x2Mg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=hsdnX1Z1L5Ym5Dq2WQDlVrlkajVqZgA9yHLAeTK+DKI=;
	b=hcsno0egY9sJtJWVrtobCAicxk/BHD4vHw7yW7jbeg6ULtFhDPJ3ze2YV11PbX/FQJ
	rzTSFqsq4X8OoLExxJfhKIGvk7lSzGE8Oal7duwOVpEckZQW2QQsVWU6CaDwT+FNFr5g
	UmSlja4mAPr3jjz4OqqV0CFX9wXACQj7mJbBtBt2A4lbmQ128PEy03oblCITFI/fGAoU
	haoZY2Yz5R7k3jiexsRTDHOaKBJbT065LJ6DutuoSDKp1vPJNKObC+kdIf4PkwdAYkl3
	ri+ba4o5EnH+murMczOvIrzevizj5XFOpgfLVoK+uDs8yGQr4GTV8Ir4DoE9Gavyq61N
	g5zQ==
X-Gm-Message-State: AKS2vOxy+2QSF5gEUpgqpdhebFjKY9LCquol+DN4/cs7q9JjhvPMmINN
	3OsgElj6kgDU1g==
X-Received: by 10.157.36.233 with SMTP id z96mr14180000ota.9.1497884282525;
	Mon, 19 Jun 2017 07:58:02 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	p38sm5895146otd.26.2017.06.19.07.58.01
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 19 Jun 2017 07:58:01 -0700 (PDT)
Date: Mon, 19 Jun 2017 09:57:55 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: Read builtin -e (readline) oddities
Message-ID: <20170619145755.2ltiig2xdto2f5hg@debian>
References: <20170619013908.x6gqolm7nv7noxmx@debian>
	<cb77236a-8560-0bd1-e416-9d8ff15b091b@case.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <cb77236a-8560-0bd1-e416-9d8ff15b091b@case.edu>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 14:58:09 -0000

On Mon, Jun 19, 2017 at 10:08:30AM -0400, Chet Ramey wrote:
[...]
> I can't reproduce this.  I suspect one of your startup files is somehow
> being read and setting PATH. It may also be an interaction with the
> command-not-found hook.

Hm, I can still reproduce it under Debian 9, using the `devel' branch, and I'm
sure no startup files are being sourced.

  dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash --norc --noprofile
  bash-4.4$ declare -p command-not-found
  bash: declare: command-not-found: not found
  bash-4.4$ 
  GNU bash, version 4.4.12(3)-maint (x86_64-unknown-linux-gnu)
  bash-4.4$ PATH= read -e
  
  bash: vim: No such file or directory
  
  echo this is vim
  this is vim

I then patched bash like this:

  dualbus@debian:~/src/gnu/bash$ git diff -- execute_cmd.c
  diff --git a/execute_cmd.c b/execute_cmd.c
  index 0183a105..50f4e2f0 100644
  --- a/execute_cmd.c
  +++ b/execute_cmd.c
  @@ -5550,6 +5550,7 @@ shell_execve (command, args, env)
     char sample[HASH_BANG_BUFSIZ];
     int sample_len;
   
  +  if (strlen(get_string_value ("PATH")) > 0) abort();
     SETOSTYPE (0);               /* Some systems use for USG/POSIX semantics */
     execve (command, args, env);
     i = errno;                   /* error from execve() */

And I got (the first `\C-x \C-e' gets to shell_execve, but PATH is empty):

  dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash --norc --noprofile
  bash-4.4$ ulimit -c unlimited
  bash-4.4$ 
  GNU bash, version 4.4.12(9)-maint (x86_64-unknown-linux-gnu)
  bash-4.4$ PATH= read -e
  
  bash: vim: No such file or directory
  
  Aborted (core dumped)
  
  Core was generated by `./bash --norc --noprofile'.
  Program terminated with signal SIGABRT, Aborted.
  #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
  51      ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
  (gdb) bt
  #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
  #1  0x00007f30b14c93fa in __GI_abort () at abort.c:89
  #2  0x000055a0df6527c4 in shell_execve (command=0x55a0e0a21020 "/usr/bin/vim", args=0x55a0e0a64610, env=0x55a0e0a207f0) at ../../bash/execute_cmd.c:5553
  #3  0x000055a0df6525b1 in execute_disk_command (words=0x55a0e0a63c20, redirects=0x0, command_line=0x55a0e0a20f60 "vim /tmp/bash-fc.HTeaRz", pipe_in=-1, pipe_out=-1, async=0, 
      fds_to_close=0x55a0e0a42d80, cmdflags=0) at ../../bash/execute_cmd.c:5348
  #4  0x000055a0df650d4f in execute_simple_command (simple_command=0x55a0e0a62780, pipe_in=-1, pipe_out=-1, async=0, fds_to_close=0x55a0e0a42d80) at ../../bash/execute_cmd.c:4466
  #5  0x000055a0df64a465 in execute_command_internal (command=0x55a0e0a20e80, asynchronous=0, pipe_in=-1, pipe_out=-1, fds_to_close=0x55a0e0a42d80) at ../../bash/execute_cmd.c:811
  #6  0x000055a0df6ad6a8 in parse_and_execute (string=0x55a0e0a61b10 "vim /tmp/bash-fc.HTeaRz", from_file=0x55a0df71cecd "fc", flags=4) at ../../../bash/builtins/evalstring.c:430
  #7  0x000055a0df6aee93 in fc_builtin (list=0x0) at ../../../bash/builtins/../../../bash/builtins/fc.def:438
  #8  0x000055a0df6511cb in execute_builtin (builtin=0x55a0df6ae4ae <fc_builtin>, words=0x55a0e0a625d0, flags=0, subshell=0) at ../../bash/execute_cmd.c:4609
  #9  0x000055a0df6520a7 in execute_builtin_or_function (words=0x55a0e0a625d0, builtin=0x55a0df6ae4ae <fc_builtin>, var=0x0, redirects=0x0, fds_to_close=0x55a0e0a63df0, flags=0)
      at ../../bash/execute_cmd.c:5107
  #10 0x000055a0df650ad1 in execute_simple_command (simple_command=0x55a0e0a62540, pipe_in=-1, pipe_out=-1, async=0, fds_to_close=0x55a0e0a63df0) at ../../bash/execute_cmd.c:4395
  #11 0x000055a0df64a465 in execute_command_internal (command=0x55a0e0a20400, asynchronous=0, pipe_in=-1, pipe_out=-1, fds_to_close=0x55a0e0a63df0) at ../../bash/execute_cmd.c:811
  #12 0x000055a0df6ad6a8 in parse_and_execute (string=0x55a0e0a613b0 "fc -e \"${VISUAL:-${EDITOR:-emacs}}\"", from_file=0x55a0df70ccd5 "C-xC-e", flags=4)
      at ../../../bash/builtins/evalstring.c:430
  #13 0x000055a0df696203 in edit_and_execute_command (count=1, c=5, editing_mode=1, edit_command=0x55a0df70cd10 "fc -e \"${VISUAL:-${EDITOR:-emacs}}\"") at ../../bash/bashline.c:977
  #14 0x000055a0df6962f0 in emacs_edit_and_execute_command (count=1, c=5) at ../../bash/bashline.c:1013
  #15 0x000055a0df6dccd5 in _rl_dispatch_subseq (key=5, map=0x55a0df9461a0 <emacs_ctlx_keymap>, got_subseq=0) at ../../../../bash/lib/readline/readline.c:851
  #16 0x000055a0df6dd19a in _rl_dispatch_subseq (key=24, map=0x55a0df944160 <emacs_standard_keymap>, got_subseq=0) at ../../../../bash/lib/readline/readline.c:985
  #17 0x000055a0df6dca4c in _rl_dispatch (key=-1320386609, map=0x55a0df944160 <emacs_standard_keymap>) at ../../../../bash/lib/readline/readline.c:797
  #18 0x000055a0df6dc6d4 in readline_internal_char () at ../../../../bash/lib/readline/readline.c:629
  #19 0x000055a0df6dc72c in readline_internal_charloop () at ../../../../bash/lib/readline/readline.c:656
  #20 0x000055a0df6dc750 in readline_internal () at ../../../../bash/lib/readline/readline.c:670
  #21 0x000055a0df6dc16d in readline (prompt=0x55a0df71d63c "") at ../../../../bash/lib/readline/readline.c:374
  #22 0x000055a0df6b6407 in edit_line (p=0x55a0df71d63c "", itext=0x0) at ../../../bash/builtins/../../../bash/builtins/read.def:1095
  #23 0x000055a0df6b5243 in read_builtin (list=0x0) at ../../../bash/builtins/../../../bash/builtins/read.def:559
  #24 0x000055a0df6511cb in execute_builtin (builtin=0x55a0df6b44f9 <read_builtin>, words=0x55a0e0a60ed0, flags=0, subshell=0) at ../../bash/execute_cmd.c:4609
  #25 0x000055a0df6520a7 in execute_builtin_or_function (words=0x55a0e0a60ed0, builtin=0x55a0df6b44f9 <read_builtin>, var=0x0, redirects=0x0, fds_to_close=0x55a0e0a61070, flags=0)
      at ../../bash/execute_cmd.c:5107
  #26 0x000055a0df650ad1 in execute_simple_command (simple_command=0x55a0e0a60df0, pipe_in=-1, pipe_out=-1, async=0, fds_to_close=0x55a0e0a61070) at ../../bash/execute_cmd.c:4395
  #27 0x000055a0df64a465 in execute_command_internal (command=0x55a0e0a42ba0, asynchronous=0, pipe_in=-1, pipe_out=-1, fds_to_close=0x55a0e0a61070) at ../../bash/execute_cmd.c:811
  #28 0x000055a0df6499c1 in execute_command (command=0x55a0e0a42ba0) at ../../bash/execute_cmd.c:393
  #29 0x000055a0df633a2a in reader_loop () at ../../bash/eval.c:172
  #30 0x000055a0df631677 in main (argc=3, argv=0x7fff33cecb28, env=0x7fff33cecb48) at ../../bash/shell.c:794

  (gdb) frame
  #2  0x000055a0df6527c4 in shell_execve (command=0x55a0e0a21020 "/usr/bin/vim", args=0x55a0e0a64610, env=0x55a0e0a207f0) at ../../bash/execute_cmd.c:5553
  5553      if (strlen(get_string_value ("PATH")) > 0) abort();
  (gdb) p env[30]
  $15 = 0x55a0e0a21140 "PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"
  (gdb) p env[5]
  $16 = 0x55a0e0a61460 "EDITOR=vim"


This works fine though:

  dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash --norc --noprofile
  bash-4.4$ export PATH=
  bash-4.4$ read -e
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  ^C

So it seems that the problem is that the tempenv is reset for the second
execution of the `fc' builtin.



And in the case of getting the extra `;'s in the history, it would seem it adds
one per failed execve:

  bash-4.4$ history -c
  bash-4.4$ export PATH=
  bash-4.4$ read -e
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  
  bash: vim: No such file or directory
  bash-4.4$ history
      1  export PATH=
      2  read -e; ; ; ; ; 
      3  history

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 19 11:03:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMyCp-0002oO-UR
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 11:03:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50934)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMyCo-0002nM-4B
	for bug-bash@gnu.org; Mon, 19 Jun 2017 11:03:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dMyCn-0005MY-Dg
	for bug-bash@gnu.org; Mon, 19 Jun 2017 11:03:06 -0400
Received: from mail-qk0-x236.google.com ([2607:f8b0:400d:c09::236]:34587)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dMyCn-0005ME-9P
	for bug-bash@gnu.org; Mon, 19 Jun 2017 11:03:05 -0400
Received: by mail-qk0-x236.google.com with SMTP id d14so35525181qkb.1
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 08:03:05 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc:content-transfer-encoding;
	bh=0N85989W0xexEvQjqikMaztFFTP8ejrPx9kQ5Dx7jY0=;
	b=a7sEIa1G7rTShpLvtFeW4hcMNPju4ut0d9OsFnTc3oKzNBySTnn4ChgaFWjUjpdeIp
	OZ5WBOMZ2SemhmiqoEQEWz5inMvIARToUc/J7QTM7bF3ko7Wei1fDifDwSveRn4lrSPO
	+altjm7YZOoPYuHPKiSBeMW0/CQJWTIc5gtOfRVp1wUQbtlDDlDqbB3F7xjwVEY2H7Tw
	IeO69ramaooGewRGP6+PL2akf66V47sZQifxIl8/fRQSvaINdFKZArdPLGOuU6l8CsWQ
	b9RipvD4wLVz8Gc6MCzjkzK/WG84pMab5uDrF4D3wUIdhXEAkYYxqwGCl6fKdho3L6mZ
	plgQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc:content-transfer-encoding;
	bh=0N85989W0xexEvQjqikMaztFFTP8ejrPx9kQ5Dx7jY0=;
	b=A+WushetlH5jnhwPWndcq0CJLwYjePgr3wMOd8/qPuHYDMQMyf7/aQ3X0Pb3r9F4fK
	ILrIaHsPZEACE5A+oBpD1QHa/ekUAYCiBNgTpA5x+F5N2CA40D5024ygjqdgbUSy4Cl3
	bIOEveR5QiLv+kt15EsbFM5H7AUKoHy5eKlEHkRspEhs8XOkh0mfKMejlBddGnsq69L7
	pLBcTkEsLWfgq7nlVxLq++w00ZtJrztSCt5Gubf0JdzumhHW6/9KikaHcQqrLygwl7of
	AHCfY9Dyp+RrxAPhUUetf0wOWjsSlUOZlFOMdU3x+NiaPupzVhalmXgfyDrqV5XxEE40
	ay3A==
X-Gm-Message-State: AKS2vOz8LoH8S3P2JKSbCfO+FEEphMHUx6RZ1oBgPdnG+ePnwvvP2Kid
	+54FTQaZJO/GtWVB3nQEu3uGdNCpig==
X-Received: by 10.55.17.209 with SMTP id 78mr20248413qkr.44.1497884584445;
	Mon, 19 Jun 2017 08:03:04 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Mon, 19 Jun 2017 08:02:43 -0700 (PDT)
In-Reply-To: <20170619145755.2ltiig2xdto2f5hg@debian>
References: <20170619013908.x6gqolm7nv7noxmx@debian>
	<cb77236a-8560-0bd1-e416-9d8ff15b091b@case.edu>
	<20170619145755.2ltiig2xdto2f5hg@debian>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Mon, 19 Jun 2017 10:02:43 -0500
Message-ID: <CAOSMAusdUzdq1fhqtxN5wDu3UDGFixnuU08XUg7zjUujKajfsA@mail.gmail.com>
Subject: Re: Read builtin -e (readline) oddities
To: Chet Ramey <chet.ramey@case.edu>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::236
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 15:03:07 -0000

On Mon, Jun 19, 2017 at 9:57 AM, Eduardo A. Bustamante L=C3=B3pez
<dualbus@gmail.com> wrote:
[...]
> Hm, I can still reproduce it under Debian 9, using the `devel' branch, an=
d I'm
> sure no startup files are being sourced.
>
>   dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash --norc --noprofile
>   bash-4.4$ declare -p command-not-found
>   bash: declare: command-not-found: not found

Heh, actually:

dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash --norc --noprofile
bash-4.4$ declare -fp command_not_found_handle
bash: declare: command_not_found_handle: not found

The rest is correct though.


From MAILER-DAEMON Mon Jun 19 12:06:09 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dMzBp-0002uj-Qx
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 12:06:09 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43457)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMzBn-0002rN-VR
	for bug-bash@gnu.org; Mon, 19 Jun 2017 12:06:08 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dMzBl-0007V1-8F
	for bug-bash@gnu.org; Mon, 19 Jun 2017 12:06:07 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:21885
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dMzBl-0007UL-2K
	for bug-bash@gnu.org; Mon, 19 Jun 2017 12:06:05 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANQ22261; Mon, 19 Jun 2017 12:06:03 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFU50948 (AUTH cpr);
	Mon, 19 Jun 2017 12:06:02 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Read builtin -e (readline) oddities
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170619013908.x6gqolm7nv7noxmx@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <044d2592-6c4b-e26e-f43e-0e0522918d60@case.edu>
Date: Mon, 19 Jun 2017 12:06:02 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170619013908.x6gqolm7nv7noxmx@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.19.150916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODY_SIZE_700_799, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 16:06:09 -0000

On 6/18/17 9:39 PM, Eduardo A. Bustamante López wrote:

> #1
> Hit `C-x C-e' twice.  The value of PATH seems to be ignored for the second
> line.

The shell should ensure that the temporary env is preserved across the
entire execution of any builtin that can call parse_and_execute (like `fc'
and `read' when using `read -e').

> #2
> Spurious `;'s are inserted into the history.

The fc builtin (via edit_and_execute_command) shouldn't try to insert empty
lines into the history list.  The only time this can happen is via
`read -e'.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 19 15:40:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN2X9-0003rk-Oq
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 15:40:23 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58747)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dN2X7-0003qk-P6
	for bug-bash@gnu.org; Mon, 19 Jun 2017 15:40:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dN2X3-0003ia-Rc
	for bug-bash@gnu.org; Mon, 19 Jun 2017 15:40:21 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:2564
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dN2X3-0003hw-LA
	for bug-bash@gnu.org; Mon, 19 Jun 2017 15:40:17 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANL31930; Mon, 19 Jun 2017 15:40:15 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGD35608 (AUTH cpr);
	Mon, 19 Jun 2017 15:40:15 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Read builtin -e (readline) oddities
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170619013908.x6gqolm7nv7noxmx@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <ce73f959-d1bd-0c39-b9b2-82cc7d5c6d11@case.edu>
Date: Mon, 19 Jun 2017 15:40:14 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170619013908.x6gqolm7nv7noxmx@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.19.191216:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1600_1699, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 19:40:22 -0000

On 6/18/17 9:39 PM, Eduardo A. Bustamante López wrote:
> I'm trying to figure out a way to fuzz >>read -e -d ""<<, without having the
> fuzzer break due to the temporary files created by fc.
> 
> While doing this, I noticed the oddities described below.
> 
> 
> #1
> Hit `C-x C-e' twice.  The value of PATH seems to be ignored for the second
> line.
> 
>   dualbus@debian:~$ PATH= read -e
>   
>   bash: vim: No such file or directory
>   
>   echo hi
>   hi
> 
> 
> #2
> Spurious `;'s are inserted into the history.
> 
>   dualbus@debian:~$ history -c
>   dualbus@debian:~$ PATH= read -e
>   
>   bash: vim: No such file or directory
>   
>   echo hi
>   hi
>   
>   dualbus@debian:~$ history
>       1  PATH= read -e; ; 
>       2  echo hi
>       3  history
> 
> 
> #3
> Hit `C-x C-e' thrice. Also, the mapping of `\C-m' became `self-insert' instead
> of `accept-line'.

`read -e' changes it because it's no longer the line delimiter.

>   dualbus@debian:~$ PATH= EDITOR=: read -e -d ''
>   
>   PATH= EDITOR=: read -e -d ''; 
>   
>   fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
>   : /tmp/bash-fc.IZAzmF
>   PATH= EDITOR=: read -e -d ''; ; 
>   bash: syntax error near unexpected token `;'
>   
>   fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
>   vim /tmp/bash-fc.35ePED
>   ^M^M^C

I'll have to check why it doesn't get restored on ^C.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 19 21:18:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN7oO-000314-AR
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 21:18:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47716)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dN7oM-00030n-3c
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:18:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <gazelle@xmission.com>) id 1dN7oH-0003tT-7F
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:18:30 -0400
Received: from out01.mta.xmission.com ([166.70.13.231]:35458)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <gazelle@xmission.com>)
	id 1dN7oH-0003ju-1U
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:18:25 -0400
Received: from mx02.mta.xmission.com ([166.70.13.212])
	by out01.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>) id 1dN7o3-0004k5-MH
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:18:11 -0600
Received: from shell.xmission.com ([166.70.8.4])
	by mx02.mta.xmission.com with esmtps
	(TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.87)
	(envelope-from <gazelle@xmission.com>) id 1dN7o3-0003HS-Ho
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:18:11 -0600
Received: from gazelle by shell.xmission.com with local (Exim 4.86_2)
	(envelope-from <gazelle@xmission.com>) id 1dN7o3-00089U-Bp
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:18:11 -0600
From: gazelle@xmission.com
To: bug-bash@gnu.org
Subject: "realpath" loadable (in the examples/loadables dir) infinite loops
Message-Id: <E1dN7o3-00089U-Bp@shell.xmission.com>
Date: Mon, 19 Jun 2017 19:18:11 -0600
X-XM-SPF: eid=1dN7o3-0003HS-Ho; ; ; mid=<E1dN7o3-00089U-Bp@shell.xmission.com>;
	; ; hst=mx02.mta.xmission.com; ; ; ip=166.70.8.4; ; ;
	frm=gazelle@xmission.com; ; ; spf=neutral
X-SA-Exim-Connect-IP: 166.70.8.4
X-SA-Exim-Mail-From: gazelle@xmission.com
X-SA-Exim-Scanned: No (on mx02.mta.xmission.com);
	SAEximRunCond expanded to false
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 166.70.13.231
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 01:18:31 -0000

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='x86_64-unknown-linux-gnu' -DCONF_VENDOR='unknown' -DLOCALEDIR='/usr/local/share/locale' -DPACKAGE='bash' -DSHELL -DHAVE_CONFIG_H   -I.  -I. -I./include -I./lib   -g -O2 -Wno-parentheses -Wno-format-security
uname output: Linux shell 4.4.0-79-generic #100-Ubuntu SMP Wed May 17 19:58:14 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-unknown-linux-gnu

Bash Version: 4.4
Patch Level: 0
Release Status: release

Description:
	Command "realpath --help" causes infinite loop.

Repeat-By:
	enable -f /usr/local/lib/bash/realpath realpath
	realpath --help

	causes infinite loop of:

realpath: usage: realpath [-csv] pathname [pathname...]
realpath: usage: realpath [-csv] pathname [pathname...]
realpath: usage: realpath [-csv] pathname [pathname...]
realpath: usage: realpath [-csv] pathname [pathname...]
realpath: usage: realpath [-csv] pathname [pathname...]
realpath: usage: realpath [-csv] pathname [pathname...]

	until the shell is killed by signal 9 from another terminal.



From MAILER-DAEMON Mon Jun 19 21:49:01 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN8Ht-000333-7L
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 21:49:01 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56184)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dN688-0003MT-Fj
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:30:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dN685-0006Di-9O
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:30:48 -0400
Received: from mail-ot0-x22e.google.com ([2607:f8b0:4003:c0f::22e]:35355)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <zartaj@gmail.com>) id 1dN684-0006Dc-WC
	for bug-bash@gnu.org; Mon, 19 Jun 2017 19:30:45 -0400
Received: by mail-ot0-x22e.google.com with SMTP id u13so64368081otd.2
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 16:30:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:from:date:message-id:subject:to;
	bh=yZImug6ct7pUUgxgsszez9iR/OZfwSOkbOX6lOfaL/4=;
	b=WFDd4IUI5ccA8qADwBYo3eQUix9WiiHq/tlAeg5t9O27O/55un4R/m/6JYB+eAwbap
	uy4MLdof4hqt7lvpiv+dRCiP/9c4yhNmQkoCDLXb5mOxOkpErvOhPao/puEA8T7piJ7A
	7DwJ4mwpMiy0WAhstb/ew4mtU8hnd4zaXxiM/XrG4HUtVy+Mg/ebjdJCaPQLLzgMSYOp
	so2s3vENKe1o8ubMJ4xdlmW49RCO4cg56VTPJsYf4NdSGJh9HZ0nezZwpnOXCZO5vFCS
	0nJSKyIx3OYFMO/VuWebgN6+h5/mbKzQej7vkTm8ImU3I2SZVdtVr1SuX+9qVEuoC25V
	yRzg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
	bh=yZImug6ct7pUUgxgsszez9iR/OZfwSOkbOX6lOfaL/4=;
	b=IVCfbUFtr8beh+DmVmgp3F9WLgCXg2TWfLAL6CXGy1uJIZwMImfSSuwH0uiGMrpR6J
	r0KtiBlVOR3USDDfKfuRiKtWMUk5ufD9y6GDZRHS2/8qpzS8JJLDI3bK6Kvws9KzMvyB
	HmLI60aZkHoA57YMx5CbPjMHpW4NNmUrZ356v36bxxD46rSU25PvVu7H7HoGlc3iB/0i
	9cT6UHq8+s09r+vBWgZrBtGL/QCnqTKrNirqaDxeaNsapduy/fI8zaA450OKpmr3Lles
	7xBZRuUpnn75uqO1lipm7ow4TB7jKGevTZiWD2JZv3iG0T0TKv0qIuEN7MZ4uYxlVyM/
	Ov3g==
X-Gm-Message-State: AKS2vOxX/za/gkZkHzbjFblJdEeylAjrCmNKCI29WZPK2egZueqUHC4/
	RVyI7hH4l+nkXxXp3YxMD+UliJbBGvf9
X-Received: by 10.157.45.109 with SMTP id v100mr13013933ota.159.1497915043451; 
	Mon, 19 Jun 2017 16:30:43 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.74.39.68 with HTTP; Mon, 19 Jun 2017 16:30:42 -0700 (PDT)
From: Z <zartaj@gmail.com>
Date: Mon, 19 Jun 2017 19:30:42 -0400
Message-ID: <CAEU1kBpKTCYasCyFsQ==PQfs7g8+VBxo71DLTz-z6_rrb+D4Sg@mail.gmail.com>
Subject: [PATCH] Unix domain socket filename redirection
To: bug-bash@gnu.org
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22e
X-Mailman-Approved-At: Mon, 19 Jun 2017 21:48:58 -0400
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 19 Jun 2017 23:30:51 -0000

This patch adds support for Unix domain sockets. A filename of the form
/dev/unixstream/path used in a redirection makes bash attempt to open a
connection to the Unix domain stream socket at /path. Similarly a filename
of the form /dev/unixdgram/path makes bash attempt to open a connection to
the Unix domain datagram socket at /path.

Zartaj Majeed

 Makefile.in              |   2 +-
 config.h.in              |   7 ++++
 configure.ac             |   9 +++-
 externs.h                |   3 ++
 lib/sh/Makefile.in       |   8 +++-
 lib/sh/usockopen.c       | 104
+++++++++++++++++++++++++++++++++++++++++++++++
 redir.c                  |  12 ++++++
 tests/misc/devunix.tests |  18 ++++++++
 8 files changed, 158 insertions(+), 5 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index c7b62bc0..542cede8 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -222,7 +222,7 @@ SHLIB_SOURCE =      ${SH_LIBSRC}/clktck.c
${SH_LIBSRC}/getcwd.c \
                ${SH_LIBSRC}/input_avail.c ${SH_LIBSRC}/mbscasecmp.c \
                ${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c \
                ${SH_LIBSRC}/wcswidth.c ${SH_LIBSRC}/wcsnwidth.c \
-               ${SH_LIBSRC}/shmbchar.c
+               ${SH_LIBSRC}/shmbchar.c ${SH_LIBSRC}/usockopen.c

 SHLIB_LIB = -lsh
 SHLIB_LIBNAME = libsh.a
diff --git a/config.h.in b/config.h.in
index a5ad9e72..36e8f5dd 100644
--- a/config.h.in
+++ b/config.h.in
@@ -151,6 +151,10 @@
    socket connections when used in redirections */
 #undef NETWORK_REDIRECTIONS

+/* Define UNIXSOCK_REDIRECTIONS if you want
/dev/(unixstream|unixdgram)/path to open
+   socket connections when used in redirections */
+#undef UNIXSOCK_REDIRECTIONS
+
 /* Define PROGRAMMABLE_COMPLETION for the programmable completion features
    and the complete builtin. */
 #undef PROGRAMMABLE_COMPLETION
@@ -1042,6 +1046,9 @@
 /* Define if you have the <sys/socket.h> header file.  */
 #undef HAVE_SYS_SOCKET_H

+/* Define if you have the <sys/un.h> header file.  */
+#undef HAVE_SYS_UN_H
+
 /* Define if you have the <sys/stat.h> header file. */
 #undef HAVE_SYS_STAT_H

diff --git a/configure.ac b/configure.ac
index ce4e9b60..a8e9f43c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -168,6 +168,7 @@ opt_cond_regexp=yes
 opt_coproc=yes
 opt_arith_for_command=yes
 opt_net_redirs=yes
+opt_usock_redirs=yes
 opt_progcomp=yes
 opt_separate_help=no
 opt_multibyte=yes
@@ -196,7 +197,7 @@ if test $opt_minimal_config = yes; then
        opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no
        opt_brace_expansion=no opt_disabled_builtins=no
opt_command_timing=no
        opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no
-       opt_net_redirs=no opt_progcomp=no opt_separate_help=no
+       opt_net_redirs=no opt_usock_redirs=no opt_progcomp=no
opt_separate_help=no
        opt_multibyte=yes opt_cond_regexp=no opt_coproc=no
        opt_casemod_attrs=no opt_casemod_expansions=no
opt_extglob_default=no
        opt_globascii_default=no
@@ -227,6 +228,7 @@ AC_ARG_ENABLE(history,
AC_HELP_STRING([--enable-history], [turn on command histo
 AC_ARG_ENABLE(job-control, AC_HELP_STRING([--enable-job-control], [enable
job control features]), opt_job_control=$enableval)
 AC_ARG_ENABLE(multibyte, AC_HELP_STRING([--enable-multibyte], [enable
multibyte characters if OS supports them]), opt_multibyte=$enableval)
 AC_ARG_ENABLE(net-redirections,
AC_HELP_STRING([--enable-net-redirections], [enable /dev/tcp/host/port
redirection]), opt_net_redirs=$enableval)
+AC_ARG_ENABLE(usock-redirections,
AC_HELP_STRING([--enable-usock-redirections], [enable /dev/unixstream/path
redirection]), opt_usock_redirs=$enableval)
 AC_ARG_ENABLE(process-substitution,
AC_HELP_STRING([--enable-process-substitution], [enable process
substitution]), opt_process_subst=$enableval)
 AC_ARG_ENABLE(progcomp, AC_HELP_STRING([--enable-progcomp], [enable
programmable completion and the complete builtin]), opt_progcomp=$enableval)
 AC_ARG_ENABLE(prompt-string-decoding,
AC_HELP_STRING([--enable-prompt-string-decoding], [turn on escape character
decoding in prompts]), opt_prompt_decoding=$enableval)
@@ -321,6 +323,9 @@ fi
 if test $opt_net_redirs = yes; then
 AC_DEFINE(NETWORK_REDIRECTIONS)
 fi
+if test $opt_usock_redirs = yes; then
+AC_DEFINE(UNIXSOCK_REDIRECTIONS)
+fi
 if test $opt_progcomp = yes; then
 AC_DEFINE(PROGRAMMABLE_COMPLETION)
 fi
@@ -702,7 +707,7 @@ AC_CHECK_HEADERS(unistd.h stdlib.h stdarg.h varargs.h
limits.h string.h \
                 stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \
                 regex.h syslog.h ulimit.h)
 AC_CHECK_HEADERS(sys/pte.h sys/stream.h sys/select.h sys/file.h
sys/ioctl.h \
-                sys/param.h sys/socket.h sys/stat.h \
+                sys/param.h sys/socket.h sys/un.h sys/stat.h \
                 sys/time.h sys/times.h sys/types.h sys/wait.h)
 AC_CHECK_HEADERS(netinet/in.h arpa/inet.h)

diff --git a/externs.h b/externs.h
index fa0603d3..1315866c 100644
--- a/externs.h
+++ b/externs.h
@@ -270,6 +270,9 @@ extern int isnetconn __P((int));
 /* declarations for functions defined in lib/sh/netopen.c */
 extern int netopen __P((char *));

+/* declarations for functions defined in lib/sh/usockopen.c */
+extern int usockopen __P((char *));
+
 /* Declarations for  functions defined in lib/sh/oslib.c */

 #if !defined (HAVE_DUP2) || defined (DUP2_BROKEN)
diff --git a/lib/sh/Makefile.in b/lib/sh/Makefile.in
index 2ca921b3..3d357997 100644
--- a/lib/sh/Makefile.in
+++ b/lib/sh/Makefile.in
@@ -84,7 +84,7 @@ LIBRARY_NAME = libsh.a
 CSOURCES = clktck.c clock.c getcwd.c getenv.c oslib.c setlinebuf.c \
           strcasecmp.c strerror.c strtod.c strtol.c strtoul.c \
           vprint.c itos.c rename.c zread.c zwrite.c shtty.c \
-          inet_aton.c netconn.c netopen.c strpbrk.c timeval.c makepath.c \
+          inet_aton.c netconn.c netopen.c usockopen.c strpbrk.c timeval.c
makepath.c \
           pathcanon.c pathphys.c tmpfile.c stringlist.c stringvec.c
spell.c \
           shquote.c strtrans.c strcasestr.c snprintf.c mailstat.c \
           fmtulong.c fmtullong.c fmtumax.c shmatch.c strnlen.c \
@@ -101,7 +101,7 @@ HSOURCES =
 LIBOBJS = @LIBOBJS@
 OBJECTS = clktck.o clock.o getenv.o oslib.o setlinebuf.o strnlen.o \
          itos.o zread.o zwrite.o shtty.o shmatch.o eaccess.o \
-         netconn.o netopen.o timeval.o makepath.o pathcanon.o \
+         netconn.o netopen.o usockopen.o timeval.o makepath.o pathcanon.o \
          pathphys.o tmpfile.o stringlist.o stringvec.o spell.o shquote.o \
          strtrans.o snprintf.o mailstat.o fmtulong.o \
          fmtullong.o fmtumax.o zcatfd.o zmapfd.o winsize.o wcsdup.o \
@@ -166,6 +166,7 @@ memset.o: memset.c
 mktime.o: mktime.c
 netconn.o: netconn.c
 netopen.o: netopen.c
+usockopen.o: usockopen.c
 oslib.o: oslib.c
 pathcanon.o: pathcanon.c
 pathphys.o: pathphys.c
@@ -243,6 +244,7 @@ memset.o: ${BUILD_DIR}/config.h
 mktime.o: ${BUILD_DIR}/config.h
 netconn.o: ${BUILD_DIR}/config.h
 netopen.o: ${BUILD_DIR}/config.h
+usockopen.o: ${BUILD_DIR}/config.h
 oslib.o: ${BUILD_DIR}/config.h
 pathcanon.o: ${BUILD_DIR}/config.h
 pathphys.o: ${BUILD_DIR}/config.h
@@ -341,6 +343,8 @@ netopen.o: ${BUILD_DIR}/pathnames.h ${topdir}/externs.h
 netopen.o: ${topdir}/bashintl.h ${LIBINTL_H} $(BASHINCDIR)/gettext.h
 #netopen.o: ${BUILD_DIR}/version.h

+usockopen.o: ${topdir}/bashansi.h ${topdir}/bashintl.h
+
 oslib.o: ${topdir}/bashtypes.h ${topdir}/bashansi.h ${BASHINCDIR}/maxpath.h
 oslib.o: ${topdir}/shell.h ${topdir}/syntax.h ${topdir}/bashjmp.h
${BASHINCDIR}/posixjmp.h
 oslib.o: ${topdir}/command.h ${BASHINCDIR}/stdc.h ${topdir}/error.h
diff --git a/lib/sh/usockopen.c b/lib/sh/usockopen.c
new file mode 100644
index 00000000..7575003c
--- /dev/null
+++ b/lib/sh/usockopen.c
@@ -0,0 +1,104 @@
+/*
+ * usockopen.c -- functions to make unix domain socket connections
+ *
+ * Zartaj T. Majeed
+ */
+
+/* Copyright (C) 1987-2017 Free Software Foundation, Inc.
+
+   This file is part of GNU Bash, the Bourne Again SHell.
+
+   Bash is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   Bash is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with Bash.  If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#include <config.h>
+
+#if defined (HAVE_UNISTD_H)
+#  include <unistd.h>
+#endif
+
+#include <stdio.h>
+#include <sys/types.h>
+
+#if defined (HAVE_SYS_SOCKET_H)
+#  include <sys/socket.h>
+#endif
+
+#if defined (HAVE_SYS_UN_H)
+#  include <sys/un.h>
+#endif
+
+#include <bashansi.h>
+#include <bashintl.h>
+
+#include <errno.h>
+
+#ifndef errno
+extern int errno;
+#endif
+
+static int _usockopen __P((char *, int));
+
+/*
+ * Open Unix domain socket connection
+ * Returns the connected socket or -1 on error.
+ */
+static int
+_usockopen (path, typ)
+     char *path;
+     int typ;
+{
+  int s, e;
+  struct sockaddr_un addr;
+  int gerr;
+  int socktyp = typ == 's'? SOCK_STREAM: SOCK_DGRAM;
+
+  if ((s = socket (AF_UNIX, socktyp, 0)) < 0)
+       {
+         sys_error ("unix socket");
+         return -1;
+       }
+
+  memset (&addr, 0, sizeof addr);
+  addr.sun_family = AF_UNIX;
+  strncpy (addr.sun_path, path, sizeof(addr.sun_path) - 1);
+
+  if (connect (s, &addr, sizeof addr) < 0)
+       {
+         e = errno;
+         sys_error ("unix connect");
+         close (s);
+         errno = e;
+         return -1;
+       }
+  return s;
+}
+
+/*
+ * Open Unix domain socket connection to a path like
/dev/unixstream/tmp/xyz.sock or /dev/unixdgram/tmp/xyz.sock
+ * Returns the connected socket or -1 on error.
+ */
+int
+usockopen (path)
+     char *path;
+{
+  char *s;
+  int fd;
+
+  s = strchr (path+9, '/');
+  fd = _usockopen (s, path[9]);
+
+  return fd;
+}
+
diff --git a/redir.c b/redir.c
index 25488eaf..e026cc12 100644
--- a/redir.c
+++ b/redir.c
@@ -519,6 +519,8 @@ here_document_to_fd (redirectee, ri)
 #define RF_DEVSTDOUT   4
 #define RF_DEVTCP      5
 #define RF_DEVUDP      6
+#define RF_DEVUSTRM    7
+#define RF_DEVUDGRM    8

 /* A list of pattern/value pairs for filenames that the redirection
    code handles specially. */
@@ -535,6 +537,10 @@ static STRING_INT_ALIST _redir_special_filenames[] = {
   { "/dev/tcp/*/*", RF_DEVTCP },
   { "/dev/udp/*/*", RF_DEVUDP },
 #endif
+#if defined (UNIXSOCK_REDIRECTIONS)
+  { "/dev/unixstream/*", RF_DEVUSTRM },
+  { "/dev/unixdgram/*", RF_DEVUDGRM },
+#endif
   { (char *)NULL, -1 }
 };

@@ -588,6 +594,12 @@ redir_special_open (spec, filename, flags, mode, ri)
 #endif
       break;
 #endif /* NETWORK_REDIRECTIONS */
+
+#if defined (UNIXSOCK_REDIRECTIONS)
+    case RF_DEVUSTRM:
+    case RF_DEVUDGRM:
+      fd = usockopen (filename);
+#endif /* UNIXSOCK_REDIRECTIONS */
     }

   return fd;
diff --git a/tests/misc/devunix.tests b/tests/misc/devunix.tests
new file mode 100644
index 00000000..457a40f0
--- /dev/null
+++ b/tests/misc/devunix.tests
@@ -0,0 +1,18 @@
+sock=/tmp/devunixtest.sock
+out=/tmp/devunixtest.out
+s=abcd.$$
+
+nc -U -l $sock >$out&
+sleep 1
+exec 9>/dev/unixstream$sock
+
+echo "$s" >&9
+exec 9>&-
+
+read t <$out
+
+if [[ $s != $t ]]; then
+  echo "out \"$s\" in \"$t\""
+fi
+
+rm $sock $out

From MAILER-DAEMON Mon Jun 19 21:49:01 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN8Ht-00033B-EP
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 21:49:01 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36071)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dN6nD-0003dD-GT
	for bug-bash@gnu.org; Mon, 19 Jun 2017 20:13:16 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dN6n8-0005OR-I7
	for bug-bash@gnu.org; Mon, 19 Jun 2017 20:13:15 -0400
Received: from mail-wr0-x229.google.com ([2a00:1450:400c:c0c::229]:35478)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <corax26@gmail.com>) id 1dN6n8-0005O4-Bk
	for bug-bash@gnu.org; Mon, 19 Jun 2017 20:13:10 -0400
Received: by mail-wr0-x229.google.com with SMTP id y25so43524808wrd.2
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 17:13:10 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=from:subject:to:message-id:date:user-agent:mime-version
	:content-transfer-encoding:content-language;
	bh=Ctr36qBif1w4sFu3Y4Po1Zj4pVqSC4L13VTi64a1jMw=;
	b=NRFVunzlahO0y2y4su+KsIZSyhRq9XgWCT9RjjyXeEoitpHuaDp4vgF1jtKEoEj8U0
	+nHUc1BNP/Qk3YwN5TC0Nu569Lvc8FqY9lE3VzRtQNe95KMotwZABoC1E/cgnyaKToXY
	4iAqFzkrWPBvL2kuGMfmDUCBKKvAelHosDZh4rCtJda1BDvaZzTFJChmOxYlm+Yr/qc/
	dvIGJiHy/miFHzESDuXLhfBL8wEpLccQEpXYIiOnlF20bggr3YCFUUoo3322Hm+aNaVZ
	Mn/oFrt8rB7zhZU5/8x4t/su59D6pCkJD0yM+jvxAtAnzh74bnw3G2HSBqSokdkk9sE1
	KNcQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:from:subject:to:message-id:date:user-agent
	:mime-version:content-transfer-encoding:content-language;
	bh=Ctr36qBif1w4sFu3Y4Po1Zj4pVqSC4L13VTi64a1jMw=;
	b=CxT7HXBfhKh/lpIz9Mw2k08yDq0YuudcSve9Zz36y4AavtXqa4MjndJTAHiH/lQODa
	aRFbRHzZxqzsEPERVSpJIt2flCDi2OnvFDXRWqT/vj44s6mukMk6Ze+r2wXjd4ipFOi1
	T6lIV1n0f32VXTlRYA0LuSeILCy2U8EayEBz50IgGzLhlEYUmfZdaCmbMwpnNhOyZqWl
	PM4NuAi2ki4LXEHQsxnMhGxjDSyBtGWmoqK7m/IvDrYZcEBDXXUlSWqN11LC/gOTTQG9
	cYT/VodOOtt+Z73KXq3GfAQO56Cf7xNFjL6OQeBFcWHERlbneBP/9TsOUNPo+4USSbiv
	sRcw==
X-Gm-Message-State: AKS2vOyUS0/E12fSr8nOouSOjgEFQO77w9ZcVZjYBbyZd+513O3UG2fY
	pc5hwlPV4GRMSUUj
X-Received: by 10.223.148.97 with SMTP id 88mr16742555wrq.137.1497917588904;
	Mon, 19 Jun 2017 17:13:08 -0700 (PDT)
Received: from [192.168.0.10] (180.190.9.51.dyn.plus.net. [51.9.190.180])
	by smtp.googlemail.com with ESMTPSA id
	p34sm5963556wrc.66.2017.06.19.17.13.07 for <bug-bash@gnu.org>
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Mon, 19 Jun 2017 17:13:08 -0700 (PDT)
From: Kevin Brodsky <corax26@gmail.com>
Subject: Unexpected word splitting on $* when IFS is unset
To: bug-bash@gnu.org
Message-ID: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
Date: Tue, 20 Jun 2017 01:13:07 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.2.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
Content-Language: en-GB
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::229
X-Mailman-Approved-At: Mon, 19 Jun 2017 21:48:58 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 00:13:16 -0000

Hi,

When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
and not the expected IFS=$' \t\n'. All the other unquoted mass
expansions ($@, array[*], array[@]) are word-split as if IFS=$'
\t\n'.For instance:

  nb_args() { echo $#; }
 
  set -- $'a\nb'
  unset IFS
 
  # Expected: 2, actual: 2
  nb_args $@
  # Expected: 2, actual: 1
  nb_args $*
 
  ar=("$@")
  # Expected: 2, actual: 2
  nb_args ${ar[*]}
  # Expected: 2, actual: 2
  nb_args ${ar[@]}

Note that this only occurs if IFS is *globally* unset. If made local and
then unset (as in f() { local IFS; unset IFS; ... }), $* is word-split
as expected.

This is a regression that appeared in 4.3 and is still present on devel
(bash-snap-20170616). A git bisect on devel shows that commit
1a81420a36fa (bash-20130125 snapshot) introduced this change. It seems
indeed that this commit is related to the handling of $* when IFS is
unset, but my knowledge of Bash's sources is too limited to tell what's
wrong with it :-)

Kevin


From MAILER-DAEMON Mon Jun 19 21:59:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN8Rq-0001T7-H1
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 21:59:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:33886)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dN8Rn-0001RQ-9o
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:59:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dN8Rl-0006mJ-IH
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:59:15 -0400
Received: from mail-ot0-x22e.google.com ([2607:f8b0:4003:c0f::22e]:34218)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <zartaj@gmail.com>) id 1dN8Rl-0006m1-BE
	for bug-bash@gnu.org; Mon, 19 Jun 2017 21:59:13 -0400
Received: by mail-ot0-x22e.google.com with SMTP id r67so80319439ota.1
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 18:59:13 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:from:date:message-id:subject:to;
	bh=2CS8sYUUK6YqZ3KV2e/u9hETRz7bbw+7X7Vao1WuBK8=;
	b=O49pnCKBChYz3q7icFnutOHNgevQaI0+mCUQmzEBBvMXSpEHSxWip4A4W2VN1Xs/s9
	OHWe4mDeTqeioz68M3/4bkcg+OrGY0loSoYDfu8gzaCarqplUMR1nQx0Ksed7plzGqKh
	MLZ7CrICG5S8CmmoI6AhFQhnwSghXI82Y+uwbS0djSkNgkE3/CkwGOqWvE9FwcTSH5kp
	DiMU48HREewtd/mpl0ugmbH8Mm5uhknDOBDvR0VmxuI7Kb9UgMxGcpAhNBHSjHY+++xp
	euZKTJ7+BhWGGuORewu+V4eIpkmLGWhJ7wD65IROustl8z1cJWmDvSlYdWDLEVxjCxcZ
	lCTg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
	bh=2CS8sYUUK6YqZ3KV2e/u9hETRz7bbw+7X7Vao1WuBK8=;
	b=VwZfa5LzZq1h/oaOiYIOKDrTQTLIACPyoPf4hhlAynkIkjYoL9NpS8dzZ6VAMWgUbO
	nMXYBKScYiz3XLFo7jEKisVjrsI5SR9q26qkzJuXQH3TqHmHyhXvJ+GJr2W4SHjVKgi8
	7ud4g2U5tL4YsoUBOW1Cg9kMVh0xnLubg+3gKWCS1X1CgaGnFvEgk/Z4CdjoqsX3ByiJ
	6vOXS5ylsgeX2l7f7KBP+nmfXCc3KWDpUan5uE8FQd/xEdqdGWGpaHgLaUvh7+pHTHdl
	qdzl3c2MbuePRWWtPjwoK1htsDqMtS6rkqBL/0XJD0XQCgqber0ZfIJj3UNNDWaGq0WS
	U8cA==
X-Gm-Message-State: AKS2vOw362onIOB50bBeO9AS19q8EgRvn/g+UcPjRpQAQMog3gFSYL66
	TzbKhm3ADBNmSbOC2YkfpVvg+cjTZBeE/r8=
X-Received: by 10.157.56.68 with SMTP id r4mr11148413otd.216.1497923952093;
	Mon, 19 Jun 2017 18:59:12 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.74.39.68 with HTTP; Mon, 19 Jun 2017 18:59:11 -0700 (PDT)
From: Z <zartaj@gmail.com>
Date: Mon, 19 Jun 2017 21:59:11 -0400
Message-ID: <CAEU1kBpA-wD+hQ+aDFcd_+E1c6RUp9o-dSZeXouz3rS8ir5z3Q@mail.gmail.com>
Subject: [PATCH] Unix domain socket filename redirection
To: bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22e
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 01:59:17 -0000

This patch adds support for Unix domain sockets. A filename of the
form /dev/unixstream/path used in a redirection makes bash attempt to
open a connection to the Unix domain stream socket at /path. Similarly
a filename of the form /dev/unixdgram/path makes bash attempt to open
a connection to the Unix domain datagram socket at /path.

Zartaj Majeed

 Makefile.in              |   2 +-
 config.h.in              |   7 ++++
 configure.ac             |   9 +++-
 externs.h                |   3 ++
 lib/sh/Makefile.in       |   8 +++-
 lib/sh/usockopen.c       | 104 +++++++++++++++++++++++++++++++++++++++++++++++
 redir.c                  |  12 ++++++
 tests/misc/devunix.tests |  18 ++++++++
 8 files changed, 158 insertions(+), 5 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index c7b62bc0..542cede8 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -222,7 +222,7 @@ SHLIB_SOURCE =      ${SH_LIBSRC}/clktck.c
${SH_LIBSRC}/getcwd.c \
                ${SH_LIBSRC}/input_avail.c ${SH_LIBSRC}/mbscasecmp.c \
                ${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c \
                ${SH_LIBSRC}/wcswidth.c ${SH_LIBSRC}/wcsnwidth.c \
-               ${SH_LIBSRC}/shmbchar.c
+               ${SH_LIBSRC}/shmbchar.c ${SH_LIBSRC}/usockopen.c

 SHLIB_LIB = -lsh
 SHLIB_LIBNAME = libsh.a
diff --git a/config.h.in b/config.h.in
index a5ad9e72..36e8f5dd 100644
--- a/config.h.in
+++ b/config.h.in
@@ -151,6 +151,10 @@
    socket connections when used in redirections */
 #undef NETWORK_REDIRECTIONS

+/* Define UNIXSOCK_REDIRECTIONS if you want
/dev/(unixstream|unixdgram)/path to open
+   socket connections when used in redirections */
+#undef UNIXSOCK_REDIRECTIONS
+
 /* Define PROGRAMMABLE_COMPLETION for the programmable completion features
    and the complete builtin. */
 #undef PROGRAMMABLE_COMPLETION
@@ -1042,6 +1046,9 @@
 /* Define if you have the <sys/socket.h> header file.  */
 #undef HAVE_SYS_SOCKET_H

+/* Define if you have the <sys/un.h> header file.  */
+#undef HAVE_SYS_UN_H
+
 /* Define if you have the <sys/stat.h> header file. */
 #undef HAVE_SYS_STAT_H

diff --git a/configure.ac b/configure.ac
index ce4e9b60..a8e9f43c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -168,6 +168,7 @@ opt_cond_regexp=yes
 opt_coproc=yes
 opt_arith_for_command=yes
 opt_net_redirs=yes
+opt_usock_redirs=yes
 opt_progcomp=yes
 opt_separate_help=no
 opt_multibyte=yes
@@ -196,7 +197,7 @@ if test $opt_minimal_config = yes; then
        opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no
        opt_brace_expansion=no opt_disabled_builtins=no opt_command_timing=no
        opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no
-       opt_net_redirs=no opt_progcomp=no opt_separate_help=no
+       opt_net_redirs=no opt_usock_redirs=no opt_progcomp=no
opt_separate_help=no
        opt_multibyte=yes opt_cond_regexp=no opt_coproc=no
        opt_casemod_attrs=no opt_casemod_expansions=no opt_extglob_default=no
        opt_globascii_default=no
@@ -227,6 +228,7 @@ AC_ARG_ENABLE(history,
AC_HELP_STRING([--enable-history], [turn on command histo
 AC_ARG_ENABLE(job-control, AC_HELP_STRING([--enable-job-control],
[enable job control features]), opt_job_control=$enableval)
 AC_ARG_ENABLE(multibyte, AC_HELP_STRING([--enable-multibyte], [enable
multibyte characters if OS supports them]), opt_multibyte=$enableval)
 AC_ARG_ENABLE(net-redirections,
AC_HELP_STRING([--enable-net-redirections], [enable /dev/tcp/host/port
redirection]), opt_net_redirs=$enableval)
+AC_ARG_ENABLE(usock-redirections,
AC_HELP_STRING([--enable-usock-redirections], [enable
/dev/unixstream/path redirection]), opt_usock_redirs=$enableval)
 AC_ARG_ENABLE(process-substitution,
AC_HELP_STRING([--enable-process-substitution], [enable process
substitution]), opt_process_subst=$enableval)
 AC_ARG_ENABLE(progcomp, AC_HELP_STRING([--enable-progcomp], [enable
programmable completion and the complete builtin]),
opt_progcomp=$enableval)
 AC_ARG_ENABLE(prompt-string-decoding,
AC_HELP_STRING([--enable-prompt-string-decoding], [turn on escape
character decoding in prompts]), opt_prompt_decoding=$enableval)
@@ -321,6 +323,9 @@ fi
 if test $opt_net_redirs = yes; then
 AC_DEFINE(NETWORK_REDIRECTIONS)
 fi
+if test $opt_usock_redirs = yes; then
+AC_DEFINE(UNIXSOCK_REDIRECTIONS)
+fi
 if test $opt_progcomp = yes; then
 AC_DEFINE(PROGRAMMABLE_COMPLETION)
 fi
@@ -702,7 +707,7 @@ AC_CHECK_HEADERS(unistd.h stdlib.h stdarg.h
varargs.h limits.h string.h \
                 stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \
                 regex.h syslog.h ulimit.h)
 AC_CHECK_HEADERS(sys/pte.h sys/stream.h sys/select.h sys/file.h sys/ioctl.h \
-                sys/param.h sys/socket.h sys/stat.h \
+                sys/param.h sys/socket.h sys/un.h sys/stat.h \
                 sys/time.h sys/times.h sys/types.h sys/wait.h)
 AC_CHECK_HEADERS(netinet/in.h arpa/inet.h)

diff --git a/externs.h b/externs.h
index fa0603d3..1315866c 100644
--- a/externs.h
+++ b/externs.h
@@ -270,6 +270,9 @@ extern int isnetconn __P((int));
 /* declarations for functions defined in lib/sh/netopen.c */
 extern int netopen __P((char *));

+/* declarations for functions defined in lib/sh/usockopen.c */
+extern int usockopen __P((char *));
+
 /* Declarations for  functions defined in lib/sh/oslib.c */

 #if !defined (HAVE_DUP2) || defined (DUP2_BROKEN)
diff --git a/lib/sh/Makefile.in b/lib/sh/Makefile.in
index 2ca921b3..3d357997 100644
--- a/lib/sh/Makefile.in
+++ b/lib/sh/Makefile.in
@@ -84,7 +84,7 @@ LIBRARY_NAME = libsh.a
 CSOURCES = clktck.c clock.c getcwd.c getenv.c oslib.c setlinebuf.c \
           strcasecmp.c strerror.c strtod.c strtol.c strtoul.c \
           vprint.c itos.c rename.c zread.c zwrite.c shtty.c \
-          inet_aton.c netconn.c netopen.c strpbrk.c timeval.c makepath.c \
+          inet_aton.c netconn.c netopen.c usockopen.c strpbrk.c
timeval.c makepath.c \
           pathcanon.c pathphys.c tmpfile.c stringlist.c stringvec.c spell.c \
           shquote.c strtrans.c strcasestr.c snprintf.c mailstat.c \
           fmtulong.c fmtullong.c fmtumax.c shmatch.c strnlen.c \
@@ -101,7 +101,7 @@ HSOURCES =
 LIBOBJS = @LIBOBJS@
 OBJECTS = clktck.o clock.o getenv.o oslib.o setlinebuf.o strnlen.o \
          itos.o zread.o zwrite.o shtty.o shmatch.o eaccess.o \
-         netconn.o netopen.o timeval.o makepath.o pathcanon.o \
+         netconn.o netopen.o usockopen.o timeval.o makepath.o pathcanon.o \
          pathphys.o tmpfile.o stringlist.o stringvec.o spell.o shquote.o \
          strtrans.o snprintf.o mailstat.o fmtulong.o \
          fmtullong.o fmtumax.o zcatfd.o zmapfd.o winsize.o wcsdup.o \
@@ -166,6 +166,7 @@ memset.o: memset.c
 mktime.o: mktime.c
 netconn.o: netconn.c
 netopen.o: netopen.c
+usockopen.o: usockopen.c
 oslib.o: oslib.c
 pathcanon.o: pathcanon.c
 pathphys.o: pathphys.c
@@ -243,6 +244,7 @@ memset.o: ${BUILD_DIR}/config.h
 mktime.o: ${BUILD_DIR}/config.h
 netconn.o: ${BUILD_DIR}/config.h
 netopen.o: ${BUILD_DIR}/config.h
+usockopen.o: ${BUILD_DIR}/config.h
 oslib.o: ${BUILD_DIR}/config.h
 pathcanon.o: ${BUILD_DIR}/config.h
 pathphys.o: ${BUILD_DIR}/config.h
@@ -341,6 +343,8 @@ netopen.o: ${BUILD_DIR}/pathnames.h ${topdir}/externs.h
 netopen.o: ${topdir}/bashintl.h ${LIBINTL_H} $(BASHINCDIR)/gettext.h
 #netopen.o: ${BUILD_DIR}/version.h

+usockopen.o: ${topdir}/bashansi.h ${topdir}/bashintl.h
+
 oslib.o: ${topdir}/bashtypes.h ${topdir}/bashansi.h ${BASHINCDIR}/maxpath.h
 oslib.o: ${topdir}/shell.h ${topdir}/syntax.h ${topdir}/bashjmp.h
${BASHINCDIR}/posixjmp.h
 oslib.o: ${topdir}/command.h ${BASHINCDIR}/stdc.h ${topdir}/error.h
diff --git a/lib/sh/usockopen.c b/lib/sh/usockopen.c
new file mode 100644
index 00000000..7575003c
--- /dev/null
+++ b/lib/sh/usockopen.c
@@ -0,0 +1,104 @@
+/*
+ * usockopen.c -- functions to make unix domain socket connections
+ *
+ * Zartaj T. Majeed
+ */
+
+/* Copyright (C) 1987-2017 Free Software Foundation, Inc.
+
+   This file is part of GNU Bash, the Bourne Again SHell.
+
+   Bash is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   Bash is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with Bash.  If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#include <config.h>
+
+#if defined (HAVE_UNISTD_H)
+#  include <unistd.h>
+#endif
+
+#include <stdio.h>
+#include <sys/types.h>
+
+#if defined (HAVE_SYS_SOCKET_H)
+#  include <sys/socket.h>
+#endif
+
+#if defined (HAVE_SYS_UN_H)
+#  include <sys/un.h>
+#endif
+
+#include <bashansi.h>
+#include <bashintl.h>
+
+#include <errno.h>
+
+#ifndef errno
+extern int errno;
+#endif
+
+static int _usockopen __P((char *, int));
+
+/*
+ * Open Unix domain socket connection
+ * Returns the connected socket or -1 on error.
+ */
+static int
+_usockopen (path, typ)
+     char *path;
+     int typ;
+{
+  int s, e;
+  struct sockaddr_un addr;
+  int gerr;
+  int socktyp = typ == 's'? SOCK_STREAM: SOCK_DGRAM;
+
+  if ((s = socket (AF_UNIX, socktyp, 0)) < 0)
+       {
+         sys_error ("unix socket");
+         return -1;
+       }
+
+  memset (&addr, 0, sizeof addr);
+  addr.sun_family = AF_UNIX;
+  strncpy (addr.sun_path, path, sizeof(addr.sun_path) - 1);
+
+  if (connect (s, &addr, sizeof addr) < 0)
+       {
+         e = errno;
+         sys_error ("unix connect");
+         close (s);
+         errno = e;
+         return -1;
+       }
+  return s;
+}
+
+/*
+ * Open Unix domain socket connection to a path like
/dev/unixstream/tmp/xyz.sock or /dev/unixdgram/tmp/xyz.sock
+ * Returns the connected socket or -1 on error.
+ */
+int
+usockopen (path)
+     char *path;
+{
+  char *s;
+  int fd;
+
+  s = strchr (path+9, '/');
+  fd = _usockopen (s, path[9]);
+
+  return fd;
+}
+
diff --git a/redir.c b/redir.c
index 25488eaf..e026cc12 100644
--- a/redir.c
+++ b/redir.c
@@ -519,6 +519,8 @@ here_document_to_fd (redirectee, ri)
 #define RF_DEVSTDOUT   4
 #define RF_DEVTCP      5
 #define RF_DEVUDP      6
+#define RF_DEVUSTRM    7
+#define RF_DEVUDGRM    8

 /* A list of pattern/value pairs for filenames that the redirection
    code handles specially. */
@@ -535,6 +537,10 @@ static STRING_INT_ALIST _redir_special_filenames[] = {
   { "/dev/tcp/*/*", RF_DEVTCP },
   { "/dev/udp/*/*", RF_DEVUDP },
 #endif
+#if defined (UNIXSOCK_REDIRECTIONS)
+  { "/dev/unixstream/*", RF_DEVUSTRM },
+  { "/dev/unixdgram/*", RF_DEVUDGRM },
+#endif
   { (char *)NULL, -1 }
 };

@@ -588,6 +594,12 @@ redir_special_open (spec, filename, flags, mode, ri)
 #endif
       break;
 #endif /* NETWORK_REDIRECTIONS */
+
+#if defined (UNIXSOCK_REDIRECTIONS)
+    case RF_DEVUSTRM:
+    case RF_DEVUDGRM:
+      fd = usockopen (filename);
+#endif /* UNIXSOCK_REDIRECTIONS */
     }

   return fd;
diff --git a/tests/misc/devunix.tests b/tests/misc/devunix.tests
new file mode 100644
index 00000000..457a40f0
--- /dev/null
+++ b/tests/misc/devunix.tests
@@ -0,0 +1,18 @@
+sock=/tmp/devunixtest.sock
+out=/tmp/devunixtest.out
+s=abcd.$$
+
+nc -U -l $sock >$out&
+sleep 1
+exec 9>/dev/unixstream$sock
+
+echo "$s" >&9
+exec 9>&-
+
+read t <$out
+
+if [[ $s != $t ]]; then
+  echo "out \"$s\" in \"$t\""
+fi
+
+rm $sock $out


From MAILER-DAEMON Mon Jun 19 23:04:12 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN9Se-0001Fn-Bf
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 23:04:12 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34762)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dN9Sc-0001Fg-84
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:04:11 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dN9SX-0007HG-Lp
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:04:10 -0400
Received: from mail-oi0-x229.google.com ([2607:f8b0:4003:c06::229]:35262)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dN9SX-0007H8-FY
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:04:05 -0400
Received: by mail-oi0-x229.google.com with SMTP id c189so42095041oia.2
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 20:04:05 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=jrLpHxvCIhuVNW0PCdLOoKV7E+Sn90A0n6s3XrnTFwE=;
	b=RwMSxk+fHtNXSqRU24GwjGp0J7TZWt601GvU+cbJr4VFAfI1z5EKa/y1hYNOZNElEn
	0jLXbqD0HIXvoGBRwAcMiHGQxJF0LCvbifDQqMn93upl8eH03Aoiaf6OGlSgWfVqFSZ8
	mK1LolNpeX7NuLPtwREcSwlmhXV3Xev4tPM28QuAIakid5bqSsaTwayt30sYDOEl2o2m
	9POhcx4kjKAdkhAhgWbL0VFhNRIUsRPB/qYxVBmGlGdmerddYw7gPExsdFp9coTC+a/E
	Up1oAPYSvcgUyuMhOjNOMOgp3/g+6IUYY70fH8mxrq77dygz0WH9kPgxP2vfhRlCyyvi
	T4aw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=jrLpHxvCIhuVNW0PCdLOoKV7E+Sn90A0n6s3XrnTFwE=;
	b=cTnNwQfva0FE4MQftBOo0T+OAuK+nqdtw26rRDaEy3Rh1YCa8on88xAMk4oFhDa88+
	yQ54p+yLThseXOiB1NcgHayUN9SMhnMOl39yEw8cN9rQpxskkxXFiMmk+W+S4+Xgi0Xx
	pKGwHbYRBqkjf8FmflVDtGSVeap1C6+ayNdGsKeOHpxZqH0nqTPbcj9oGiRbkAY+jfig
	UeLtX9UR+MFp+Qovy6+K5EItFEyJFLYVxd8i4IQmYMKm1Z/cIP7YttCvWpNu7h1a4+aB
	J0esbe5jtEiVhLbhtV6VOy9J+X6GPgt1CzkM2CA3IdF6ZF6C9vtJrLLLO8INAJnXGcwX
	t52A==
X-Gm-Message-State: AKS2vOyYKuefraX4k9UUoLO3nkrSOekp3tDbuePt4bgFHmo+oVuW1IY0
	agqGm732jKDLaA==
X-Received: by 10.202.44.134 with SMTP id s128mr12305277ois.7.1497927844419;
	Mon, 19 Jun 2017 20:04:04 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	v69sm5776232oie.31.2017.06.19.20.04.01
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 19 Jun 2017 20:04:03 -0700 (PDT)
Date: Mon, 19 Jun 2017 22:03:48 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: gazelle@xmission.com
Cc: bug-bash@gnu.org
Subject: Re: "realpath" loadable (in the examples/loadables dir) infinite loops
Message-ID: <20170620030348.mdfb3b3macnabvyb@debian>
References: <E1dN7o3-00089U-Bp@shell.xmission.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <E1dN7o3-00089U-Bp@shell.xmission.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 03:04:11 -0000

On Mon, Jun 19, 2017 at 07:18:11PM -0600, gazelle@xmission.com wrote:
[...]
> Description:
> 	Command "realpath --help" causes infinite loop.

I can reproduce this in the `devel' branch.

The getopts loop is missing a `return' to break out of it. This should
fix it:

diff --git a/examples/loadables/realpath.c b/examples/loadables/realpath.c
index b19b87fb..7ea9a995 100644
--- a/examples/loadables/realpath.c
+++ b/examples/loadables/realpath.c
@@ -88,6 +88,7 @@ WORD_LIST	*list;
 			break;
 		default:
 			builtin_usage();
+			return (EX_USAGE);
 		}
 	}

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Mon Jun 19 23:37:02 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dN9yQ-00086S-H5
	for mharc-bug-bash@gnu.org; Mon, 19 Jun 2017 23:37:02 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44514)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dN9yO-00086F-4k
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:37:01 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dN9yL-0003aM-1y
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:37:00 -0400
Received: from mail-oi0-x22b.google.com ([2607:f8b0:4003:c06::22b]:34977)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dN9yK-0003a8-SO
	for bug-bash@gnu.org; Mon, 19 Jun 2017 23:36:56 -0400
Received: by mail-oi0-x22b.google.com with SMTP id c189so42349330oia.2
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 20:36:56 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=NRDXPS5vrFiAgI+US2ATEBa54Lwn8TVcg8wdQPDKIvU=;
	b=fAdZKgfAFTKdGOYnWpx4odDTfeDIfXjlYffysyw88+qqhBeqqbMsLAVhGwa3JYF9vZ
	IarSvsq2SbxcPNQPAv+lQ/s5juyaZ9q4wILrsCRj4uEur1bi7QqXBhcKtAhT4Ysn7WCe
	ayO8AHFJ21oVnxB75igIj0QwTQ1mx1U2tYgzuSXSWve/vymUfqZALbnBb6jwLXYZqwWJ
	R1jPeeT9fxA1yFovcwDEH0lxwkuLijrDx5VSdsEYZPcuKIVPc40RCxzsirNQOI0afv3Y
	3+MlhpQH6UN0Tc4g4TZImV9aIDnPGPneqU2us9qfgtzKXeh7QyaM6V7Wldj51UXXGk4y
	A9/w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=NRDXPS5vrFiAgI+US2ATEBa54Lwn8TVcg8wdQPDKIvU=;
	b=dmEmG2zqjA85Dj4tV3K1LGgRKOsLZiNVgPrM+iYbKLREkmc6m4ANXPkHxYX2EzmVMa
	OMruEs0k/7Y8hgRLIN59NGaDKTu8vDTSu2UFRz4khCsyIsbOamoZ7lLDocx6oicWwcWK
	/ne/RJFNZMBpjE/EniMpQGodeK7KF+VnKRckuLAz7I9xJFDjv9HfeKlLvRzRbWenMLLr
	Y9j0NaVMfWHPbKAYPbhcBxzQk37nZ14f5nL2ttPtoiNf4cujzZYmGBqgf4HwMUEwVjnX
	lZVgFPoqNszQZJgc6Zg2IXxL0HSLp5hflpnSQjEWM6NNi39ph39Zxf4L2afyBTtIaYQE
	qnkg==
X-Gm-Message-State: AKS2vOxFqpqoiTxXgytYDmE6xn6Pm7fhf3rMVs0x+IAd6oC6/xxxoG7y
	fmcv9aWvmiAG3g==
X-Received: by 10.202.190.214 with SMTP id o205mr6683385oif.70.1497929816116; 
	Mon, 19 Jun 2017 20:36:56 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	r206sm5850707oia.32.2017.06.19.20.36.53
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 19 Jun 2017 20:36:55 -0700 (PDT)
Date: Mon, 19 Jun 2017 22:36:40 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Z <zartaj@gmail.com>
Cc: bug-bash@gnu.org
Subject: Re: [PATCH] Unix domain socket filename redirection
Message-ID: <20170620033640.462tyl64fj6xcznu@debian>
References: <CAEU1kBpKTCYasCyFsQ==PQfs7g8+VBxo71DLTz-z6_rrb+D4Sg@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CAEU1kBpKTCYasCyFsQ==PQfs7g8+VBxo71DLTz-z6_rrb+D4Sg@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22b
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 03:37:01 -0000

On Mon, Jun 19, 2017 at 07:30:42PM -0400, Z wrote:
> This patch adds support for Unix domain sockets. A filename of the form
> /dev/unixstream/path used in a redirection makes bash attempt to open a
> connection to the Unix domain stream socket at /path. Similarly a filename
> of the form /dev/unixdgram/path makes bash attempt to open a connection to
> the Unix domain datagram socket at /path.

Excuse my ignorance:

- What would be an expected use case of this feature? /dev/tcp and
  /dev/udp are commonly used because it allows the shell script writer
  to interact with popular text based protocols like HTTP or SMTP. It
  would seem that this UNIX domain socket patch targets a niche instead?

- Why should this be integrated into the core of bash, and not provided
  as a loadable builtin instead? It makes more sense to me to provide
  this as an optional shell builtin, which also make the usage less
  awkward (not a fan of the /dev/unixstream/the/path/is/here thing).


By the way, the patch does not apply. It would seem like you copy-pasted
the diff, so it got wrapped at some points and git is rejecting it.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 20 00:40:47 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNAy7-0002sH-Hd
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 00:40:47 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54148)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNAy4-0002s9-R4
	for bug-bash@gnu.org; Tue, 20 Jun 2017 00:40:46 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNAy2-0003Ey-Fd
	for bug-bash@gnu.org; Tue, 20 Jun 2017 00:40:44 -0400
Received: from mail-ot0-x22f.google.com ([2607:f8b0:4003:c0f::22f]:33200)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <zartaj@gmail.com>) id 1dNAy2-0003Ef-8a
	for bug-bash@gnu.org; Tue, 20 Jun 2017 00:40:42 -0400
Received: by mail-ot0-x22f.google.com with SMTP id y47so59520836oty.0
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 21:40:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=jIaJrRVqFHiStaSAyXP4GFbHEHPM0uJip0GJTVWa8+M=;
	b=U5KehDuRPBvfHK8ep3wOthi/mCDV2lrblKrONMaqAHgscE4OGRz+JI3I2Bsc93abZi
	vc/EOPX+TNyvCYP1vG75pQ8au0jRD/uHwH2Nke98uiljj+PyjRmOmGHU406KpN0lN2/p
	PUNbB7LvJ4CmebRo5+bf9jlWj8PiNOe3U1aT1QGiJkN0XcGq3CkaioqMlRSzvW3qW6qF
	QvhIuBznqKLGBsZ+qVHAPDFvnkLauvtlDSTcUv7cl7zh7/qr+8sLJgQRm/9fRdAM6dZs
	744FKTlewPz8bzAKPyszXz/dDfEPlmcegc4iuUdwU7JxArqEsMtaVnnW57K30lty0akQ
	56ow==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=jIaJrRVqFHiStaSAyXP4GFbHEHPM0uJip0GJTVWa8+M=;
	b=PwbpypdggbCOMw8cYcwdzS/M+1zVXgemGXDQSDbLgkHPlSWo/sVO9MXBk+rkvJDC8b
	W/v/bFL1/qKDb16m7QV4LYNuyr6T3rUkUWHYgzchhaY2xtSAdgPW6E8Z+dzvLcsPcnKh
	03T4s9su20fwJTJMXNB97OmlZbN4tBQd8xKI0bJNDlmOF54+fEk5/OOirq+IsGytAs+n
	g7lE6l1bsRoc8kkt5zo+m/44OoJCWUAVqimYkJZtktkhuYijlF6wMdZhJAEmBZkSQ3GK
	fAajCAeFQqgtOdHx9vs5bBQpGbALf+HkJ8lf28Ht+9xw3HPc4artlTwhvmIa1HAwSuwE
	duFw==
X-Gm-Message-State: AKS2vOxgQiCzjOGECRNF8aG9RjBSGYhMgX4AoWcPAxJVVQLidVWTyMIa
	8LCykLP+e5D6A0wdNZXq9AyyMwVoNQ==
X-Received: by 10.157.82.38 with SMTP id e38mr16229830oth.153.1497933641547;
	Mon, 19 Jun 2017 21:40:41 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.74.39.68 with HTTP; Mon, 19 Jun 2017 21:40:40 -0700 (PDT)
In-Reply-To: <20170620033640.462tyl64fj6xcznu@debian>
References: <CAEU1kBpKTCYasCyFsQ==PQfs7g8+VBxo71DLTz-z6_rrb+D4Sg@mail.gmail.com>
	<20170620033640.462tyl64fj6xcznu@debian>
From: Zartaj Majeed <zartaj@gmail.com>
Date: Tue, 20 Jun 2017 00:40:40 -0400
Message-ID: <CAEU1kBqOr5ZMOLHEYkS02A1ScCmb+JkL9G-9ayqWWiu-gRBPvA@mail.gmail.com>
Subject: Re: [PATCH] Unix domain socket filename redirection
To: =?UTF-8?Q?Eduardo_A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
Cc: bug-bash@gnu.org
Content-Type: multipart/mixed; boundary="f40304352a0c9a2c8d05525cdaec"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22f
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 04:40:46 -0000

--f40304352a0c9a2c8d05525cdaec
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Attaching the patch usock.diff.txt



On Mon, Jun 19, 2017 at 11:36 PM, Eduardo A. Bustamante L=C3=B3pez
<dualbus@gmail.com> wrote:
> On Mon, Jun 19, 2017 at 07:30:42PM -0400, Z wrote:
>> This patch adds support for Unix domain sockets. A filename of the form
>> /dev/unixstream/path used in a redirection makes bash attempt to open a
>> connection to the Unix domain stream socket at /path. Similarly a filena=
me
>> of the form /dev/unixdgram/path makes bash attempt to open a connection =
to
>> the Unix domain datagram socket at /path.
>
> Excuse my ignorance:
>
> - What would be an expected use case of this feature? /dev/tcp and
>   /dev/udp are commonly used because it allows the shell script writer
>   to interact with popular text based protocols like HTTP or SMTP. It
>   would seem that this UNIX domain socket patch targets a niche instead?
>
> - Why should this be integrated into the core of bash, and not provided
>   as a loadable builtin instead? It makes more sense to me to provide
>   this as an optional shell builtin, which also make the usage less
>   awkward (not a fan of the /dev/unixstream/the/path/is/here thing).
>
>
> By the way, the patch does not apply. It would seem like you copy-pasted
> the diff, so it got wrapped at some points and git is rejecting it.
>
> --
> Eduardo Bustamante
> https://dualbus.me/

--f40304352a0c9a2c8d05525cdaec
Content-Type: text/plain; charset="US-ASCII"; name="usock.diff.txt"
Content-Disposition: attachment; filename="usock.diff.txt"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_j452yikx0

ZGlmZiAtLWdpdCBhL01ha2VmaWxlLmluIGIvTWFrZWZpbGUuaW4KaW5kZXggYzdiNjJiYzAuLjU0
MmNlZGU4IDEwMDY0NAotLS0gYS9NYWtlZmlsZS5pbgorKysgYi9NYWtlZmlsZS5pbgpAQCAtMjIy
LDcgKzIyMiw3IEBAIFNITElCX1NPVVJDRSA9CSR7U0hfTElCU1JDfS9jbGt0Y2suYyAke1NIX0xJ
QlNSQ30vZ2V0Y3dkLmMgXAogCQkke1NIX0xJQlNSQ30vaW5wdXRfYXZhaWwuYyAke1NIX0xJQlNS
Q30vbWJzY2FzZWNtcC5jIFwKIAkJJHtTSF9MSUJTUkN9L2ZueGZvcm0uYyAke1NIX0xJQlNSQ30v
dW5pY29kZS5jIFwKIAkJJHtTSF9MSUJTUkN9L3djc3dpZHRoLmMgJHtTSF9MSUJTUkN9L3djc253
aWR0aC5jIFwKLQkJJHtTSF9MSUJTUkN9L3NobWJjaGFyLmMKKwkJJHtTSF9MSUJTUkN9L3NobWJj
aGFyLmMgJHtTSF9MSUJTUkN9L3Vzb2Nrb3Blbi5jCiAKIFNITElCX0xJQiA9IC1sc2gKIFNITElC
X0xJQk5BTUUgPSBsaWJzaC5hCmRpZmYgLS1naXQgYS9jb25maWcuaC5pbiBiL2NvbmZpZy5oLmlu
CmluZGV4IGE1YWQ5ZTcyLi4zNmU4ZjVkZCAxMDA2NDQKLS0tIGEvY29uZmlnLmguaW4KKysrIGIv
Y29uZmlnLmguaW4KQEAgLTE1MSw2ICsxNTEsMTAgQEAKICAgIHNvY2tldCBjb25uZWN0aW9ucyB3
aGVuIHVzZWQgaW4gcmVkaXJlY3Rpb25zICovCiAjdW5kZWYgTkVUV09SS19SRURJUkVDVElPTlMK
IAorLyogRGVmaW5lIFVOSVhTT0NLX1JFRElSRUNUSU9OUyBpZiB5b3Ugd2FudCAvZGV2Lyh1bml4
c3RyZWFtfHVuaXhkZ3JhbSkvcGF0aCB0byBvcGVuCisgICBzb2NrZXQgY29ubmVjdGlvbnMgd2hl
biB1c2VkIGluIHJlZGlyZWN0aW9ucyAqLworI3VuZGVmIFVOSVhTT0NLX1JFRElSRUNUSU9OUwor
CiAvKiBEZWZpbmUgUFJPR1JBTU1BQkxFX0NPTVBMRVRJT04gZm9yIHRoZSBwcm9ncmFtbWFibGUg
Y29tcGxldGlvbiBmZWF0dXJlcwogICAgYW5kIHRoZSBjb21wbGV0ZSBidWlsdGluLiAqLwogI3Vu
ZGVmIFBST0dSQU1NQUJMRV9DT01QTEVUSU9OCkBAIC0xMDQyLDYgKzEwNDYsOSBAQAogLyogRGVm
aW5lIGlmIHlvdSBoYXZlIHRoZSA8c3lzL3NvY2tldC5oPiBoZWFkZXIgZmlsZS4gICovCiAjdW5k
ZWYgSEFWRV9TWVNfU09DS0VUX0gKIAorLyogRGVmaW5lIGlmIHlvdSBoYXZlIHRoZSA8c3lzL3Vu
Lmg+IGhlYWRlciBmaWxlLiAgKi8KKyN1bmRlZiBIQVZFX1NZU19VTl9ICisKIC8qIERlZmluZSBp
ZiB5b3UgaGF2ZSB0aGUgPHN5cy9zdGF0Lmg+IGhlYWRlciBmaWxlLiAqLwogI3VuZGVmIEhBVkVf
U1lTX1NUQVRfSAogCmRpZmYgLS1naXQgYS9jb25maWd1cmUuYWMgYi9jb25maWd1cmUuYWMKaW5k
ZXggY2U0ZTliNjAuLmE4ZTlmNDNjIDEwMDY0NAotLS0gYS9jb25maWd1cmUuYWMKKysrIGIvY29u
ZmlndXJlLmFjCkBAIC0xNjgsNiArMTY4LDcgQEAgb3B0X2NvbmRfcmVnZXhwPXllcwogb3B0X2Nv
cHJvYz15ZXMKIG9wdF9hcml0aF9mb3JfY29tbWFuZD15ZXMKIG9wdF9uZXRfcmVkaXJzPXllcwor
b3B0X3Vzb2NrX3JlZGlycz15ZXMKIG9wdF9wcm9nY29tcD15ZXMKIG9wdF9zZXBhcmF0ZV9oZWxw
PW5vCiBvcHRfbXVsdGlieXRlPXllcwpAQCAtMTk2LDcgKzE5Nyw3IEBAIGlmIHRlc3QgJG9wdF9t
aW5pbWFsX2NvbmZpZyA9IHllczsgdGhlbgogCW9wdF9zZWxlY3Q9bm8gb3B0X2hlbHA9bm8gb3B0
X2FycmF5X3ZhcmlhYmxlcz1ubyBvcHRfZHBhcmVuX2FyaXRoPW5vCiAJb3B0X2JyYWNlX2V4cGFu
c2lvbj1ubyBvcHRfZGlzYWJsZWRfYnVpbHRpbnM9bm8gb3B0X2NvbW1hbmRfdGltaW5nPW5vCiAJ
b3B0X2V4dGVuZGVkX2dsb2I9bm8gb3B0X2NvbmRfY29tbWFuZD1ubyBvcHRfYXJpdGhfZm9yX2Nv
bW1hbmQ9bm8KLQlvcHRfbmV0X3JlZGlycz1ubyBvcHRfcHJvZ2NvbXA9bm8gb3B0X3NlcGFyYXRl
X2hlbHA9bm8KKwlvcHRfbmV0X3JlZGlycz1ubyBvcHRfdXNvY2tfcmVkaXJzPW5vIG9wdF9wcm9n
Y29tcD1ubyBvcHRfc2VwYXJhdGVfaGVscD1ubwogCW9wdF9tdWx0aWJ5dGU9eWVzIG9wdF9jb25k
X3JlZ2V4cD1ubyBvcHRfY29wcm9jPW5vCiAJb3B0X2Nhc2Vtb2RfYXR0cnM9bm8gb3B0X2Nhc2Vt
b2RfZXhwYW5zaW9ucz1ubyBvcHRfZXh0Z2xvYl9kZWZhdWx0PW5vCiAJb3B0X2dsb2Jhc2NpaV9k
ZWZhdWx0PW5vCkBAIC0yMjcsNiArMjI4LDcgQEAgQUNfQVJHX0VOQUJMRShoaXN0b3J5LCBBQ19I
RUxQX1NUUklORyhbLS1lbmFibGUtaGlzdG9yeV0sIFt0dXJuIG9uIGNvbW1hbmQgaGlzdG8KIEFD
X0FSR19FTkFCTEUoam9iLWNvbnRyb2wsIEFDX0hFTFBfU1RSSU5HKFstLWVuYWJsZS1qb2ItY29u
dHJvbF0sIFtlbmFibGUgam9iIGNvbnRyb2wgZmVhdHVyZXNdKSwgb3B0X2pvYl9jb250cm9sPSRl
bmFibGV2YWwpCiBBQ19BUkdfRU5BQkxFKG11bHRpYnl0ZSwgQUNfSEVMUF9TVFJJTkcoWy0tZW5h
YmxlLW11bHRpYnl0ZV0sIFtlbmFibGUgbXVsdGlieXRlIGNoYXJhY3RlcnMgaWYgT1Mgc3VwcG9y
dHMgdGhlbV0pLCBvcHRfbXVsdGlieXRlPSRlbmFibGV2YWwpCiBBQ19BUkdfRU5BQkxFKG5ldC1y
ZWRpcmVjdGlvbnMsIEFDX0hFTFBfU1RSSU5HKFstLWVuYWJsZS1uZXQtcmVkaXJlY3Rpb25zXSwg
W2VuYWJsZSAvZGV2L3RjcC9ob3N0L3BvcnQgcmVkaXJlY3Rpb25dKSwgb3B0X25ldF9yZWRpcnM9
JGVuYWJsZXZhbCkKK0FDX0FSR19FTkFCTEUodXNvY2stcmVkaXJlY3Rpb25zLCBBQ19IRUxQX1NU
UklORyhbLS1lbmFibGUtdXNvY2stcmVkaXJlY3Rpb25zXSwgW2VuYWJsZSAvZGV2L3VuaXhzdHJl
YW0vcGF0aCByZWRpcmVjdGlvbl0pLCBvcHRfdXNvY2tfcmVkaXJzPSRlbmFibGV2YWwpCiBBQ19B
UkdfRU5BQkxFKHByb2Nlc3Mtc3Vic3RpdHV0aW9uLCBBQ19IRUxQX1NUUklORyhbLS1lbmFibGUt
cHJvY2Vzcy1zdWJzdGl0dXRpb25dLCBbZW5hYmxlIHByb2Nlc3Mgc3Vic3RpdHV0aW9uXSksIG9w
dF9wcm9jZXNzX3N1YnN0PSRlbmFibGV2YWwpCiBBQ19BUkdfRU5BQkxFKHByb2djb21wLCBBQ19I
RUxQX1NUUklORyhbLS1lbmFibGUtcHJvZ2NvbXBdLCBbZW5hYmxlIHByb2dyYW1tYWJsZSBjb21w
bGV0aW9uIGFuZCB0aGUgY29tcGxldGUgYnVpbHRpbl0pLCBvcHRfcHJvZ2NvbXA9JGVuYWJsZXZh
bCkKIEFDX0FSR19FTkFCTEUocHJvbXB0LXN0cmluZy1kZWNvZGluZywgQUNfSEVMUF9TVFJJTkco
Wy0tZW5hYmxlLXByb21wdC1zdHJpbmctZGVjb2RpbmddLCBbdHVybiBvbiBlc2NhcGUgY2hhcmFj
dGVyIGRlY29kaW5nIGluIHByb21wdHNdKSwgb3B0X3Byb21wdF9kZWNvZGluZz0kZW5hYmxldmFs
KQpAQCAtMzIxLDYgKzMyMyw5IEBAIGZpCiBpZiB0ZXN0ICRvcHRfbmV0X3JlZGlycyA9IHllczsg
dGhlbgogQUNfREVGSU5FKE5FVFdPUktfUkVESVJFQ1RJT05TKQogZmkKK2lmIHRlc3QgJG9wdF91
c29ja19yZWRpcnMgPSB5ZXM7IHRoZW4KK0FDX0RFRklORShVTklYU09DS19SRURJUkVDVElPTlMp
CitmaQogaWYgdGVzdCAkb3B0X3Byb2djb21wID0geWVzOyB0aGVuCiBBQ19ERUZJTkUoUFJPR1JB
TU1BQkxFX0NPTVBMRVRJT04pCiBmaQpAQCAtNzAyLDcgKzcwNyw3IEBAIEFDX0NIRUNLX0hFQURF
UlModW5pc3RkLmggc3RkbGliLmggc3RkYXJnLmggdmFyYXJncy5oIGxpbWl0cy5oIHN0cmluZy5o
IFwKIAkJIHN0ZGJvb2wuaCBzdGRkZWYuaCBzdGRpbnQuaCBuZXRkYi5oIHB3ZC5oIGdycC5oIHN0
cmluZ3MuaCBcCiAJCSByZWdleC5oIHN5c2xvZy5oIHVsaW1pdC5oKQogQUNfQ0hFQ0tfSEVBREVS
UyhzeXMvcHRlLmggc3lzL3N0cmVhbS5oIHN5cy9zZWxlY3QuaCBzeXMvZmlsZS5oIHN5cy9pb2N0
bC5oIFwKLQkJIHN5cy9wYXJhbS5oIHN5cy9zb2NrZXQuaCBzeXMvc3RhdC5oIFwKKwkJIHN5cy9w
YXJhbS5oIHN5cy9zb2NrZXQuaCBzeXMvdW4uaCBzeXMvc3RhdC5oIFwKIAkJIHN5cy90aW1lLmgg
c3lzL3RpbWVzLmggc3lzL3R5cGVzLmggc3lzL3dhaXQuaCkKIEFDX0NIRUNLX0hFQURFUlMobmV0
aW5ldC9pbi5oIGFycGEvaW5ldC5oKQogCmRpZmYgLS1naXQgYS9leHRlcm5zLmggYi9leHRlcm5z
LmgKaW5kZXggZmEwNjAzZDMuLjEzMTU4NjZjIDEwMDY0NAotLS0gYS9leHRlcm5zLmgKKysrIGIv
ZXh0ZXJucy5oCkBAIC0yNzAsNiArMjcwLDkgQEAgZXh0ZXJuIGludCBpc25ldGNvbm4gX19QKChp
bnQpKTsKIC8qIGRlY2xhcmF0aW9ucyBmb3IgZnVuY3Rpb25zIGRlZmluZWQgaW4gbGliL3NoL25l
dG9wZW4uYyAqLwogZXh0ZXJuIGludCBuZXRvcGVuIF9fUCgoY2hhciAqKSk7CiAKKy8qIGRlY2xh
cmF0aW9ucyBmb3IgZnVuY3Rpb25zIGRlZmluZWQgaW4gbGliL3NoL3Vzb2Nrb3Blbi5jICovCitl
eHRlcm4gaW50IHVzb2Nrb3BlbiBfX1AoKGNoYXIgKikpOworCiAvKiBEZWNsYXJhdGlvbnMgZm9y
ICBmdW5jdGlvbnMgZGVmaW5lZCBpbiBsaWIvc2gvb3NsaWIuYyAqLwogCiAjaWYgIWRlZmluZWQg
KEhBVkVfRFVQMikgfHwgZGVmaW5lZCAoRFVQMl9CUk9LRU4pCmRpZmYgLS1naXQgYS9saWIvc2gv
TWFrZWZpbGUuaW4gYi9saWIvc2gvTWFrZWZpbGUuaW4KaW5kZXggMmNhOTIxYjMuLjNkMzU3OTk3
IDEwMDY0NAotLS0gYS9saWIvc2gvTWFrZWZpbGUuaW4KKysrIGIvbGliL3NoL01ha2VmaWxlLmlu
CkBAIC04NCw3ICs4NCw3IEBAIExJQlJBUllfTkFNRSA9IGxpYnNoLmEKIENTT1VSQ0VTID0gY2xr
dGNrLmMgY2xvY2suYyBnZXRjd2QuYyBnZXRlbnYuYyBvc2xpYi5jIHNldGxpbmVidWYuYyBcCiAJ
ICAgc3RyY2FzZWNtcC5jIHN0cmVycm9yLmMgc3RydG9kLmMgc3RydG9sLmMgc3RydG91bC5jIFwK
IAkgICB2cHJpbnQuYyBpdG9zLmMgcmVuYW1lLmMgenJlYWQuYyB6d3JpdGUuYyBzaHR0eS5jIFwK
LQkgICBpbmV0X2F0b24uYyBuZXRjb25uLmMgbmV0b3Blbi5jIHN0cnBicmsuYyB0aW1ldmFsLmMg
bWFrZXBhdGguYyBcCisJICAgaW5ldF9hdG9uLmMgbmV0Y29ubi5jIG5ldG9wZW4uYyB1c29ja29w
ZW4uYyBzdHJwYnJrLmMgdGltZXZhbC5jIG1ha2VwYXRoLmMgXAogCSAgIHBhdGhjYW5vbi5jIHBh
dGhwaHlzLmMgdG1wZmlsZS5jIHN0cmluZ2xpc3QuYyBzdHJpbmd2ZWMuYyBzcGVsbC5jIFwKIAkg
ICBzaHF1b3RlLmMgc3RydHJhbnMuYyBzdHJjYXNlc3RyLmMgc25wcmludGYuYyBtYWlsc3RhdC5j
IFwKIAkgICBmbXR1bG9uZy5jIGZtdHVsbG9uZy5jIGZtdHVtYXguYyBzaG1hdGNoLmMgc3Rybmxl
bi5jIFwKQEAgLTEwMSw3ICsxMDEsNyBAQCBIU09VUkNFUyA9CiBMSUJPQkpTID0gQExJQk9CSlNA
CiBPQkpFQ1RTID0gY2xrdGNrLm8gY2xvY2subyBnZXRlbnYubyBvc2xpYi5vIHNldGxpbmVidWYu
byBzdHJubGVuLm8gXAogCSAgaXRvcy5vIHpyZWFkLm8gendyaXRlLm8gc2h0dHkubyBzaG1hdGNo
Lm8gZWFjY2Vzcy5vIFwKLQkgIG5ldGNvbm4ubyBuZXRvcGVuLm8gdGltZXZhbC5vIG1ha2VwYXRo
Lm8gcGF0aGNhbm9uLm8gXAorCSAgbmV0Y29ubi5vIG5ldG9wZW4ubyB1c29ja29wZW4ubyB0aW1l
dmFsLm8gbWFrZXBhdGgubyBwYXRoY2Fub24ubyBcCiAJICBwYXRocGh5cy5vIHRtcGZpbGUubyBz
dHJpbmdsaXN0Lm8gc3RyaW5ndmVjLm8gc3BlbGwubyBzaHF1b3RlLm8gXAogCSAgc3RydHJhbnMu
byBzbnByaW50Zi5vIG1haWxzdGF0Lm8gZm10dWxvbmcubyBcCiAJICBmbXR1bGxvbmcubyBmbXR1
bWF4Lm8gemNhdGZkLm8gem1hcGZkLm8gd2luc2l6ZS5vIHdjc2R1cC5vIFwKQEAgLTE2Niw2ICsx
NjYsNyBAQCBtZW1zZXQubzogbWVtc2V0LmMKIG1rdGltZS5vOiBta3RpbWUuYwogbmV0Y29ubi5v
OiBuZXRjb25uLmMKIG5ldG9wZW4ubzogbmV0b3Blbi5jCit1c29ja29wZW4ubzogdXNvY2tvcGVu
LmMKIG9zbGliLm86IG9zbGliLmMKIHBhdGhjYW5vbi5vOiBwYXRoY2Fub24uYwogcGF0aHBoeXMu
bzogcGF0aHBoeXMuYwpAQCAtMjQzLDYgKzI0NCw3IEBAIG1lbXNldC5vOiAke0JVSUxEX0RJUn0v
Y29uZmlnLmgKIG1rdGltZS5vOiAke0JVSUxEX0RJUn0vY29uZmlnLmgKIG5ldGNvbm4ubzogJHtC
VUlMRF9ESVJ9L2NvbmZpZy5oCiBuZXRvcGVuLm86ICR7QlVJTERfRElSfS9jb25maWcuaAordXNv
Y2tvcGVuLm86ICR7QlVJTERfRElSfS9jb25maWcuaAogb3NsaWIubzogJHtCVUlMRF9ESVJ9L2Nv
bmZpZy5oCiBwYXRoY2Fub24ubzogJHtCVUlMRF9ESVJ9L2NvbmZpZy5oCiBwYXRocGh5cy5vOiAk
e0JVSUxEX0RJUn0vY29uZmlnLmgKQEAgLTM0MSw2ICszNDMsOCBAQCBuZXRvcGVuLm86ICR7QlVJ
TERfRElSfS9wYXRobmFtZXMuaCAke3RvcGRpcn0vZXh0ZXJucy5oCiBuZXRvcGVuLm86ICR7dG9w
ZGlyfS9iYXNoaW50bC5oICR7TElCSU5UTF9IfSAkKEJBU0hJTkNESVIpL2dldHRleHQuaAogI25l
dG9wZW4ubzogJHtCVUlMRF9ESVJ9L3ZlcnNpb24uaAogCit1c29ja29wZW4ubzogJHt0b3BkaXJ9
L2Jhc2hhbnNpLmggJHt0b3BkaXJ9L2Jhc2hpbnRsLmgKKwogb3NsaWIubzogJHt0b3BkaXJ9L2Jh
c2h0eXBlcy5oICR7dG9wZGlyfS9iYXNoYW5zaS5oICR7QkFTSElOQ0RJUn0vbWF4cGF0aC5oCiBv
c2xpYi5vOiAke3RvcGRpcn0vc2hlbGwuaCAke3RvcGRpcn0vc3ludGF4LmggJHt0b3BkaXJ9L2Jh
c2hqbXAuaCAke0JBU0hJTkNESVJ9L3Bvc2l4am1wLmgKIG9zbGliLm86ICR7dG9wZGlyfS9jb21t
YW5kLmggJHtCQVNISU5DRElSfS9zdGRjLmggJHt0b3BkaXJ9L2Vycm9yLmgKZGlmZiAtLWdpdCBh
L2xpYi9zaC91c29ja29wZW4uYyBiL2xpYi9zaC91c29ja29wZW4uYwpuZXcgZmlsZSBtb2RlIDEw
MDY0NAppbmRleCAwMDAwMDAwMC4uNzU3NTAwM2MKLS0tIC9kZXYvbnVsbAorKysgYi9saWIvc2gv
dXNvY2tvcGVuLmMKQEAgLTAsMCArMSwxMDQgQEAKKy8qCisgKiB1c29ja29wZW4uYyAtLSBmdW5j
dGlvbnMgdG8gbWFrZSB1bml4IGRvbWFpbiBzb2NrZXQgY29ubmVjdGlvbnMKKyAqCisgKiBaYXJ0
YWogVC4gTWFqZWVkCisgKi8KKworLyogQ29weXJpZ2h0IChDKSAxOTg3LTIwMTcgRnJlZSBTb2Z0
d2FyZSBGb3VuZGF0aW9uLCBJbmMuCisKKyAgIFRoaXMgZmlsZSBpcyBwYXJ0IG9mIEdOVSBCYXNo
LCB0aGUgQm91cm5lIEFnYWluIFNIZWxsLgorCisgICBCYXNoIGlzIGZyZWUgc29mdHdhcmU6IHlv
dSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vciBtb2RpZnkKKyAgIGl0IHVuZGVyIHRoZSB0ZXJt
cyBvZiB0aGUgR05VIEdlbmVyYWwgUHVibGljIExpY2Vuc2UgYXMgcHVibGlzaGVkIGJ5CisgICB0
aGUgRnJlZSBTb2Z0d2FyZSBGb3VuZGF0aW9uLCBlaXRoZXIgdmVyc2lvbiAzIG9mIHRoZSBMaWNl
bnNlLCBvcgorICAgKGF0IHlvdXIgb3B0aW9uKSBhbnkgbGF0ZXIgdmVyc2lvbi4KKworICAgQmFz
aCBpcyBkaXN0cmlidXRlZCBpbiB0aGUgaG9wZSB0aGF0IGl0IHdpbGwgYmUgdXNlZnVsLAorICAg
YnV0IFdJVEhPVVQgQU5ZIFdBUlJBTlRZOyB3aXRob3V0IGV2ZW4gdGhlIGltcGxpZWQgd2FycmFu
dHkgb2YKKyAgIE1FUkNIQU5UQUJJTElUWSBvciBGSVRORVNTIEZPUiBBIFBBUlRJQ1VMQVIgUFVS
UE9TRS4gIFNlZSB0aGUKKyAgIEdOVSBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlIGZvciBtb3JlIGRl
dGFpbHMuCisKKyAgIFlvdSBzaG91bGQgaGF2ZSByZWNlaXZlZCBhIGNvcHkgb2YgdGhlIEdOVSBH
ZW5lcmFsIFB1YmxpYyBMaWNlbnNlCisgICBhbG9uZyB3aXRoIEJhc2guICBJZiBub3QsIHNlZSA8
aHR0cDovL3d3dy5nbnUub3JnL2xpY2Vuc2VzLz4uCisqLworCisjaW5jbHVkZSA8Y29uZmlnLmg+
CisKKyNpZiBkZWZpbmVkIChIQVZFX1VOSVNURF9IKQorIyAgaW5jbHVkZSA8dW5pc3RkLmg+Cisj
ZW5kaWYKKworI2luY2x1ZGUgPHN0ZGlvLmg+CisjaW5jbHVkZSA8c3lzL3R5cGVzLmg+CisKKyNp
ZiBkZWZpbmVkIChIQVZFX1NZU19TT0NLRVRfSCkKKyMgIGluY2x1ZGUgPHN5cy9zb2NrZXQuaD4K
KyNlbmRpZgorCisjaWYgZGVmaW5lZCAoSEFWRV9TWVNfVU5fSCkKKyMgIGluY2x1ZGUgPHN5cy91
bi5oPgorI2VuZGlmCisKKyNpbmNsdWRlIDxiYXNoYW5zaS5oPgorI2luY2x1ZGUgPGJhc2hpbnRs
Lmg+CisKKyNpbmNsdWRlIDxlcnJuby5oPgorCisjaWZuZGVmIGVycm5vCitleHRlcm4gaW50IGVy
cm5vOworI2VuZGlmCisKK3N0YXRpYyBpbnQgX3Vzb2Nrb3BlbiBfX1AoKGNoYXIgKiwgaW50KSk7
CisKKy8qCisgKiBPcGVuIFVuaXggZG9tYWluIHNvY2tldCBjb25uZWN0aW9uCisgKiBSZXR1cm5z
IHRoZSBjb25uZWN0ZWQgc29ja2V0IG9yIC0xIG9uIGVycm9yLgorICovCitzdGF0aWMgaW50Citf
dXNvY2tvcGVuIChwYXRoLCB0eXApCisgICAgIGNoYXIgKnBhdGg7CisgICAgIGludCB0eXA7Cit7
CisgIGludCBzLCBlOworICBzdHJ1Y3Qgc29ja2FkZHJfdW4gYWRkcjsKKyAgaW50IGdlcnI7Cisg
IGludCBzb2NrdHlwID0gdHlwID09ICdzJz8gU09DS19TVFJFQU06IFNPQ0tfREdSQU07CisKKyAg
aWYgKChzID0gc29ja2V0IChBRl9VTklYLCBzb2NrdHlwLCAwKSkgPCAwKQorCXsKKwkgIHN5c19l
cnJvciAoInVuaXggc29ja2V0Iik7CisJICByZXR1cm4gLTE7CisJfQorCisgIG1lbXNldCAoJmFk
ZHIsIDAsIHNpemVvZiBhZGRyKTsKKyAgYWRkci5zdW5fZmFtaWx5ID0gQUZfVU5JWDsKKyAgc3Ry
bmNweSAoYWRkci5zdW5fcGF0aCwgcGF0aCwgc2l6ZW9mKGFkZHIuc3VuX3BhdGgpIC0gMSk7CisK
KyAgaWYgKGNvbm5lY3QgKHMsICZhZGRyLCBzaXplb2YgYWRkcikgPCAwKQorCXsKKwkgIGUgPSBl
cnJubzsKKwkgIHN5c19lcnJvciAoInVuaXggY29ubmVjdCIpOworCSAgY2xvc2UgKHMpOworCSAg
ZXJybm8gPSBlOworCSAgcmV0dXJuIC0xOworCX0KKyAgcmV0dXJuIHM7Cit9CisKKy8qCisgKiBP
cGVuIFVuaXggZG9tYWluIHNvY2tldCBjb25uZWN0aW9uIHRvIGEgcGF0aCBsaWtlIC9kZXYvdW5p
eHN0cmVhbS90bXAveHl6LnNvY2sgb3IgL2Rldi91bml4ZGdyYW0vdG1wL3h5ei5zb2NrCisgKiBS
ZXR1cm5zIHRoZSBjb25uZWN0ZWQgc29ja2V0IG9yIC0xIG9uIGVycm9yLgorICovCitpbnQKK3Vz
b2Nrb3BlbiAocGF0aCkKKyAgICAgY2hhciAqcGF0aDsKK3sKKyAgY2hhciAqczsKKyAgaW50IGZk
OworCisgIHMgPSBzdHJjaHIgKHBhdGgrOSwgJy8nKTsKKyAgZmQgPSBfdXNvY2tvcGVuIChzLCBw
YXRoWzldKTsKKworICByZXR1cm4gZmQ7Cit9CisKZGlmZiAtLWdpdCBhL3JlZGlyLmMgYi9yZWRp
ci5jCmluZGV4IDI1NDg4ZWFmLi5lMDI2Y2MxMiAxMDA2NDQKLS0tIGEvcmVkaXIuYworKysgYi9y
ZWRpci5jCkBAIC01MTksNiArNTE5LDggQEAgaGVyZV9kb2N1bWVudF90b19mZCAocmVkaXJlY3Rl
ZSwgcmkpCiAjZGVmaW5lIFJGX0RFVlNURE9VVAk0CiAjZGVmaW5lIFJGX0RFVlRDUAk1CiAjZGVm
aW5lIFJGX0RFVlVEUAk2CisjZGVmaW5lIFJGX0RFVlVTVFJNCTcKKyNkZWZpbmUgUkZfREVWVURH
Uk0JOAogCiAvKiBBIGxpc3Qgb2YgcGF0dGVybi92YWx1ZSBwYWlycyBmb3IgZmlsZW5hbWVzIHRo
YXQgdGhlIHJlZGlyZWN0aW9uCiAgICBjb2RlIGhhbmRsZXMgc3BlY2lhbGx5LiAqLwpAQCAtNTM1
LDYgKzUzNywxMCBAQCBzdGF0aWMgU1RSSU5HX0lOVF9BTElTVCBfcmVkaXJfc3BlY2lhbF9maWxl
bmFtZXNbXSA9IHsKICAgeyAiL2Rldi90Y3AvKi8qIiwgUkZfREVWVENQIH0sCiAgIHsgIi9kZXYv
dWRwLyovKiIsIFJGX0RFVlVEUCB9LAogI2VuZGlmCisjaWYgZGVmaW5lZCAoVU5JWFNPQ0tfUkVE
SVJFQ1RJT05TKQorICB7ICIvZGV2L3VuaXhzdHJlYW0vKiIsIFJGX0RFVlVTVFJNIH0sCisgIHsg
Ii9kZXYvdW5peGRncmFtLyoiLCBSRl9ERVZVREdSTSB9LAorI2VuZGlmCiAgIHsgKGNoYXIgKilO
VUxMLCAtMSB9CiB9OwogCkBAIC01ODgsNiArNTk0LDEyIEBAIHJlZGlyX3NwZWNpYWxfb3BlbiAo
c3BlYywgZmlsZW5hbWUsIGZsYWdzLCBtb2RlLCByaSkKICNlbmRpZgogICAgICAgYnJlYWs7CiAj
ZW5kaWYgLyogTkVUV09SS19SRURJUkVDVElPTlMgKi8KKworI2lmIGRlZmluZWQgKFVOSVhTT0NL
X1JFRElSRUNUSU9OUykKKyAgICBjYXNlIFJGX0RFVlVTVFJNOgorICAgIGNhc2UgUkZfREVWVURH
Uk06CisgICAgICBmZCA9IHVzb2Nrb3BlbiAoZmlsZW5hbWUpOworI2VuZGlmIC8qIFVOSVhTT0NL
X1JFRElSRUNUSU9OUyAqLwogICAgIH0KIAogICByZXR1cm4gZmQ7CmRpZmYgLS1naXQgYS90ZXN0
cy9taXNjL2RldnVuaXgudGVzdHMgYi90ZXN0cy9taXNjL2RldnVuaXgudGVzdHMKbmV3IGZpbGUg
bW9kZSAxMDA2NDQKaW5kZXggMDAwMDAwMDAuLjQ1N2E0MGYwCi0tLSAvZGV2L251bGwKKysrIGIv
dGVzdHMvbWlzYy9kZXZ1bml4LnRlc3RzCkBAIC0wLDAgKzEsMTggQEAKK3NvY2s9L3RtcC9kZXZ1
bml4dGVzdC5zb2NrCitvdXQ9L3RtcC9kZXZ1bml4dGVzdC5vdXQKK3M9YWJjZC4kJAorCituYyAt
VSAtbCAkc29jayA+JG91dCYKK3NsZWVwIDEKK2V4ZWMgOT4vZGV2L3VuaXhzdHJlYW0kc29jawor
CitlY2hvICIkcyIgPiY5CitleGVjIDk+Ji0KKworcmVhZCB0IDwkb3V0CisKK2lmIFtbICRzICE9
ICR0IF1dOyB0aGVuCisgIGVjaG8gIm91dCBcIiRzXCIgaW4gXCIkdFwiIgorZmkKKworcm0gJHNv
Y2sgJG91dAo=
--f40304352a0c9a2c8d05525cdaec--


From MAILER-DAEMON Tue Jun 20 01:06:42 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNBNC-0001Bk-5f
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 01:06:42 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60357)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNBN9-0001BH-N3
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:06:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNBN4-0004Rq-P1
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:06:39 -0400
Received: from mail-oi0-x229.google.com ([2607:f8b0:4003:c06::229]:33294)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dNBN4-0004Ra-Jv
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:06:34 -0400
Received: by mail-oi0-x229.google.com with SMTP id p66so33094783oia.0
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 22:06:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=P7t3t1IQUPdgLdNUxa37ccCy5BMxS62ugq+88a0q7Cg=;
	b=KQuOp/AOZZ2uxG3KBzAm4nw3FueCvQEK3UfIUfQBqEn3VptCcD92IMRpwaL/+d/S74
	gaVhoViH/dOTEsLUgfXHHAmajz5QfisZFQzcAFegdg3KJeq424fbpp8ex6FfAUgx8yyn
	VMqfIkwT+Du2aXWO0fk0Scj5X2h6w8jE8aBxNNi7Pf3bRjcwsq1jYDuJ4rvc0HRdoaT7
	NkBvFpuh6PxYlbSklXXlV1qEGyFE0tv3nZ/rbLedaOATe9D6CzJfeBaZKvgfo2JGoA9/
	8apPscIi6QAEcXJxCAYg5B63NRQIt9LtkICIq2rAQZ2us7h0wKqFzslteiaLlRcMUCe3
	5q6g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=P7t3t1IQUPdgLdNUxa37ccCy5BMxS62ugq+88a0q7Cg=;
	b=kmPJj3oTPDa2Nl6DFO2YJlgG+xJGDL2wVFWbQNs/fa+hV4SWaB9ovR3ZIBoZxCdSL5
	58uLndxmOcpLLS0sr30lcfYL3ArK0EG70QdHsHnIuWPD/55rPHqsofWE+rxkarmoAbaF
	hn7zDBU2VGBUYlv5bfWGylWjZyDqancKwXklyjM4a6cqT6ORTr7YhagOK3TdhtaKUshV
	itl34h3I9ogLaU5uHIqm1P9rULFXMYeJMm95BURCdOXJlp4234wtzKwrfVCnhulditxt
	1M4eG3QcE3wASAWR4rEsr5sQ91SEvWKyVmmyAAngE1cRjCIyiKDmTaY6MRLPno5CrJ8b
	4b5w==
X-Gm-Message-State: AKS2vOw5BgnjBXNR8Fokxu2qzRvZTaSF9MBMiVNWg0Zty7YD8af5CPN9
	8CkCr3He/VW8jcCZ
X-Received: by 10.202.56.11 with SMTP id f11mr3025247oia.127.1497935193756;
	Mon, 19 Jun 2017 22:06:33 -0700 (PDT)
Received: from localhost ([201.157.173.180])
	by smtp.gmail.com with ESMTPSA id w1sm2065598otd.40.2017.06.19.22.06.32
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 19 Jun 2017 22:06:33 -0700 (PDT)
Date: Tue, 20 Jun 2017 00:06:31 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: devel: Builtin wait infinite loop when SIGINT received
Message-ID: <20170620050631.4ok7kocrcanfoxot@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 05:06:40 -0000

There's something weird about the wait builtin + SIGINT handling in the latest
`devel' branch (i.e. 6374eecf232e70e45fe9c49cc8335e8779c07979)

If you interrupt the second `wait' with C-c, the shell will go into an infinite
loop.

  dualbus@debian:~/src/gnu/bash-builds/devel$ cat /tmp/s
  #!/bin/bash
  : &
  wait
  sleep inf &
  wait

  dualbus@debian:~/src/gnu/bash-builds/devel$ ./bash -x /tmp/s
  + wait
  + :
  + wait
  + sleep inf
  ^C^Z
  [1]+  Stopped                 ./bash -x /tmp/s
  dualbus@debian:~/src/gnu/bash-builds/devel$ kill -6 %%
  
  [1]+  Stopped                 ./bash -x /tmp/s
  dualbus@debian:~/src/gnu/bash-builds/devel$ fg
  ./bash -x /tmp/s
  Aborted (core dumped)

(I suspended the process and killed it with SIGABRT to get a nice stack trace).

  Core was generated by `./bash -x /tmp/s'.
  Program terminated with signal SIGABRT, Aborted.
  #0  wait_sigint_handler (sig=2) at ../../bash/jobs.c:2527
  2527    {
  (gdb) bt
  #0  wait_sigint_handler (sig=2) at ../../bash/jobs.c:2527
  #1  <signal handler called>
  #2  0x00007fcbc52e4fba in __GI___waitpid (pid=-1, stat_loc=0x7ffc4d9ec21c, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:29
  #3  0x0000563ed5620317 in waitchld (wpid=8312, block=1) at ../../bash/jobs.c:3566
  #4  0x0000563ed561e6a7 in wait_for (pid=8312) at ../../bash/jobs.c:2772
  #5  0x0000563ed561db90 in wait_for_single_pid (pid=8312, flags=1) at ../../bash/jobs.c:2393
  #6  0x0000563ed561df8b in wait_for_background_pids () at ../../bash/jobs.c:2461
  #7  0x0000563ed5678220 in wait_builtin (list=0x0) at ../../../bash/builtins/../../../bash/builtins/wait.def:171
  #8  0x0000563ed5609ad2 in execute_builtin (builtin=0x563ed56780c7 <wait_builtin>, words=0x563ed6ec7b48, flags=0, subshell=0) at ../../bash/execute_cmd.c:4609
  #9  0x0000563ed560aa32 in execute_builtin_or_function (words=0x563ed6ec7b48, builtin=0x563ed56780c7 <wait_builtin>, var=0x0, redirects=0x0, fds_to_close=0x563ed6ec3e08, flags=0)
      at ../../bash/execute_cmd.c:5107
  #10 0x0000563ed56093b4 in execute_simple_command (simple_command=0x563ed6ec7a08, pipe_in=-1, pipe_out=-1, async=0, fds_to_close=0x563ed6ec3e08) at ../../bash/execute_cmd.c:4395
  #11 0x0000563ed5602ac8 in execute_command_internal (command=0x563ed6ec7ec8, asynchronous=0, pipe_in=-1, pipe_out=-1, fds_to_close=0x563ed6ec3e08) at ../../bash/execute_cmd.c:811
  #12 0x0000563ed5601fe4 in execute_command (command=0x563ed6ec7ec8) at ../../bash/execute_cmd.c:393
  #13 0x0000563ed55eb51c in reader_loop () at ../../bash/eval.c:172
  #14 0x0000563ed55e8fd1 in main (argc=3, argv=0x7ffc4d9ecb38, env=0x7ffc4d9ecb58) at ../../bash/shell.c:794

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 20 01:33:17 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNBmv-0007Qc-Ce
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 01:33:17 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38231)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNBms-0007QT-RA
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:33:15 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNBmp-0005yY-M0
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:33:14 -0400
Received: from mail-ot0-x234.google.com ([2607:f8b0:4003:c0f::234]:34255)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dNBmp-0005yN-Ex
	for bug-bash@gnu.org; Tue, 20 Jun 2017 01:33:11 -0400
Received: by mail-ot0-x234.google.com with SMTP id r67so82409738ota.1
	for <bug-bash@gnu.org>; Mon, 19 Jun 2017 22:33:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=1h1EAH5YOFFIaN4PtAOZfDGrbsPtGY+lB2EJW90f4HE=;
	b=CBgku9OknhkQ7+yI3YBJlpacgAwrf7xb/P3lxXmfZ5ov64RVKFjEB4NlaVipjFELpI
	T5z+ak19MeixNqgFhBAkeBQ64h3iC7qBL0wxhtlKcYIcco0Fpub89/Rcg2SZqNA+pTE+
	EkQ2s5p+ymaCIuYMI8rRC9VBwP3ivO3NIbr7r11hkXRUY7RoMx7lFjDS+rhOtm1Yuoek
	9XdeLPxLbF2PwJ2TK0P8N4jLndOolqWYPklKpjQeRYclf8NgNknv2JTs+bKJy8QAw5j9
	DgYZ4VWMGOBOblJG0GHXi4b7MWyI2nEe6OOEvitCwcN5xG//nB3NM7ZcrrDiEwUpy6QU
	y4uw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=1h1EAH5YOFFIaN4PtAOZfDGrbsPtGY+lB2EJW90f4HE=;
	b=q53cUPwPHhbT3pubH3/BzaxaUllDwYx33t6UC9xc3LaHft51aJdLtwfWMEJTNRC7DX
	koUAu+F5LHvEsU8oM0E+QER+3PszTR+ZbB7Tejc/AfrnM5mCaeUWRtThEFmocrhM5o/0
	6LNDET9O09n1pWv9bFHwrBfvb0NZwy0mC5pYZLM7KMhut0wpB8/V1kMYgLtogC9sKOuZ
	OtlXbsfj6mIsNvBBKb+HYZMEXCk/UZuQK5rbQK6VE7CdRQVmlrKQP4hwHmsvFeRH6Mku
	95YK27u+n/mV0IpvqIgvtvE00Wg4KwJNS29gG246yz+PVy39st+NHXUreBLpdf47g3Ll
	zG4A==
X-Gm-Message-State: AKS2vOzDyKzaufjwdXzoPNpCSQRQlcSWQoIeJ2PJ9Zp6VrltnjH7ILO5
	yABwd2uj95YSaVxq
X-Received: by 10.157.34.232 with SMTP id y95mr2327109ota.63.1497936790735;
	Mon, 19 Jun 2017 22:33:10 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	e131sm5966883oia.26.2017.06.19.22.33.09
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Mon, 19 Jun 2017 22:33:09 -0700 (PDT)
Date: Tue, 20 Jun 2017 00:33:08 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Kevin Brodsky <corax26@gmail.com>
Cc: bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
Message-ID: <20170620053308.kxwjqs6gmi2ncoii@debian>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 05:33:15 -0000

On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
[...]
> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
> and not the expected IFS=$' \t\n'. All the other unquoted mass
> This is a regression that appeared in 4.3 and is still present on devel
[...]

AFAICT, the following patch fixes this.

diff --git a/subst.c b/subst.c
index 3093309f..bf73a35f 100644
--- a/subst.c
+++ b/subst.c
@@ -10158,7 +10158,7 @@ finished_with_string:
 	 or we expanded "$@" with IFS null and we need to split the positional
 	 parameters into separate words. */
       if (split_on_spaces)
-	list = list_string (istring, " ", 1);	/* XXX quoted == 1? */
+	list = list_string (istring, " \t\n", 1);	/* XXX quoted == 1? */
       /* If we have $@ (has_dollar_at != 0) and we are in a context where we
 	 don't want to split the result (W_NOSPLIT2), and we are not quoted,
 	 we have already separated the arguments with the first character of

The above code (`list_string' function call when split_on_spaces != 0)
seems to be executed when IFS is either unset or the empty string. The
comment above that block of code mentions that in either case, the
result should be "split on spaces", although it has a narrow definition
of space.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 20 05:02:15 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNF39-0005W8-1U
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 05:02:15 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50371)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dNF31-0005Vx-KG
	for bug-bash@gnu.org; Tue, 20 Jun 2017 05:02:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <bash@tlinx.org>) id 1dNF2x-0002xV-Bl
	for bug-bash@gnu.org; Tue, 20 Jun 2017 05:02:07 -0400
Received: from ishtar.tlinx.org ([173.164.175.65]:56618
	helo=Ishtar.sc.tlinx.org)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <bash@tlinx.org>) id 1dNF2x-0002vl-4a
	for bug-bash@gnu.org; Tue, 20 Jun 2017 05:02:03 -0400
Received: from [192.168.3.12] (Athenae [192.168.3.12])
	by Ishtar.sc.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id
	v5K91pgC093469; Tue, 20 Jun 2017 02:01:53 -0700
Message-ID: <5948E47F.7050102@tlinx.org>
Date: Tue, 20 Jun 2017 02:01:51 -0700
From: L A Walsh <bash@tlinx.org>
User-Agent: Thunderbird
MIME-Version: 1.0
To: Pierre Gaston <pierre.gaston@gmail.com>
CC: Chet Ramey <chet.ramey@case.edu>, bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
	<CAPSX3sRFiC+DNce7-oXnS-UkdyEgf0C1Zr0j97e1xNr5n54u=w@mail.gmail.com>
In-Reply-To: <CAPSX3sRFiC+DNce7-oXnS-UkdyEgf0C1Zr0j97e1xNr5n54u=w@mail.gmail.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
X-MIME-Autoconverted: from 8bit to quoted-printable by Ishtar.sc.tlinx.org id
	v5K91pgC093469
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 173.164.175.65
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 09:02:13 -0000



Pierre Gaston wrote:
>
>
> Your response: you accuse him to lie to you.
Huh?  Are you daft?  Just because I can't find something about bash
corrupting input in google and ask where people have said this
was said is accusing someone of lying?  Sorry, but I'm looking for
context to see exactly what was said is a far cry calling someone
a liar.

I've tried multiple searches to see where someone might have said
something about bash corrupting input -- most often I see that Nuls
are ignored or can be used as terminators.=20

I find lots of stuff about people wanting or trying to get nulls to
work with bash, with several thinking it terminates input (or a line).
But nothing about corruption. Perhaps you have pointers to this
discussion I missed?  I find various things about Nul's but nothing
mentioning their absence as being "corruption".

* BASH=E2=80=99s =E2=80=98read=E2=80=99 built-in supports '\0' as delimit=
er
 =20
(http://transnum.blogspot.com/2008/11/bashs-read-built-in-supports-0-as.h=
tml)
* And a line is by definition terminated by ascii 0, right? Newline, for
  instance, is just a formatting character?
  (an apple-darwin user - stackoverflow (SO))
* marked as 'answer' method to read null terminated lines:
   |while IFS=3D read -r -d '' line ; do ... done <<<"$var" (also SO)
* support for "-d '' " as equivalent to specifying null termination:
   * "The man page of bash reads: '-d delim  The first character of
     delim is  used  to  terminate  the input line, rather than newline.'
     Because strings are null terminated, the first character of an empty
     string is the null byte." (unix.StckExchng (unix.SE)
   * "Your read has -d $'\0'. This works because -d '' also works! It is
     the empty string, so the null byte comes immediately. -d delim uses
    "The first character of delim". (trimmed for
     brevity; same site)
* question asking why null bytes are removed from a read (unix.com); answ=
er
  was to use zsh or pdksh as they seemed to handle it.
* question asking how to use null bytes in BASH (unix.SE)
* reactionary essay on posix shells being "buggy". How anything in IFS=20
can cause
  corruption. (https://www.dwheeler.com/essays/filenames-in-shell.html)
|

Etc...
Pierre, if anyone is spreading falsehoods, it would be you in your=20
accusations.

p.s. -- Chet, if you've taken Pierre serious, I'm sorry, I am looking for
the source of the discussion, I'm not interested in accusations.




From MAILER-DAEMON Tue Jun 20 08:25:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNIEI-0006hr-Fb
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 08:25:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41407)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dNIEF-0006hf-RE
	for bug-bash@gnu.org; Tue, 20 Jun 2017 08:25:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dNIEC-0004wv-O1
	for bug-bash@gnu.org; Tue, 20 Jun 2017 08:25:55 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:39928 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dNIEC-0004tm-HN
	for bug-bash@gnu.org; Tue, 20 Jun 2017 08:25:52 -0400
Received: (qmail 7876 invoked from network); 20 Jun 2017 12:25:21 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Tue, 20 Jun 2017 08:25:21 -0400
Received: (qmail 6302 invoked by uid 563); 20 Jun 2017 12:25:21 -0000
Date: Tue, 20 Jun 2017 08:25:21 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash <bug-bash@gnu.org>
Subject: Re: Regression -- can't read input w/stderr redirect
Message-ID: <20170620122521.GA22519@eeg.ccf.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
	<CAPSX3sRFiC+DNce7-oXnS-UkdyEgf0C1Zr0j97e1xNr5n54u=w@mail.gmail.com>
	<5948E47F.7050102@tlinx.org>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <5948E47F.7050102@tlinx.org>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 12:25:56 -0000

On Tue, Jun 20, 2017 at 02:01:51AM -0700, L A Walsh wrote:
> * BASH???s ???read??? built-in supports '\0' as delimiter

Yes, but not with that syntax.  It uses the -d '' option,
which is undocumented, but supported according to
<https://lists.gnu.org/archive/html/bug-bash/2016-01/msg00121.html>.

> * And a line is by definition terminated by ascii 0, right? Newline, for
>  instance, is just a formatting character?

No, that isn't a correct statement.  A "line" is terminated by a newline.
However, there are some input sources that don't use lines.  Instead,
they use records terminated by NULs.

Once upon a time, such input sources were rare.  The original Bourne
and POSIX shells have no facilities for working with these inputs.
But bash does.

>  (an apple-darwin user - stackoverflow (SO))
> * marked as 'answer' method to read null terminated lines:
>   |while IFS= read -r -d '' line ; do ... done <<<"$var" (also SO)

That's just plain wrong.  Don't believe everything you read on
stackoverflow.

A bash variable cannot contain a NUL byte, so <<<"$var" is never going
to have NULs in it.

> * support for "-d '' " as equivalent to specifying null termination:

I cited Chet above.  That's the most official word we have.

>   * "The man page of bash reads: '-d delim  The first character of
[...]

It's not in the man page.


From MAILER-DAEMON Tue Jun 20 10:23:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNK3q-0006Bn-DW
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 10:23:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:43520)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNK3o-00065I-1n
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:23:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNK3i-0003HM-DF
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:23:16 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:16573
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNK3i-0003GT-8o
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:23:10 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANQ57340; Tue, 20 Jun 2017 10:23:05 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGE03958 (AUTH cpr);
	Tue, 20 Jun 2017 10:23:05 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Regression -- can't read input w/stderr redirect
To: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash <bug-bash@gnu.org>
References: <5946EA4D.8030004@tlinx.org>
	<6d1184ae-db2f-5d95-6aa9-7e5dc02d8388@case.edu>
	<594705DC.6000300@tlinx.org>
	<d37cfc2a-27e9-c0ef-1013-6886f93e03ee@case.edu>
	<5947344A.7020805@tlinx.org>
	<CAPSX3sRFiC+DNce7-oXnS-UkdyEgf0C1Zr0j97e1xNr5n54u=w@mail.gmail.com>
	<5948E47F.7050102@tlinx.org> <20170620122521.GA22519@eeg.ccf.org>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <8c0bc12c-4747-6081-b7bf-52262f002508@case.edu>
Date: Tue, 20 Jun 2017 10:23:04 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170620122521.GA22519@eeg.ccf.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.20.130916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODY_SIZE_600_699,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 14:23:17 -0000

On 6/20/17 8:25 AM, Greg Wooledge wrote:

>>   * "The man page of bash reads: '-d delim  The first character of
> [...]
> 
> It's not in the man page.

   -d delim
             The  first  character  of  delim is used to terminate the
             input line, rather than newline.  If delim is  the  empty
             string,  read  will  terminate a line when it reads a NUL
             character.


-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 20 10:43:18 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNKNC-00022G-0O
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 10:43:18 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:48925)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNKN9-000227-UR
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:43:17 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNKN2-0001XT-7D
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:43:15 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:46236
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNKN2-0001XL-1B
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:43:08 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMG56824; Tue, 20 Jun 2017 10:43:06 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGE07634 (AUTH cpr);
	Tue, 20 Jun 2017 10:43:05 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Read builtin -e (readline) oddities
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170619013908.x6gqolm7nv7noxmx@debian>
	<ce73f959-d1bd-0c39-b9b2-82cc7d5c6d11@case.edu>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <6247b315-bb29-1395-98d3-5c5461a96ccb@case.edu>
Date: Tue, 20 Jun 2017 10:43:05 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <ce73f959-d1bd-0c39-b9b2-82cc7d5c6d11@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.20.133017:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_1200_1299, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 14:43:17 -0000

On 6/19/17 3:40 PM, Chet Ramey wrote:

>> #3
>> Hit `C-x C-e' thrice. Also, the mapping of `\C-m' became `self-insert' instead
>> of `accept-line'.
> 
> `read -e' changes it because it's no longer the line delimiter.
> 
>>   dualbus@debian:~$ PATH= EDITOR=: read -e -d ''
>>   
>>   PATH= EDITOR=: read -e -d ''; 
>>   
>>   fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
>>   : /tmp/bash-fc.IZAzmF
>>   PATH= EDITOR=: read -e -d ''; ; 
>>   bash: syntax error near unexpected token `;'
>>   
>>   fc -e "${VISUAL:-${EDITOR:-$(command -v editor || echo emacs)}}"
>>   vim /tmp/bash-fc.35ePED
>>   ^M^M^C
> 
> I'll have to check why it doesn't get restored on ^C.

It does get restored, but the code only has one level of restoration, so
the recursive calls overwrite it.  Who's going to do multiple levels of
edit-and-execute-command?

If you want to run multiple recursive versions of edit-and-execute-
command, you should be savvy enough to get out using ^@ (control-shift-2),
right? :-)

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Tue Jun 20 10:58:59 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNKcM-0002Uk-Si
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 10:58:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52503)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNKcE-0002Oj-Iy
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:58:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNKc9-0007Xl-Ib
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:58:50 -0400
Received: from mail-ot0-x229.google.com ([2607:f8b0:4003:c0f::229]:36036)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dNKc9-0007XK-Bu
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:58:45 -0400
Received: by mail-ot0-x229.google.com with SMTP id s7so91688168otb.3
	for <bug-bash@gnu.org>; Tue, 20 Jun 2017 07:58:45 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:user-agent; bh=KLSUXbJkilCqK++fyGfU2JnF+Rj+vf3w13IKY+m+Rbw=;
	b=WZL70VuDSOenn7y3Kctbq3dNjs4Z3B63qGk5a5tuBsuIh6U3KYe1eBD4+M4+PHMDYE
	5hsnttsoCOr1F96gVcVxvkqLiZIbFTdWCvC8QKMpjH80qlUH2RXfLWuKY1X6eqXKTT3k
	nonkQxSi4dc/DMIj8psTyqxJ1N/ib02lUXmCNQtcDR384+qcodYfnSq0EKAKRJ3c2yA6
	lI/4YWQXak0IsOLfjvQBmcC6GinKhY8BlO7sNU0WU76Fhi6IR2zrSDQFH8joojDFS8a5
	3eSl7qYqaYwWlDeIw8yi3Gdk7KDCsXoKJQFyn/a3DmbyT+IY/r4+Tb/NTFm5bGebn/Xw
	oeeg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:user-agent;
	bh=KLSUXbJkilCqK++fyGfU2JnF+Rj+vf3w13IKY+m+Rbw=;
	b=Cj/qy2JpwH97+1TaerTa3Hy7MDmZgbmnJPKIcD8VgxAFZnw+umYD2ZSUFyfYA0rYfp
	wCy5Vrvd8hLsh1lQbfeYEVxIEWePopZyy3Xi9lgM7ShZX3MBLc1xd3Q7iZe6/aQSCaqw
	mRSo57W3TmSNhbiSBDg8Q5xq64YSK6QGleOq5jgZoc/aC0kpQmzrT3gIAPiD4BNhSZjc
	iGL5Sy5VHckcUydIQV9XydoTTjqWXGmvzx3Dq/8C0ugh2vC5XaseznLjHCbM/ph32ks/
	QN+weJAX4D0DU1g9JGGPI3sZEhTR56KX5nag3rajp5CHYa8Tax99r85CqPBur0K61Nin
	TW/g==
X-Gm-Message-State: AKS2vOwGttMsXmadav9JPHVFBPR+v9kFPJivIf6xbRON7gdcSDqz2ffi
	3ct0SVGeAxfTm7Sl
X-Received: by 10.157.67.157 with SMTP id t29mr11801488ote.64.1497970724146;
	Tue, 20 Jun 2017 07:58:44 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	t190sm6474176oie.29.2017.06.20.07.58.43
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Tue, 20 Jun 2017 07:58:43 -0700 (PDT)
Date: Tue, 20 Jun 2017 09:58:42 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: AddressSanitizer: heap-use-after-free in readtok | PS1='$((b[x++}]))'
Message-ID: <20170620145842.ntlrjgbzaol6tmxh@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 14:58:57 -0000

I don't know how to fix this.


dualbus@debian:~/readline$ ASAN_OPTIONS=disable_coredump=0:unmap_shadow_on_exit=1:abort_on_error=1:detect_leaks=0 ~/src/gnu/bash-builds/devel-asan/bash
bash-4.4$ PS1='$((b[x++}]))'
bash: x++}: syntax error: invalid arithmetic operator (error token is "}")
=================================================================
==11490==ERROR: AddressSanitizer: heap-use-after-free on address 0x602000001f77 at pc 0x55c081f6ad7e bp 0x7ffd7429f4a0 sp 0x7ffd7429f498
READ of size 1 at 0x602000001f77 thread T0
    #0 0x55c081f6ad7d in readtok ../../bash/expr.c:1274
    #1 0x55c081f6a32a in exp0 ../../bash/expr.c:1042
    #2 0x55c081f6a08e in exp1 ../../bash/expr.c:982
    #3 0x55c081f69f7d in exppower ../../bash/expr.c:937
    #4 0x55c081f69c62 in exp2 ../../bash/expr.c:862
    #5 0x55c081f69b76 in exp3 ../../bash/expr.c:836
    #6 0x55c081f69b07 in expshift ../../bash/expr.c:812
    #7 0x55c081f69a5a in exp4 ../../bash/expr.c:782
    #8 0x55c081f699e3 in exp5 ../../bash/expr.c:760
    #9 0x55c081f699a1 in expband ../../bash/expr.c:742
    #10 0x55c081f69963 in expbxor ../../bash/expr.c:723
    #11 0x55c081f69925 in expbor ../../bash/expr.c:704
    #12 0x55c081f69896 in expland ../../bash/expr.c:677
    #13 0x55c081f69803 in explor ../../bash/expr.c:649
    #14 0x55c081f696c6 in expcond ../../bash/expr.c:602
    #15 0x55c081f692f5 in expassign ../../bash/expr.c:487
    #16 0x55c081f69240 in expcomma ../../bash/expr.c:467
    #17 0x55c081f691cf in subexpr ../../bash/expr.c:449
    #18 0x55c081f68f2a in evalexp ../../bash/expr.c:414
    #19 0x55c081fb0527 in param_expand ../../bash/subst.c:9159
    #20 0x55c081fb2ea4 in expand_word_internal ../../bash/subst.c:9655
    #21 0x55c081f93a17 in expand_prompt_string ../../bash/subst.c:3785
    #22 0x55c081f2199d in decode_prompt_string ../../bash/parse.y:5973
    #23 0x55c081f1f71b in prompt_again ../../bash/parse.y:5484
    #24 0x55c081f11c6a in yylex ../../bash/parse.y:2677
    #25 0x55c081f068a1 in yyparse /home/dualbus/src/gnu/bash-builds/devel-asan/y.tab.c:1821
    #26 0x55c081f05a72 in parse_command ../../bash/eval.c:294
    #27 0x55c081f05cc7 in read_command ../../bash/eval.c:338
    #28 0x55c081f04f03 in reader_loop ../../bash/eval.c:140
    #29 0x55c081f006ad in main ../../bash/shell.c:794
    #30 0x7f9bcc9c02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)
    #31 0x55c081eff2a9 in _start (/home/dualbus/src/gnu/bash-builds/devel-asan/bash+0x842a9)

0x602000001f77 is located 7 bytes inside of 8-byte region [0x602000001f70,0x602000001f78)
freed by thread T0 here:
    #0 0x7f9bcd22ea10 in free (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1a10)
    #1 0x55c081f689a9 in expr_unwind ../../bash/expr.c:311
    #2 0x55c081f68e9d in evalexp ../../bash/expr.c:404
    #3 0x55c081fde64e in array_expand_index ../../bash/arrayfunc.c:947
    #4 0x55c081fdf169 in array_value_internal ../../bash/arrayfunc.c:1128
    #5 0x55c081fdf917 in get_array_value ../../bash/arrayfunc.c:1198
    #6 0x55c081f6aa51 in expr_streval ../../bash/expr.c:1179
    #7 0x55c081f6b311 in readtok ../../bash/expr.c:1343
    #8 0x55c081f691ca in subexpr ../../bash/expr.c:447
    #9 0x55c081f68f2a in evalexp ../../bash/expr.c:414
    #10 0x55c081fb0527 in param_expand ../../bash/subst.c:9159
    #11 0x55c081fb2ea4 in expand_word_internal ../../bash/subst.c:9655
    #12 0x55c081f93a17 in expand_prompt_string ../../bash/subst.c:3785
    #13 0x55c081f2199d in decode_prompt_string ../../bash/parse.y:5973
    #14 0x55c081f1f71b in prompt_again ../../bash/parse.y:5484
    #15 0x55c081f11c6a in yylex ../../bash/parse.y:2677
    #16 0x55c081f068a1 in yyparse /home/dualbus/src/gnu/bash-builds/devel-asan/y.tab.c:1821
    #17 0x55c081f05a72 in parse_command ../../bash/eval.c:294
    #18 0x55c081f05cc7 in read_command ../../bash/eval.c:338
    #19 0x55c081f04f03 in reader_loop ../../bash/eval.c:140
    #20 0x55c081f006ad in main ../../bash/shell.c:794
    #21 0x7f9bcc9c02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)

previously allocated by thread T0 here:
    #0 0x7f9bcd22ed28 in malloc (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc1d28)
    #1 0x55c08200fa54 in xmalloc ../../bash/xmalloc.c:112
    #2 0x55c081f6912e in subexpr ../../bash/expr.c:438
    #3 0x55c081f68f2a in evalexp ../../bash/expr.c:414
    #4 0x55c081fb0527 in param_expand ../../bash/subst.c:9159
    #5 0x55c081fb2ea4 in expand_word_internal ../../bash/subst.c:9655
    #6 0x55c081f93a17 in expand_prompt_string ../../bash/subst.c:3785
    #7 0x55c081f2199d in decode_prompt_string ../../bash/parse.y:5973
    #8 0x55c081f1f71b in prompt_again ../../bash/parse.y:5484
    #9 0x55c081f11c6a in yylex ../../bash/parse.y:2677
    #10 0x55c081f068a1 in yyparse /home/dualbus/src/gnu/bash-builds/devel-asan/y.tab.c:1821
    #11 0x55c081f05a72 in parse_command ../../bash/eval.c:294
    #12 0x55c081f05cc7 in read_command ../../bash/eval.c:338
    #13 0x55c081f04f03 in reader_loop ../../bash/eval.c:140
    #14 0x55c081f006ad in main ../../bash/shell.c:794
    #15 0x7f9bcc9c02b0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x202b0)

SUMMARY: AddressSanitizer: heap-use-after-free ../../bash/expr.c:1274 in readtok
Shadow bytes around the buggy address:
  0x0c047fff8390: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff83a0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff83b0: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
  0x0c047fff83c0: fa fa 02 fa fa fa 02 fa fa fa 02 fa fa fa fd fa
  0x0c047fff83d0: fa fa fd fa fa fa fd fa fa fa fd fa fa fa fd fa
=>0x0c047fff83e0: fa fa fd fa fa fa fd fa fa fa fd fa fa fa[fd]fa
  0x0c047fff83f0: fa fa 00 fa fa fa fd fd fa fa 00 02 fa fa 00 05
  0x0c047fff8400: fa fa 02 fa fa fa 01 fa fa fa 00 05 fa fa fd fd
  0x0c047fff8410: fa fa 00 00 fa fa 00 00 fa fa fd fd fa fa fd fd
  0x0c047fff8420: fa fa fd fd fa fa 00 00 fa fa 00 00 fa fa fd fd
  0x0c047fff8430: fa fa fd fa fa fa 00 04 fa fa 00 fa fa fa 00 03
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==11490==ABORTING
Segmentation fault (core dumped)


(gdb) bt
#0  0x000055c081fcd16b in termsig_sighandler (sig=6) at ../../bash/sig.c:533
#1  <signal handler called>
#2  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#3  0x00007f9bcc9d43fa in __GI_abort () at abort.c:89
#4  0x00007f9bcd248329 in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#5  0x00007f9bcd23d9ab in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#6  0x00007f9bcd237b57 in ?? () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#7  0x00007f9bcd2381e8 in __asan_report_load1 () from /usr/lib/x86_64-linux-gnu/libasan.so.3
#8  0x000055c081f6ad7e in readtok () at ../../bash/expr.c:1274
#9  0x000055c081f6a32b in exp0 () at ../../bash/expr.c:1042
#10 0x000055c081f6a08f in exp1 () at ../../bash/expr.c:982
#11 0x000055c081f69f7e in exppower () at ../../bash/expr.c:937
#12 0x000055c081f69c63 in exp2 () at ../../bash/expr.c:862
#13 0x000055c081f69b77 in exp3 () at ../../bash/expr.c:836
#14 0x000055c081f69b08 in expshift () at ../../bash/expr.c:812
#15 0x000055c081f69a5b in exp4 () at ../../bash/expr.c:782
#16 0x000055c081f699e4 in exp5 () at ../../bash/expr.c:760
#17 0x000055c081f699a2 in expband () at ../../bash/expr.c:742
#18 0x000055c081f69964 in expbxor () at ../../bash/expr.c:723
#19 0x000055c081f69926 in expbor () at ../../bash/expr.c:704
#20 0x000055c081f69897 in expland () at ../../bash/expr.c:677
#21 0x000055c081f69804 in explor () at ../../bash/expr.c:649
#22 0x000055c081f696c7 in expcond () at ../../bash/expr.c:602
#23 0x000055c081f692f6 in expassign () at ../../bash/expr.c:487
#24 0x000055c081f69241 in expcomma () at ../../bash/expr.c:467
#25 0x000055c081f691d0 in subexpr (expr=0x602000001f90 "b[x++}]") at ../../bash/expr.c:449
#26 0x000055c081f68f2b in evalexp (expr=0x602000001f90 "b[x++}]", flags=1, validp=0x7ffd7429fdc0) at ../../bash/expr.c:414
#27 0x000055c081fb0528 in param_expand (string=0x602000001ff0 "$((b[x++}]))", sindex=0x7ffd7429ffc0, quoted=1, expanded_something=0x0, contains_dollar_at=0x7ffd742a0080, 
    quoted_dollar_at_p=0x7ffd742a0000, had_quoted_null_p=0x7ffd742a0040, pflags=0) at ../../bash/subst.c:9159
#28 0x000055c081fb2ea5 in expand_word_internal (word=0x7ffd742a0240, quoted=1, isexp=0, contains_dollar_at=0x0, expanded_something=0x0) at ../../bash/subst.c:9655
#29 0x000055c081f93a18 in expand_prompt_string (string=0x604000008d50 "$((b[x++}]))", quoted=1, wflags=0) at ../../bash/subst.c:3785
#30 0x000055c081f2199e in decode_prompt_string (string=0x60200000205d "") at ../../bash/parse.y:5973
#31 0x000055c081f1f71c in prompt_again () at ../../bash/parse.y:5484
#32 0x000055c081f11c6b in yylex () at ../../bash/parse.y:2677
#33 0x000055c081f068a2 in yyparse () at y.tab.c:1821
#34 0x000055c081f05a73 in parse_command () at ../../bash/eval.c:294
#35 0x000055c081f05cc8 in read_command () at ../../bash/eval.c:338
#36 0x000055c081f04f04 in reader_loop () at ../../bash/eval.c:140
#37 0x000055c081f006ae in main (argc=1, argv=0x7ffd742a29f8, env=0x7ffd742a2a08) at ../../bash/shell.c:794

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Tue Jun 20 11:22:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNKyl-0001fn-1n
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 11:22:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41109)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <mukuntha.rajaa@nokia.com>) id 1dNJtL-0008Dp-Qb
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:12:33 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <mukuntha.rajaa@nokia.com>) id 1dNJtH-0008HQ-GF
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:12:27 -0400
Received: from mail-eopbgr20103.outbound.protection.outlook.com
	([40.107.2.103]:31170
	helo=EUR02-VE1-obe.outbound.protection.outlook.com)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <mukuntha.rajaa@nokia.com>)
	id 1dNJtG-0008HI-UC
	for bug-bash@gnu.org; Tue, 20 Jun 2017 10:12:23 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nokia.onmicrosoft.com; 
	s=selector1-nokia-com;
	h=From:Date:Subject:Message-ID:Content-Type:MIME-Version;
	bh=fn3vz4EMgqcDAzXLL2Evq4DBx+xalP4tMEeD9fEW+JQ=;
	b=hmMW5Ek1tTkdcZdVtYfpy1/jbl/sYZX6I0gphpubmMK2YToDVdjuIqhIjwNaCuCmM+axQ2uVE0esedG0UENICspF5W1we4ICiTvOBg90QEOiPq5IUaV2zP/0yQh9gQD3E/UThVaB2wtpKhD+e7dcvzdILMFu61R4NBbxbGebFAM=
Received: from VI1PR07MB1439.eurprd07.prod.outlook.com (10.165.238.21) by
	VI1PR07MB1536.eurprd07.prod.outlook.com (10.165.238.154) with Microsoft
	SMTP Server (version=TLS1_2,
	cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id
	15.1.1199.6; Tue, 20 Jun 2017 14:12:19 +0000
Received: from VI1PR07MB1439.eurprd07.prod.outlook.com
	([fe80::f4a2:dc96:7e2e:f1ab]) by
	VI1PR07MB1439.eurprd07.prod.outlook.com
	([fe80::f4a2:dc96:7e2e:f1ab%13]) with mapi id 15.01.1199.012;
	Tue, 20 Jun 2017 14:12:18 +0000
From: "Rajaa, Mukuntha (Nokia - IN/Bangalore)" <mukuntha.rajaa@nokia.com>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: bash sigabrt
Thread-Topic: bash sigabrt
Thread-Index: AdLpzvM/HMJY/QMKRZO735qB1ydsRw==
Date: Tue, 20 Jun 2017 14:12:18 +0000
Message-ID: <VI1PR07MB143934D95020853E38FD15B495C50@VI1PR07MB1439.eurprd07.prod.outlook.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
authentication-results: gnu.org; dkim=none (message not signed)
	header.d=none;gnu.org; dmarc=none action=none header.from=nokia.com;
x-originating-ip: [131.228.32.187]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; VI1PR07MB1536;
	7:jutkd/tYYVikm3RPtHPBbd1nWC7SJZDKQnZ6iRPvjCKf/Mz3uGkAjQ9yyKqaK3GgMpXjhVX+nrQEfA6MYeZlm1/dALjmVJ/yz74bihci7NMZGBLjVSz2RwSzP3G9xHbPhwsKTt5ol0k4xPjoM5hHinV7TpDMX0/AnaGRAGO+tTNwss03ihRwI+iRXP1bFEu8OSApxvDkmSoXFAsW7SGBwjCqX9lQSG+FyRemzH+wN8B9MBRvz20o8gK0r/PEtcONWOD2AGoImWtsJ02NTLhT5GDC0/6Zk3rG3PywR2x8YWFWnrNPJdVWwTRI6dnbJTQgb/mjs714MUQPYSZE3QHuPX/XDjp0voBtX4yBvv189JblBexyv+sFF2RZlRyZuyD3OrZwBDAj5mnvSpACN4VomJXcw3t18g78c5DXNKSYbCutE6eFlpfjM3JhWotMrTpwtgUV1SFfexvDwzGOoMJYdFPC/oAGlPgJmleBtr5L/rlTw0xHZsNv8+Xq9DejcJP1mpmSe075iE7cgqBbVH6PTzZfXu/TieGOJ8F0bjDFpXOV/0AlNYp/YG/bB6AxRtSuaJJo3XUmwOK0VScGGjCgEWQEH86ok6KD3x19+LZhJgwb63hPifn3NTqgiyZJLGOmcL0HgbSV+jPoWtQCbCxDe2y0jKBrkJFSFN+Ave5RccUFTUwHato04v+6f4dK//uID9+AaiIq5K0gg/V4N6D5JzLjHK9KC82BFD3hwB5SXdrRztBuHh0OEGxQ+YXlR2znFo8nx7u825ZzLfHtqMBxdR1ZoFnoGDxkJdc45oYSD68=
x-ms-office365-filtering-correlation-id: 264b2ece-e62e-4bb7-b541-08d4b7e65c6d
x-ms-office365-filtering-ht: Tenant
x-microsoft-antispam: UriScan:; BCL:0; PCL:0;
	RULEID:(300000500055)(300135000095)(300000501055)(300135300095)(300000502055)(300135100095)(22001)(2017030254075)(300000503055)(300135400095)(48565401081)(201703131423075)(201703031133081)(300000504055)(300135200095)(300000505055)(300135600095)(300000506048)(300135500095);
	SRVR:VI1PR07MB1536; 
x-ms-traffictypediagnostic: VI1PR07MB1536:
x-microsoft-antispam-prvs: <VI1PR07MB1536B38EFB5F369F09F4856F95C50@VI1PR07MB1536.eurprd07.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(250305191791016)(22074186197030)(209352067349851)(21748063052155)(211171220733660);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0;
	RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(93006095)(93001095)(10201501046)(3002001)(100000703101)(100105400095)(6055026)(6041248)(20161123555025)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(20161123562025)(20161123564025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);
	SRVR:VI1PR07MB1536; BCL:0; PCL:0;
	RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);
	SRVR:VI1PR07MB1536; 
x-forefront-prvs: 03449D5DD1
x-forefront-antispam-report: SFV:NSPM;
	SFS:(10019020)(6009001)(39840400002)(39860400002)(39850400002)(39450400003)(39400400002)(39410400002)(7696004)(110136004)(38730400002)(54356999)(55016002)(6916009)(478600001)(5250100002)(6506006)(99286003)(9686003)(6436002)(81166006)(53936002)(74316002)(6306002)(14454004)(2900100001)(5640700003)(53376002)(50986999)(305945005)(25786009)(966005)(5660300001)(7116003)(33656002)(8676002)(3480700004)(2501003)(3280700002)(8936002)(3660700001)(3846002)(6116002)(2906002)(102836003)(189998001)(221733001)(66066001)(2351001)(2004002);
	DIR:OUT; SFP:1102; SCL:1; SRVR:VI1PR07MB1536;
	H:VI1PR07MB1439.eurprd07.prod.outlook.com; FPR:; SPF:None;
	MLV:sfv; LANG:en; 
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
MIME-Version: 1.0
X-OriginatorOrg: nokia.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 20 Jun 2017 14:12:18.5731 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 5d471751-9675-428d-917b-70f44f9630b0
X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR07MB1536
X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy]
X-Received-From: 40.107.2.103
X-Mailman-Approved-At: Tue, 20 Jun 2017 11:22:06 -0400
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 14:12:33 -0000

Hi,

Bash-4.4.12(1) release occasionally coredumps. This was tested on mips64 pl=
atform. Could you please confirm, is this a known bug or should I raise a t=
icket for this ?


GNU gdb (GDB) 7.12.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.htm=
l>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "mips64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from bash...Reading symbols from /bin/bash.debug...done.
done.
[New LWP 24672]
Core was generated by `-bash'.
Program terminated with signal SIGABRT, Aborted.
#0  __GI_raise (sig=3D<optimized out>) at ../sysdeps/unix/sysv/linux/raise.=
c:58
58      ../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) t a a bt

Thread 1 (LWP 24672):
#0  __GI_raise (sig=3D<optimized out>) at ../sysdeps/unix/sysv/linux/raise.=
c:58
#1  0x000000ffe8019aa0 in __GI_abort () at abort.c:118
#2  0x0000000120050220 in programming_error (format=3D0x120117290 "free: ca=
lled with already freed block argument")
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/error.c:176
#3  0x00000001200f62e8 in xbotch (s=3D0x120117290 "free: called with alread=
y freed block argument",
    file=3Dfile@entry=3D0x1200fedc8 "/build/distro/work/shared/bash-bfb3958=
cf769d48678bf2b583dd69c6036c09e18/bashline.c",
    line=3Dline@entry=3D1828, e=3D<optimized out>, mem=3D0x1201424f8)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/malloc/malloc.c:319
#4  0x00000001200f63a8 in internal_free (mem=3D0x1201424f8,
    file=3D0x1200fedc8 "/build/distro/work/shared/bash-bfb3958cf769d48678bf=
2b583dd69c6036c09e18/bashline.c",
    line=3D<optimized out>, flags=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/malloc/malloc.c:880
#5  0x0000000120097814 in sh_xfree (string=3D<optimized out>, file=3D<optim=
ized out>, line=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/xmalloc.c:221
#6  0x0000000120089954 in command_word_completion_function (hint_text=3Dhin=
t_text@entry=3D0x120153888 "netst",
    state=3Dstate@entry=3D0) at /build/distro/work/shared/bash-bfb3958cf769=
d48678bf2b583dd69c6036c09e18/bashline.c:1828
#7  0x00000001200d4484 in rl_completion_matches (text=3D0x120153888 "netst"=
,
    entry_function=3D0x120089788 <command_word_completion_function>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/complete.c:2232
#8  0x000000012008c7a0 in bash_default_completion (text=3D0x120153888 "nets=
t", start=3D<optimized out>, end=3D<optimized out>,
    qc=3D<optimized out>, compflags=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/bashline.c:1698
#9  0x000000012008ce34 in attempt_shell_completion (text=3D0x120153888 "net=
st", start=3D<optimized out>, end=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/bashline.c:1630
#10 0x00000001200d45ec in gen_completion_matches (text=3Dtext@entry=3D0x120=
153888 "netst", start=3Dstart@entry=3D0,
    end=3D<optimized out>, our_func=3D0x1200d21a0 <rl_filename_completion_f=
unction>, found_quote=3D<optimized out>,
    quote_char=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/complete.c:1232
#11 0x00000001200d4810 in rl_complete_internal (what_to_do=3D<optimized out=
>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/complete.c:2058
#12 0x00000001200c7dcc in _rl_dispatch_subseq (key=3D<optimized out>, map=
=3D<optimized out>, got_subseq=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:859
#13 0x00000001200c82e0 in _rl_dispatch (map=3D<optimized out>, key=3D9)
---Type <return> to continue, or q <return> to quit---
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:802
#14 readline_internal_char ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:629
#15 0x00000001200c8d78 in readline_internal_charloop ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:656
#16 readline_internal ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:670
#17 readline (prompt=3D<optimized out>)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/lib/readline/readline.c:376
#18 0x0000000120023d6c in yy_readline_get () at /usr/homes/chet/src/bash/sr=
c/parse.y:1456
#19 0x00000001200266e4 in yy_getc () at /usr/homes/chet/src/bash/src/parse.=
y:1390
#20 shell_getc (remove_quoted_newline=3Dremove_quoted_newline@entry=3D1) at=
 /usr/homes/chet/src/bash/src/parse.y:2299
#21 0x000000012002a41c in read_token (command=3D0) at /usr/homes/chet/src/b=
ash/src/parse.y:3115
#22 0x000000012002e654 in yylex () at /usr/homes/chet/src/bash/src/parse.y:=
2675
#23 yyparse () at y.tab.c:1834
#24 0x0000000120022ecc in parse_command ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/eval.c:261
#25 0x0000000120023024 in read_command ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/eval.c:305
#26 0x00000001200232c8 in reader_loop ()
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/eval.c:149
#27 0x0000000120021c9c in main (argc=3D1, argv=3D0xfffffbd6d8, env=3D0xffff=
fbd6e8)
    at /build/distro/work/shared/bash-bfb3958cf769d48678bf2b583dd69c6036c09=
e18/shell.c:792
(gdb) quit


Regards,
Mukunth


From MAILER-DAEMON Tue Jun 20 11:41:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNLHy-0000xF-CG
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 11:41:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36227)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNLHu-0000x7-IO
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:41:57 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNLHt-0000Pj-O9
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:41:54 -0400
Received: from mail-qk0-x234.google.com ([2607:f8b0:400d:c09::234]:35088)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dNLHt-0000Pf-JS
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:41:53 -0400
Received: by mail-qk0-x234.google.com with SMTP id a199so60712427qkb.2
	for <bug-bash@gnu.org>; Tue, 20 Jun 2017 08:41:53 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc; bh=PoKxcz6ZElFMw7A4tv7MvLU7iOv3WJ70N7mPhpOFoDw=;
	b=TDVm+e7IzQqywpN6LhmmuHt9agWSL9bjVwRtMfgZO9pL0Wr0BapbXSS8BS0Xmhc89C
	kJ3yc+RqZs2Y1UCSyO+HyfhniGRcIC4oJUhHkaKSVjxvfmZadnjQH3JPyX3KnAMYCYN/
	Jfn2YwntIid8clxhhrjo0LL95rMV8KAbQOou/9RJvNcqGxNC95varjBCKXykAhmuFUbK
	5DvoSYGN5IVxZI+W6E1h9BXxRu+1TVoTWZq2R9uh3jr59JXMenewYkP4kN1AlWVx1LBb
	HcGYeKhhu0iDctqZWqL0/EWaKCSjdu4i2xc+Xwh6pjw4Fz8kN7BOopmGeBYBjY3VSJcm
	91uQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc;
	bh=PoKxcz6ZElFMw7A4tv7MvLU7iOv3WJ70N7mPhpOFoDw=;
	b=KNoUvZGc7dBNDlZvvF3ULshhauUNyR9O0rLM34iNylahUwLpNeReKZfvPNbPm0KeQK
	t48TWbRPBk82ok/bJeoufTju+HY3sdtyA+C0i6GQ2mLZAwbnnRZuu4pDITzHzFdMCmah
	pycCTzHoMVSqPEVHux2kbPAL+q1uSEBihkLFpqaPkPEY09W+txX38gt9SAuSro3xf9IR
	XUZbYvwlXxETuWamJLPZUl+MeLPR/ODL/a7FIr42WN6vEVUIE+yjWSMU2t+LcYr9SzBP
	LQvSS/54Y1Zi0dnlynGYMRffL1MLuLPC3Zy2uDliOnastbIJUTnC22i3o1Rx+idpP7vo
	DMKQ==
X-Gm-Message-State: AKS2vOyIOkRPPZ20UjQhXEvT4Hm2vRI1bNXT14Jsp44ms6UgO8LxvumY
	Zyfbk1RQ/zwYPOLdBA62akmKbXKx7hkY
X-Received: by 10.55.91.70 with SMTP id p67mr35424699qkb.237.1497973312973;
	Tue, 20 Jun 2017 08:41:52 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Tue, 20 Jun 2017 08:41:32 -0700 (PDT)
In-Reply-To: <VI1PR07MB143934D95020853E38FD15B495C50@VI1PR07MB1439.eurprd07.prod.outlook.com>
References: <VI1PR07MB143934D95020853E38FD15B495C50@VI1PR07MB1439.eurprd07.prod.outlook.com>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Tue, 20 Jun 2017 10:41:32 -0500
Message-ID: <CAOSMAutwdmEd=3b5=SWJo8LzmWfGPzXPC1-NpQ8Eu_AJnH+b7g@mail.gmail.com>
Subject: Re: bash sigabrt
To: "Rajaa, Mukuntha (Nokia - IN/Bangalore)" <mukuntha.rajaa@nokia.com>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 15:41:57 -0000

On Tue, Jun 20, 2017 at 9:12 AM, Rajaa, Mukuntha (Nokia -
IN/Bangalore) <mukuntha.rajaa@nokia.com> wrote:
> Hi,
>
> Bash-4.4.12(1) release occasionally coredumps. This was tested on mips64 platform. Could you please confirm, is this a known bug or should I raise a ticket for this ?

This error means that bash's internal allocator found an issue
(perhaps the code is trying to `free' a memory region that was not
allocated by it) and calls `abort()' which causes the process to end.

It looks like it crashed during completion for `netst'. Can you
reproduce this consistently? And if so, how?


From MAILER-DAEMON Tue Jun 20 11:50:14 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNLPy-0004Vd-3K
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 11:50:14 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38547)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dNLPq-0004Pk-NR
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:50:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dNLPn-0003dj-6o
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:50:06 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:43365
	helo=homiemail-a51.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dNLPm-0003ct-NA
	for bug-bash@gnu.org; Tue, 20 Jun 2017 11:50:03 -0400
Received: from homiemail-a51.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a51.g.dreamhost.com (Postfix) with ESMTP id B061A600B000; 
	Tue, 20 Jun 2017 08:49:56 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=EKzGOW7DF1LstVihuhKpFjcYKOw=; b=
	X2KexrgPXeRmdVaX1R+MNuMW6YJvyU9ivhPjxNE9jix+kmAPOuiNHig8wVV/tag2
	gDaA+1aP+8JxKd5gi2moYeT3xuDb7yHaejqbZdHbquYpe+52ut1G+/PJpU2Rsy10
	MW2hI+KgHEkrwW5m9l5suumygQXKBthRs5RMxGMoYqU=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a51.g.dreamhost.com (Postfix) with ESMTPSA id 2286B600A13F;
	Tue, 20 Jun 2017 08:49:56 -0700 (PDT)
Message-Id: <c6faa9c4b3c3386dbca1beba13265ffb276172e5@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Z" <zartaj@gmail.com>
Cc: bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <20170620033640.462tyl64fj6xcznu@debian>
Subject: Re: [PATCH] Unix domain socket filename redirection
Date: Tue, 20 Jun 2017 11:49:56 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 15:50:13 -0000

=0AUnix Domain Sockets form the basis of a lot of the modern forms of=0A=
Unix/Posix IPC. Compared to using TCP sockets for IPC, Unix Domain=0Asoc=
kets allow you to control access to the resource with filesystem=0Apermi=
ssions, and identify the socket with a file path so you don't=0Ahave to=
 come up with a system-wide-unique port number for the service.=0AIt's k=
ind of like using named pipes created with mkfifo(), except they=0Acan a=
ccept multiple connections, and you can transfer not only data=0Avalues=
 over the channel, but open file descriptors and system=0Aprivileges as=
 well.=0A=0ASo implementing Unix Domain Sockets in the shell would give=
 you the=0Aability to connect to existing services on the machine that u=
se named=0Asockets for control (systemd, dbus, cups, etc.) or you could=
 use the=0Afeature to implement new services and connect to them with sh=
ell=0Ascripts, or just use them to connect different scripts and program=
s=0Atogether for various forms of IPC.=0A=0A(As a side note, the shell s=
omewhat defines the user's operating=0Aenvironment. I think that not pro=
viding a feature because of a=0Aperception that "no one uses it" becomes=
 somewhat self-fulfilling: No=0Aone writes shell-friendly Unix Domain So=
cket servers because the shell=0Adoesn't support connecting to them, and=
 the definition of what's=0A"shell-friendly" is rather narrow.)=0A=0AI m=
entioned this in an earlier post, but I have written an=0Aimplementation=
 of socketpair, sendmsg, and recvmsg as shell loadable=0Abuilt-ins, in a=
 lib I call "shell-pepper". This makes it possible to=0Aimplement new "o=
pen a file descriptor" commands as external=0Aexecutables rather than as=
 shell built-ins:=0A=0A$ socketpair --cloexec s=C2=A0=C2=A0=C2=A0 # Crea=
tes a bidirectional Unix Domain=0Acommunication channel, stores the file=
 descriptors for the two ends in=0A${s[@]}.=0A$ connect_to_socketfile ./=
socket_to_me >&${s[1]} &=C2=A0=C2=A0 #=0A"connect_to_socketfile" is an e=
xternal command that connects to a=0Asocket and sends it over FD 1 using=
 sendmsg() and SCM_RIGHTS=0A$ recvmsg message connection_fd <&${s[0]}=C2=
=A0=C2=A0 # Receives the open file=0Adescriptor send by connect_to_named=
_socket, assigns it an unused file=0Adescriptor, and stores that FD in $=
connection_fd=0A=0AI think this speaks to the benefits of building Unix=
 Domain Socket=0Afunctionality into the shell: it allows adding other fu=
nctionality=0Alike this without having to tie it directly into the shell=
 process.=0A=0AAs for the redirection syntax, it's useful because the sh=
ell manages=0Athe lifetime of file redirections, like this:=0A=0A$ cmd <=
>/dev/unixstream/./smelly_sock=C2=A0=C2=A0 # Socket "./smelly_sock" is=
=0Aopened, used for the I/O of "cmd", and then closed by the shell=0Aaft=
erward.=0A=0AAs opposed to something like this:=0A=0A$ connect_to_socket=
file ./smelly_sock connection_fd=C2=A0=C2=A0=C2=A0 # Assuming=0A"connect=
_to_socketfile" were a built-in, rather than an external=0Acommand as it=
 is described above=0A$ cmd <>&$connection_fd=0A$ exec {connection_fd}<&=
-=C2=A0=C2=A0=C2=A0 # Explicitly close the file descriptor=0A=0AThough e=
ven with the benefits of redirection, personally I oppose the=0Aidea of=
 spoofing more fake devices in /dev. (The shell spoofs some=0Astuff in /=
dev already, and it's all long-established at this=0Apoint...=C2=A0 But=
 I don't think more such fake devices should be added.)=0AIn this patch,=
 spoofing /dev grants us the ability to specify a single=0Asocket option=
. It's not a great way to set options, though. What if=0Athe API changed=
, and we suddenly wanted to be able to specify two=0Aoptions? Specifying=
 options as command arguments is both clearer and=0Amore flexible.=0A=0A=
I've given some thought to how the two approaches could be combined:=0Au=
se a command to open a file descriptor, but bind the file=0Adescriptor's=
 lifetime to a redirection. For instance, consider this=0Aconcept for a=
 new redirection syntax:=0A=0A$ cmd <>&(connect_to_socketfile --datagram=
 ./rockem_sockem)=C2=A0=C2=A0 #=0AConnect to socketfile, bind it as stdi=
n and stdout for running "cmd",=0Athen undo the redirection and close th=
e socket=0A=0AIn this hypothetical model, the redirection syntax <&(fd_c=
md) runs=0A"fd_cmd" with its output redirected to one end of a socketpai=
r.=0A"connect_to_socketfile" creates the connection then tries to send i=
t=0Aover file descriptor 1 using sendmsg() and SCM_RIGHTS (see "man 7=0A=
unix")=0A The shell process listens to the other end of the socketpair,=
=0Aexpecting to receive a file descriptor. If it does receive a file=0Ad=
escriptor, it uses that FD for the redirection, and then disposes of=0Ai=
t when the job is done.=0A(And if "connect_to_socketfile" returns nonzer=
o status, or doesn't=0Asend exactly one file descriptor over its output=
 socket, then the=0Aredirection fails and the command is aborted.)=0A=0A=
That said, there are always problems with introducing new syntax...=C2=
=A0=0AI don't know if this specific syntax would be viable (and it's har=
d to=0Acome up with syntax that seems conceptually coherent with other f=
orms=0Aof redirection and substitution) but I think something like this=
 could=0Abe useful as a way to add new functionality like this to the sh=
ell,=0Aand take advantage of redirection semantics, without having to=0A=
integrate the implementation of each new feature into the shell.=0A=0AAn=
d it's worth noting that while Unix Domain Socket functionality is=0Awid=
espread, established as part of POSIX 2001 and all that, it's not=0Auniv=
ersally-supported on all (especially older) platforms Bash=0Asupports. S=
o even if it were integrated into the shell, it still must=0Abe consider=
ed an optional feature. It may be possible to provide a=0Asingle interfa=
ce that would also cover other APIs with similar=0Afeatures (the STREAMS=
 API maybe?)=0A=0A----- Original Message -----=0AFrom: =0ATo:"Z" <zartaj=
@gmail.com>=0ACc:<bug-bash@gnu.org>=0ASent:Mon, 19 Jun 2017 22:36:40 -05=
00=0ASubject:Re: [PATCH] Unix domain socket filename redirection=0A=0A O=
n Mon, Jun 19, 2017 at 07:30:42PM -0400, Z wrote:=0A > This patch adds s=
upport for Unix domain sockets. A filename of the=0Aform=0A > /dev/unixs=
tream/path used in a redirection makes bash attempt to=0Aopen a=0A > con=
nection to the Unix domain stream socket at /path. Similarly a=0Afilenam=
e=0A > of the form /dev/unixdgram/path makes bash attempt to open a=0Aco=
nnection to=0A > the Unix domain datagram socket at /path.=0A=0A Excuse=
 my ignorance:=0A=0A - What would be an expected use case of this featur=
e? /dev/tcp and=0A /dev/udp are commonly used because it allows the shel=
l script writer=0A to interact with popular text based protocols like HT=
TP or SMTP. It=0A would seem that this UNIX domain socket patch targets=
 a niche=0Ainstead?=0A=0A - Why should this be integrated into the core=
 of bash, and not=0Aprovided=0A as a loadable builtin instead? It makes=
 more sense to me to provide=0A this as an optional shell builtin, which=
 also make the usage less=0A awkward (not a fan of the /dev/unixstream/t=
he/path/is/here thing).=0A=0A By the way, the patch does not apply. It w=
ould seem like you=0Acopy-pasted=0A the diff, so it got wrapped at some=
 points and git is rejecting it.=0A=0A -- =0A Eduardo Bustamante=0A http=
s://dualbus.me/=0A=0A

From MAILER-DAEMON Tue Jun 20 19:07:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNSF1-0003OP-Vz
	for mharc-bug-bash@gnu.org; Tue, 20 Jun 2017 19:07:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57580)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNSEz-0003O3-IS
	for bug-bash@gnu.org; Tue, 20 Jun 2017 19:07:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNSEw-00073t-CC
	for bug-bash@gnu.org; Tue, 20 Jun 2017 19:07:21 -0400
Received: from mail-wr0-x22d.google.com ([2a00:1450:400c:c0c::22d]:36741)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <corax26@gmail.com>) id 1dNSEw-00073f-5a
	for bug-bash@gnu.org; Tue, 20 Jun 2017 19:07:18 -0400
Received: by mail-wr0-x22d.google.com with SMTP id c11so55513161wrc.3
	for <bug-bash@gnu.org>; Tue, 20 Jun 2017 16:07:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-transfer-encoding:content-language;
	bh=j+gA3MbW7wZgf603Crz1ZUeL6yqPG4INOT5l7+dn2DI=;
	b=nv0YL5lNteTTwnS44WcBEh/O/illAyESQdyQ4hB9xqmmLlERO7DvLep2jjXP+IFksw
	7mFSuENmeQ6K0WzG5WneW7eLc62jIGl4xoSiUls2F9QTrToQnViF1ltZzpLJ3aKazfQi
	dIa1ps29LZdFl1GRgIrA8xVTCf6yt1tYaFohQTZR7lCPgb1LYO/X1FurAP2AATDu/MqD
	MHvhnwju5EMIghHMuKHtYPZ10msDLetBVtbJmHdUfd30INdZ0w27f4shO7eWau9SCkho
	OmlvT4xXTwgyo0Tl4p3tzkjqYMRqoaMwWD0MgIKlO+QzGftcWEfGeCCQ38xivDq7oAiE
	A8sw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:cc:references:from:message-id:date
	:user-agent:mime-version:in-reply-to:content-transfer-encoding
	:content-language;
	bh=j+gA3MbW7wZgf603Crz1ZUeL6yqPG4INOT5l7+dn2DI=;
	b=B+KkHphGtvAfnMsQqJLPL3tI4Ls5fWIE6VnSzuTZVX3MqiFWHNpR0A7waKsSnM+XQM
	kqCmuJtcFm5ur6iEly051zq1jkz5h5KLnEDOQmo4QQyU8GbAsLdRcv0Xyw9gzmUQdcwx
	jUIPbYSwPOVWHfkamLqJS2cFlDORitttrUFL5j/BJFFW5PKJaSZWSVXgNtLmOFwaKQI2
	TxYbLNKMdiCNZkH64OmY75HOGyNTAHOtMxHEwvGdFpM6eLzxNU7x+GOozaAIt31HPa0i
	pQp5vV3nO0fgGHdzQd+HQObB6b6/NmKiIP1RxnxTx+nVqUhKt+vhUGMmO7tnYT7YfSoG
	OAlQ==
X-Gm-Message-State: AKS2vOwVCWGvFFV43zf/XPYb3fz1HGjz5yQhduHChr/NMGlT6GcBi22m
	qUi3z7HNNVMdbcxd
X-Received: by 10.223.136.37 with SMTP id d34mr23144777wrd.160.1498000036333; 
	Tue, 20 Jun 2017 16:07:16 -0700 (PDT)
Received: from [192.168.0.10] (180.190.9.51.dyn.plus.net. [51.9.190.180])
	by smtp.googlemail.com with ESMTPSA id
	w79sm9360405wrc.33.2017.06.20.16.07.15
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 20 Jun 2017 16:07:15 -0700 (PDT)
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: =?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?= <dualbus@gmail.com>
Cc: bug-bash@gnu.org
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
From: Kevin Brodsky <corax26@gmail.com>
Message-ID: <9c482e81-f6e5-b1d7-122b-7584699589e1@gmail.com>
Date: Wed, 21 Jun 2017 00:07:14 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170620053308.kxwjqs6gmi2ncoii@debian>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Content-Language: en-GB
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::22d
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Tue, 20 Jun 2017 23:07:22 -0000

On 20/06/2017 06:33, Eduardo A. Bustamante López wrote:
> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
> [...]
>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>> and not the expected IFS=$' \t\n'. All the other unquoted mass
>> This is a regression that appeared in 4.3 and is still present on devel
> [...]
>
> AFAICT, the following patch fixes this.
>
> diff --git a/subst.c b/subst.c
> index 3093309f..bf73a35f 100644
> --- a/subst.c
> +++ b/subst.c
> @@ -10158,7 +10158,7 @@ finished_with_string:
>  	 or we expanded "$@" with IFS null and we need to split the positional
>  	 parameters into separate words. */
>        if (split_on_spaces)
> -	list = list_string (istring, " ", 1);	/* XXX quoted == 1? */
> +	list = list_string (istring, " \t\n", 1);	/* XXX quoted == 1? */
>        /* If we have $@ (has_dollar_at != 0) and we are in a context where we
>  	 don't want to split the result (W_NOSPLIT2), and we are not quoted,
>  	 we have already separated the arguments with the first character of
>
> The above code (`list_string' function call when split_on_spaces != 0)
> seems to be executed when IFS is either unset or the empty string. The
> comment above that block of code mentions that in either case, the
> result should be "split on spaces", although it has a narrow definition
> of space.
>

The comments about "IFS either unset or null" confuse me, because word
splitting should behave very differently when IFS is null (there is no
word splitting at all, whereas unset IFS is equivalent to IFS=$' \t\n').
My tests show that the behaviour is as expected when IFS is null, so I'm
wondering if the comments match the actual behaviour.

Kevin


From MAILER-DAEMON Wed Jun 21 00:48:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNXYp-00034T-JA
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 00:48:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49853)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNXYm-00033u-ST
	for bug-bash@gnu.org; Wed, 21 Jun 2017 00:48:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dNXYi-0008Vb-UT
	for bug-bash@gnu.org; Wed, 21 Jun 2017 00:48:08 -0400
Received: from mail-ot0-x242.google.com ([2607:f8b0:4003:c0f::242]:33375)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dNXYi-0008UR-Oh
	for bug-bash@gnu.org; Wed, 21 Jun 2017 00:48:04 -0400
Received: by mail-ot0-x242.google.com with SMTP id q16so14921196otb.0
	for <bug-bash@gnu.org>; Tue, 20 Jun 2017 21:48:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:content-transfer-encoding:in-reply-to
	:user-agent; bh=QyygDoEgplCkY6y9/SlXLAwkeEw+81Nzq3BHwpuYIak=;
	b=ErsMYHpz9JekA8Uy0Srk1ixsRehSFPqkpP6UdGej558zipKLUlQY5rokL6EmpVUPQv
	HH57p/WZYmMgCHgLkJGlLwCx2YE6H/ib3VUMM/8SG6U5nn13nyPGYjIUUSOCGVY//ufY
	Y1Gfg9+tSBwcQAgoKqi+I8unPgpCQEQKMogXHS292DW99VSun4Sgg/Lz/A9C9rdsEfCw
	OlQBvNvwUVpijkzp+EyLEMXo/6lzWZczCMz8s/w0BbFlYzwrWIvd0aGUb0L2lqIttvWL
	ZjMjZCv1kMO6q6j68VsG+K18KbOPsuBwZrUUl8DLm8cNFLWfGnhhERCtwNDvCsI5GWnv
	9mvA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:content-transfer-encoding
	:in-reply-to:user-agent;
	bh=QyygDoEgplCkY6y9/SlXLAwkeEw+81Nzq3BHwpuYIak=;
	b=sj8xKkYjPv/OvXgrpXKLUYrrEa05P+Np76GgfktbBi+aT+vMnucdia7+wYWb0IV9pi
	HgE9XvIEBAI0WL4jbd04ubLwfG2KO2V+jMwsRBeO1V8UTytjsgs1v0LsV+8p79QuP0zy
	D6Cfvv/B7VwwdTdI02XI24SBGJfJi8cCVVXKVARprD7XLti5i4KbLrUgoihSsVQygG4g
	wdNF42XAv9niy9uiI9k1c1CCyRiT9eVs/5fWWM7z4hP4208OdZi+v6JUdSvB6YGsfb9L
	tpDSxcGyGUzefuEENOBMRsRKcpqA2hxQjfEFrKkmkn8a+TAkyw4G6NO9TcgRn9BK9Yq0
	2CFQ==
X-Gm-Message-State: AKS2vOzl+CUh9j6yJwJoPrsAfzm0Z69hClCGTZxEwbgJdI1LkRfdtcOn
	M/nBHqcGUQfkWw==
X-Received: by 10.157.16.8 with SMTP id h8mr20010603ote.80.1498020482086;
	Tue, 20 Jun 2017 21:48:02 -0700 (PDT)
Received: from localhost ([201.157.173.180]) by smtp.gmail.com with ESMTPSA id
	o16sm8661667oto.45.2017.06.20.21.48.00
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Tue, 20 Jun 2017 21:48:00 -0700 (PDT)
Date: Tue, 20 Jun 2017 23:47:59 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: tetsujin@scope-eye.net
Cc: Z <zartaj@gmail.com>, bug-bash@gnu.org
Subject: Re: [PATCH] Unix domain socket filename redirection
Message-ID: <20170621044759.raqif4pobndcqqwf@debian>
References: <20170620033640.462tyl64fj6xcznu@debian>
	<c6faa9c4b3c3386dbca1beba13265ffb276172e5@webmail.scope-eye.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <c6faa9c4b3c3386dbca1beba13265ffb276172e5@webmail.scope-eye.net>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::242
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 04:48:10 -0000

On Tue, Jun 20, 2017 at 11:49:56AM -0400, tetsujin@scope-eye.net wrote:
[...]
> So implementing Unix Domain Sockets in the shell would give you the
> ability to connect to existing services on the machine that use named
> sockets for control (systemd, dbus, cups, etc.) or you could use the
> feature to implement new services and connect to them with shell
> scripts, or just use them to connect different scripts and programs
> together for various forms of IPC.

AFAICT, dbus uses a binary wire protocol [1], so we will also need a
new builtin that provides some of the functionality to read binary data
as described by Pierre in [2]. My point: in order to do something useful
with UNIX domain sockets, which in my experience are usually binary wire
protocols, bash would need a robust mechanism to read, manipulate, and
write binary strings. Why not implement both as loadable builtins?

> (As a side note, the shell somewhat defines the user's operating
> environment. I think that not providing a feature because of a
> perception that "no one uses it" becomes somewhat self-fulfilling: No
> one writes shell-friendly Unix Domain Socket servers because the shell
> doesn't support connecting to them, and the definition of what's
> "shell-friendly" is rather narrow.)

I didn't claim that this feature is not desired or useful. I just
claimed that it seems to be targetted to a very small set of users. And
if this is correct, it might be better to provide this functionality as
a loadable builtin. I'm happy to be proven wrong here.

> Though even with the benefits of redirection, personally I oppose the
> idea of spoofing more fake devices in /dev. (The shell spoofs some
> stuff in /dev already, and it's all long-established at this
> point...  But I don't think more such fake devices should be added.)
> In this patch, spoofing /dev grants us the ability to specify a single
> socket option. It's not a great way to set options, though. What if
> the API changed, and we suddenly wanted to be able to specify two
> options? Specifying options as command arguments is both clearer and
> more flexible.

I agree.

> I've given some thought to how the two approaches could be combined:
> use a command to open a file descriptor, but bind the file
> descriptor's lifetime to a redirection. For instance, consider this
> concept for a new redirection syntax:

I'm more in favor of a shell builtin, with the user having to explicity
close the descriptors, instead of bloating the parser. It is incredibly
complex as it is now. Please don't add more complexity.

[1] https://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-marshaling
[2] https://lists.gnu.org/archive/html/bug-bash/2017-06/msg00096.html

P.S. I enjoy reading your emails, but please, get a better MUA!

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Wed Jun 21 04:16:05 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNao1-0006bk-24
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 04:16:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55592)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <mukuntha.rajaa@nokia.com>) id 1dNanx-0006be-UZ
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:16:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <mukuntha.rajaa@nokia.com>) id 1dNant-0005Dt-9Y
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:16:01 -0400
Received: from mail-he1eur01on0121.outbound.protection.outlook.com
	([104.47.0.121]:20704
	helo=EUR01-HE1-obe.outbound.protection.outlook.com)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <mukuntha.rajaa@nokia.com>)
	id 1dNans-0005Cw-KP
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:15:57 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nokia.onmicrosoft.com; 
	s=selector1-nokia-com;
	h=From:Date:Subject:Message-ID:Content-Type:MIME-Version;
	bh=H1AKl+gqckIi7C1KqjoHKbqId3ZVhcakab4JfC0/MJI=;
	b=tY9PoTUtVrfO86FICdGu+EFV56vP/tZ+JIgt/wbL4c7aKWXKYU2pamKYuFXnGIrMFra4Kh4RSNpVQ5mTQ+a/qpkAUht1M5SQze/9p5kZU5P58oY1SjJhZPocRLjJ0ZuIvMICf7BfxHGmrd8Xb9h1nZcoSf1kATTKgo9lXuZM6/U=
Received: from VI1PR07MB1439.eurprd07.prod.outlook.com (10.165.238.21) by
	VI1PR07MB1294.eurprd07.prod.outlook.com (10.164.92.24) with Microsoft
	SMTP Server (version=TLS1_2,
	cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id
	15.1.1199.6; Wed, 21 Jun 2017 08:15:53 +0000
Received: from VI1PR07MB1439.eurprd07.prod.outlook.com
	([fe80::f4a2:dc96:7e2e:f1ab]) by
	VI1PR07MB1439.eurprd07.prod.outlook.com
	([fe80::f4a2:dc96:7e2e:f1ab%13]) with mapi id 15.01.1199.012;
	Wed, 21 Jun 2017 08:15:53 +0000
From: "Rajaa, Mukuntha (Nokia - IN/Bangalore)" <mukuntha.rajaa@nokia.com>
To: Eduardo Bustamante <dualbus@gmail.com>
CC: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: RE: bash sigabrt
Thread-Topic: bash sigabrt
Thread-Index: AdLpzvM/HMJY/QMKRZO735qB1ydsRwADL2EAACKwfwA=
Date: Wed, 21 Jun 2017 08:15:52 +0000
Message-ID: <VI1PR07MB1439C948A5BF4A3C3F000EC595DA0@VI1PR07MB1439.eurprd07.prod.outlook.com>
References: <VI1PR07MB143934D95020853E38FD15B495C50@VI1PR07MB1439.eurprd07.prod.outlook.com>
	<CAOSMAutwdmEd=3b5=SWJo8LzmWfGPzXPC1-NpQ8Eu_AJnH+b7g@mail.gmail.com>
In-Reply-To: <CAOSMAutwdmEd=3b5=SWJo8LzmWfGPzXPC1-NpQ8Eu_AJnH+b7g@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
authentication-results: gmail.com; dkim=none (message not signed)
	header.d=none; gmail.com; dmarc=none action=none header.from=nokia.com; 
x-originating-ip: [131.228.32.164]
x-ms-publictraffictype: Email
x-microsoft-exchange-diagnostics: 1; VI1PR07MB1294;
	7:JbOOvtgigD0H6ZChhZ5hs+EWc6d/sBMbt9+2Bhvyu/G2Pj/r+K4QgNxjeLmFKNznPtGqfwNdjCVddZ8dezIWK70PjUY/8KDUmgEf6UlHgYyhMUuP3Jhtq9OmQdH2jETQ2m7Oh2tB/5nYm5A+DFb4E9VGvxjpN1d2xhxI/i2IAoiTTXByJ/v0XwBMvM/HDKXXC/aSyh5U7rX7mOcYhLCjYbOQUrcZyXo1LpA07O/LqdoS379MasWCrgAuBKmlx9NxYyMKUS5sbgllXx3+9OaVxRyweBvACh+HXiSGWj8sTXwrhpkmeIemWvkxMAeCnJWGEt4USusW1FcTznQzVwmc53LDS2gVLzgieCNBabunFMcJpGdFFXkndwwkyz73PvPMieyySY28zw2y05rKUeNfSD/Fl1ro99zK0RgihmLyRwt5FrOBTWHMGlDgYb0YpBbm2xKb/oWkr8/y+hwBq0ll84kVMaaQTLvHOWZIZjxw4omT7vvKlH3yQxR3N1rqO6xOoqxDQpUr7UjWTZkERK2i9pGnK5xf7KYCkZho9Ibwuheh49YlanNoJjjiFOivCSex1KxZU+P/irwxsl0w5sdQqat+lNHWpSuwuuPqP7UayNbHoak6nPxLObheeXxn7jgLjDPfArWCFK/lVV/JMe1j58MriN7s8dWaUWsjhYaH5/UprhU1biVUZcT8MXrziJtSdScDPlp8cZpUctVo+8skmtWLXRtZhlRW5y2Ka8VN7+swgqabJRItnsOKtKxTJmHbed4FvsFdn3EAD07GupBmIoqkBYx/WVq+3KCVlmPmCBw=
x-ms-office365-filtering-correlation-id: adad620d-add7-4118-3954-08d4b87dbc09
x-ms-office365-filtering-ht: Tenant
x-microsoft-antispam: UriScan:; BCL:0; PCL:0;
	RULEID:(22001)(2017030254075)(48565401081)(201703131423075)(201703031133081)(201702281549075);
	SRVR:VI1PR07MB1294; 
x-ms-traffictypediagnostic: VI1PR07MB1294:
x-microsoft-antispam-prvs: <VI1PR07MB1294353AC31A57B007DADBFC95DA0@VI1PR07MB1294.eurprd07.prod.outlook.com>
x-exchange-antispam-report-test: UriScan:(22074186197030)(82608151540597);
x-exchange-antispam-report-cfa-test: BCL:0; PCL:0;
	RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(10201501046)(100000703101)(100105400095)(3002001)(93006095)(93001095)(6055026)(6041248)(20161123555025)(20161123564025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123558100)(20161123560025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095);
	SRVR:VI1PR07MB1294; BCL:0; PCL:0;
	RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);
	SRVR:VI1PR07MB1294; 
x-forefront-prvs: 0345CFD558
x-forefront-antispam-report: SFV:NSPM;
	SFS:(10019020)(6009001)(39840400002)(39450400003)(39410400002)(39400400002)(39850400002)(39860400002)(13464003)(24454002)(377454003)(33656002)(25786009)(102836003)(14454004)(189998001)(478600001)(229853002)(305945005)(7736002)(3280700002)(3660700001)(6436002)(54356999)(8936002)(76176999)(99286003)(55016002)(74316002)(9686003)(3480700004)(6116002)(5660300001)(3846002)(50986999)(6506006)(7116003)(2906002)(4326008)(1411001)(39060400002)(38730400002)(81166006)(110136004)(2900100001)(66066001)(2950100002)(221733001)(86362001)(7696004)(53936002)(6916009)(8676002)(5250100002)(6246003)(53546010)(111123002);
	DIR:OUT; SFP:1102; SCL:1; SRVR:VI1PR07MB1294;
	H:VI1PR07MB1439.eurprd07.prod.outlook.com; FPR:; SPF:None;
	MLV:ovrnspm; PTR:InfoNoRecords; LANG:en; 
spamdiagnosticoutput: 1:99
spamdiagnosticmetadata: NSPM
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: nokia.com
X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Jun 2017 08:15:52.9976 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 5d471751-9675-428d-917b-70f44f9630b0
X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR07MB1294
X-detected-operating-system: by eggs.gnu.org: Windows 7 or 8 [fuzzy]
X-Received-From: 104.47.0.121
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 08:16:03 -0000

SGksDQoNCk5vIHRoaXMgaXMgYW4gb2NjYXNpb25hbCBpc3N1ZSBhbmQgdGhlcmUgaXMgbm8gcmVw
cm9kdWNlciB5ZXQuIA0KDQpSZWdhcmRzLA0KTXVrdW50aA0KDQotLS0tLU9yaWdpbmFsIE1lc3Nh
Z2UtLS0tLQ0KRnJvbTogRWR1YXJkbyBCdXN0YW1hbnRlIFttYWlsdG86ZHVhbGJ1c0BnbWFpbC5j
b21dIA0KU2VudDogVHVlc2RheSwgSnVuZSAyMCwgMjAxNyA5OjEyIFBNDQpUbzogUmFqYWEsIE11
a3VudGhhIChOb2tpYSAtIElOL0JhbmdhbG9yZSkgPG11a3VudGhhLnJhamFhQG5va2lhLmNvbT4N
CkNjOiBidWctYmFzaEBnbnUub3JnDQpTdWJqZWN0OiBSZTogYmFzaCBzaWdhYnJ0DQoNCk9uIFR1
ZSwgSnVuIDIwLCAyMDE3IGF0IDk6MTIgQU0sIFJhamFhLCBNdWt1bnRoYSAoTm9raWEgLQ0KSU4v
QmFuZ2Fsb3JlKSA8bXVrdW50aGEucmFqYWFAbm9raWEuY29tPiB3cm90ZToNCj4gSGksDQo+DQo+
IEJhc2gtNC40LjEyKDEpIHJlbGVhc2Ugb2NjYXNpb25hbGx5IGNvcmVkdW1wcy4gVGhpcyB3YXMg
dGVzdGVkIG9uIG1pcHM2NCBwbGF0Zm9ybS4gQ291bGQgeW91IHBsZWFzZSBjb25maXJtLCBpcyB0
aGlzIGEga25vd24gYnVnIG9yIHNob3VsZCBJIHJhaXNlIGEgdGlja2V0IGZvciB0aGlzID8NCg0K
VGhpcyBlcnJvciBtZWFucyB0aGF0IGJhc2gncyBpbnRlcm5hbCBhbGxvY2F0b3IgZm91bmQgYW4g
aXNzdWUNCihwZXJoYXBzIHRoZSBjb2RlIGlzIHRyeWluZyB0byBgZnJlZScgYSBtZW1vcnkgcmVn
aW9uIHRoYXQgd2FzIG5vdA0KYWxsb2NhdGVkIGJ5IGl0KSBhbmQgY2FsbHMgYGFib3J0KCknIHdo
aWNoIGNhdXNlcyB0aGUgcHJvY2VzcyB0byBlbmQuDQoNCkl0IGxvb2tzIGxpa2UgaXQgY3Jhc2hl
ZCBkdXJpbmcgY29tcGxldGlvbiBmb3IgYG5ldHN0Jy4gQ2FuIHlvdQ0KcmVwcm9kdWNlIHRoaXMg
Y29uc2lzdGVudGx5PyBBbmQgaWYgc28sIGhvdz8NCg==


From MAILER-DAEMON Wed Jun 21 04:17:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNapk-0006rl-Fa
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 04:17:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55962)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dNaph-0006rW-JV
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:17:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dNapc-0005lH-Hc
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:17:49 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:43900
	helo=homiemail-a40.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dNapc-0005kb-55
	for bug-bash@gnu.org; Wed, 21 Jun 2017 04:17:44 -0400
Received: from homiemail-a40.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a40.g.dreamhost.com (Postfix) with ESMTP id AE19F6004413; 
	Wed, 21 Jun 2017 01:17:41 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:cc:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=aKYYUDNZ9YHvKnjV
	hE1QXmny+iA=; b=PWUp7aSbEzNiC+S8PK2DQmIkGuHtiKBHo6fydp+UAp/SG8yj
	DFdKrJIwCUMYCVgFkKTKp4dvU2gvthLL0iQUJ7HAQshNO28F6LQLTFxISkNeTbHt
	LY7ozFgvPGfUwaJxk+7D/JBI6wc7oW3Tw+ZrnCTsVo1JmoihBEUqX4K7klQ=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a40.g.dreamhost.com (Postfix) with ESMTPSA id 432F36004407;
	Wed, 21 Jun 2017 01:17:41 -0700 (PDT)
Message-ID: <1498033060.1800.89.camel@scope-eye.net>
Subject: Re: [PATCH] Unix domain socket filename redirection
From: George <tetsujin@scope-eye.net>
To: "Eduardo A. Bustamante" =?ISO-8859-1?Q?L=F3pez?= <dualbus@gmail.com>
Cc: Z <zartaj@gmail.com>, bug-bash@gnu.org
Date: Wed, 21 Jun 2017 04:17:40 -0400
In-Reply-To: <20170621044759.raqif4pobndcqqwf@debian>
References: <20170620033640.462tyl64fj6xcznu@debian>
	<c6faa9c4b3c3386dbca1beba13265ffb276172e5@webmail.scope-eye.net>
	<20170621044759.raqif4pobndcqqwf@debian>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 08:17:51 -0000

On Tue, 2017-06-20 at 23:47 -0500, Eduardo A. Bustamante L=C3=B3pez wrote=
:
> On Tue, Jun 20, 2017 at 11:49:56AM -0400, tetsujin@scope-eye.net wrote:
> [...]
> >=20
> > So implementing Unix Domain Sockets in the shell would give you the
> > ability to connect to existing services on the machine that use named
> > sockets for control (systemd, dbus, cups, etc.) or you could use the
> > feature to implement new services and connect to them with shell
> > scripts, or just use them to connect different scripts and programs
> > together for various forms of IPC.
> AFAICT, dbus uses a binary wire protocol [1], so we will also need a
> new builtin that provides some of the functionality to read binary data
> as described by Pierre in [2]. My point: in order to do something usefu=
l
> with UNIX domain sockets, which in my experience are usually binary wir=
e
> protocols, bash would need a robust mechanism to read, manipulate, and
> write binary strings. Why not implement both as loadable builtins?
> >=20
> > I've given some thought to how the two approaches could be combined:
> > use a command to open a file descriptor, but bind the file
> > descriptor's lifetime to a redirection. For instance, consider this
> > concept for a new redirection syntax:
> >=20

>=20
>=20
> I'm more in favor of a shell builtin, with the user having to explicity
> close the descriptors, instead of bloating the parser. It is incredibly
> complex as it is now. Please don't add more complexity.
>=20
>=20

> P.S. I enjoy reading your emails, but please, get a better MUA!
>=20
>=20

Certainly I'd have no objections to *also* having the ability to work wit=
h binary data in the shell, in addition to the ability to work with unix
domain sockets. And this is absolutely the sort of thing I try to address=
 in the library I'm working on. But I haven't been able to figure out an
approach I'm happy with yet. Because of the way Bash variables work inter=
nally, there has to be the textual representation stored in memory, and
there's really no provision to store anything else as part of the variabl=
e. So effectively you store the data twice, more than doubling the storag=
e
requirements. At that point you may as well just use a storage solution t=
hat _merely_ doubles the storage requirements, like hexadecimal. I don't =
love
that kind of approach (kind of on principle I'd prefer to avoid solutions=
 that require dealing with a transfromed version of the data, rather than=
 the
actual data) but it works.
As for the redirection syntax... =C2=A0I guess new syntax is a bit much t=
o hope for, but when faced with a situation like this I try to look for a=
 solution
that will be generally useful. In this case, the discussion started with =
a patch to add a new connection method to the redirection syntax. Adding =
one
such feature isn't a big deal. But I look at the situation and think, wou=
ldn't it be nice to have a more general solution that could address this
case, and future ones as well? The redirection syntax concept does that, =
though the cost of adding syntax to the language is indeed not to be take=
n
lightly.
Generally speaking, having explored file descriptor passing functionality=
 a bit in the shell, it would be nice if the shell could support it a bit
better. For instance, this command in ksh + shell-pepper:
$ connect_to_socketfile ./s | recvmsg m fd
works in ksh because it's got the equivalent of "lastpipe", and because p=
ipes in ksh jobs are actually socket pairs, so FDs can be passed over the=
m.
In Bash, because the pipe syntax creates a pipe and not a socketpair, the=
 caller must bascially create the pipeline themselves:
$ socketpair --cloexec s
$ connect_to_socketfile ./s >&${s[1]} &
$ recvmsg m fd <&${s[0]}
$ exec {s[0]}<&-
$ exec {s[1]}<&-
It makes the functionality feel much more alien. There are consequences t=
o ksh's choice to use socketpairs rather than pipes (for instance this br=
eaks /dev/fd on linux... =C2=A0Because the implementation of /dev/fd on L=
inux is kind of dumb generally.) but it makes other Unix domain socket fu=
nctionality integrate quite nicely.

From MAILER-DAEMON Wed Jun 21 08:53:50 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNf8o-0001tK-9W
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 08:53:50 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35116)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNf8j-0001bY-8t
	for bug-bash@gnu.org; Wed, 21 Jun 2017 08:53:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNf8h-0006T7-7r
	for bug-bash@gnu.org; Wed, 21 Jun 2017 08:53:45 -0400
Received: from mail-oi0-x242.google.com ([2607:f8b0:4003:c06::242]:34102)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <zartaj@gmail.com>) id 1dNf8h-0006Sg-14
	for bug-bash@gnu.org; Wed, 21 Jun 2017 08:53:43 -0400
Received: by mail-oi0-x242.google.com with SMTP id b6so1336301oia.1
	for <bug-bash@gnu.org>; Wed, 21 Jun 2017 05:53:41 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:from:date:message-id:subject:to;
	bh=c8XLy6LXdTK74RxFDPRCE/aJcrd20wxYbsizszogTxI=;
	b=mewbYtWqhnm4BImlSmoABk/R0mCuU6l20MFdbUdzcjERm4iLYv55sRfzNH0z2xH4Iw
	3Id0xPBcTfZSTV4GWo01MMkThLmExS3rl981kTg6zMD+gBuMqL60FP0aR3fewE3HcWJY
	ryE8RVXvRDiqNEIFMdkWOsMcau2F3t64norC7Oe07XvaHS3NtcOzkDNSJMczGkmiMUgJ
	CUiuBum6Dpg9Lc9O56DLFMCMjCDDdcmfHGsDa1x60IEEG1YBUvbSnfBIQ8dl7k7Jurvn
	XJlIhwyHyPPHTy+ueiOYeiU0keCg5Fs6FF5GfNjq9epn0PXNuq1mESA+fAvfQCen53f8
	VYtg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
	bh=c8XLy6LXdTK74RxFDPRCE/aJcrd20wxYbsizszogTxI=;
	b=mr6lbxoaG0DWRsiI2xKtIEapC/uyVKm1ysG0CIrQusAeh4nKsKt2r1t9VhOpcxYSZ0
	1Ll2Lmn+mkDzU62TisMDrSX0Tin/ArvLdF6YOvul+id0H5o6eELC+ilBPmguhibhFfn5
	DTCqeajfL2lnJdq4WynfErc2ARDGP3jTReIgZRRT2buWtsIru+MaOitGsNMTQ5M6MKkf
	08/nMWFddNmU/2dgHZerfcu2P2wnks/xK+5A7QO5Y9vwXU7IBAum0ouvn5+apV+ZZubU
	syfPcnRMCwKmdI2MtX6JS2KmA2zSe84Dr2dRqeH+Hke7BVHX5XeDuJYOd0uTFmZ4mqDd
	FSyA==
X-Gm-Message-State: AKS2vOyGLV2onKOOkwSGTMvl5UpDNSN2COKyL8kyh51agpvZOvLzevOT
	hzYoATHkutHqp25vsIC6Qtek++6uqQ==
X-Received: by 10.202.170.210 with SMTP id t201mr19544898oie.27.1498049620359; 
	Wed, 21 Jun 2017 05:53:40 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.74.39.68 with HTTP; Wed, 21 Jun 2017 05:53:39 -0700 (PDT)
From: Zartaj Majeed <zartaj@gmail.com>
Date: Wed, 21 Jun 2017 08:53:39 -0400
Message-ID: <CAEU1kBrQ1FiGng_qgAwKG6uvd0t=w85+mnR2R8DLS=WM=VXU3g@mail.gmail.com>
Subject: Re: [PATCH] Unix domain socket filename redirection (patch update)
To: bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::242
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 12:53:47 -0000

This update to the patch adds the following:

1. Check socket file path length less than sizeof sun_path array in
struct sockaddr_un
2. Allow relative socket file paths starting with "./" or "../". This
means the pseudo filename
opened in bash is of the form "/dev/unixstream/./xyz.sock" or
"/dev/unixdgram/../xyz.sock"


diff --git a/Makefile.in b/Makefile.in
index c7b62bc0..542cede8 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -222,7 +222,7 @@ SHLIB_SOURCE = ${SH_LIBSRC}/clktck.c ${SH_LIBSRC}/getcwd.c \
  ${SH_LIBSRC}/input_avail.c ${SH_LIBSRC}/mbscasecmp.c \
  ${SH_LIBSRC}/fnxform.c ${SH_LIBSRC}/unicode.c \
  ${SH_LIBSRC}/wcswidth.c ${SH_LIBSRC}/wcsnwidth.c \
- ${SH_LIBSRC}/shmbchar.c
+ ${SH_LIBSRC}/shmbchar.c ${SH_LIBSRC}/usockopen.c

 SHLIB_LIB = -lsh
 SHLIB_LIBNAME = libsh.a
diff --git a/config.h.in b/config.h.in
index a5ad9e72..36e8f5dd 100644
--- a/config.h.in
+++ b/config.h.in
@@ -151,6 +151,10 @@
    socket connections when used in redirections */
 #undef NETWORK_REDIRECTIONS

+/* Define UNIXSOCK_REDIRECTIONS if you want
/dev/(unixstream|unixdgram)/path to open
+   socket connections when used in redirections */
+#undef UNIXSOCK_REDIRECTIONS
+
 /* Define PROGRAMMABLE_COMPLETION for the programmable completion features
    and the complete builtin. */
 #undef PROGRAMMABLE_COMPLETION
@@ -1042,6 +1046,9 @@
 /* Define if you have the <sys/socket.h> header file.  */
 #undef HAVE_SYS_SOCKET_H

+/* Define if you have the <sys/un.h> header file.  */
+#undef HAVE_SYS_UN_H
+
 /* Define if you have the <sys/stat.h> header file. */
 #undef HAVE_SYS_STAT_H

diff --git a/configure.ac b/configure.ac
index ce4e9b60..a8e9f43c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -168,6 +168,7 @@ opt_cond_regexp=yes
 opt_coproc=yes
 opt_arith_for_command=yes
 opt_net_redirs=yes
+opt_usock_redirs=yes
 opt_progcomp=yes
 opt_separate_help=no
 opt_multibyte=yes
@@ -196,7 +197,7 @@ if test $opt_minimal_config = yes; then
  opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no
  opt_brace_expansion=no opt_disabled_builtins=no opt_command_timing=no
  opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no
- opt_net_redirs=no opt_progcomp=no opt_separate_help=no
+ opt_net_redirs=no opt_usock_redirs=no opt_progcomp=no opt_separate_help=no
  opt_multibyte=yes opt_cond_regexp=no opt_coproc=no
  opt_casemod_attrs=no opt_casemod_expansions=no opt_extglob_default=no
  opt_globascii_default=no
@@ -227,6 +228,7 @@ AC_ARG_ENABLE(history,
AC_HELP_STRING([--enable-history], [turn on command histo
 AC_ARG_ENABLE(job-control, AC_HELP_STRING([--enable-job-control],
[enable job control features]), opt_job_control=$enableval)
 AC_ARG_ENABLE(multibyte, AC_HELP_STRING([--enable-multibyte], [enable
multibyte characters if OS supports them]), opt_multibyte=$enableval)
 AC_ARG_ENABLE(net-redirections,
AC_HELP_STRING([--enable-net-redirections], [enable /dev/tcp/host/port
redirection]), opt_net_redirs=$enableval)
+AC_ARG_ENABLE(usock-redirections,
AC_HELP_STRING([--enable-usock-redirections], [enable
/dev/unixstream/path redirection]), opt_usock_redirs=$enableval)
 AC_ARG_ENABLE(process-substitution,
AC_HELP_STRING([--enable-process-substitution], [enable process
substitution]), opt_process_subst=$enableval)
 AC_ARG_ENABLE(progcomp, AC_HELP_STRING([--enable-progcomp], [enable
programmable completion and the complete builtin]),
opt_progcomp=$enableval)
 AC_ARG_ENABLE(prompt-string-decoding,
AC_HELP_STRING([--enable-prompt-string-decoding], [turn on escape
character decoding in prompts]), opt_prompt_decoding=$enableval)
@@ -321,6 +323,9 @@ fi
 if test $opt_net_redirs = yes; then
 AC_DEFINE(NETWORK_REDIRECTIONS)
 fi
+if test $opt_usock_redirs = yes; then
+AC_DEFINE(UNIXSOCK_REDIRECTIONS)
+fi
 if test $opt_progcomp = yes; then
 AC_DEFINE(PROGRAMMABLE_COMPLETION)
 fi
@@ -702,7 +707,7 @@ AC_CHECK_HEADERS(unistd.h stdlib.h stdarg.h
varargs.h limits.h string.h \
  stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \
  regex.h syslog.h ulimit.h)
 AC_CHECK_HEADERS(sys/pte.h sys/stream.h sys/select.h sys/file.h sys/ioctl.h \
- sys/param.h sys/socket.h sys/stat.h \
+ sys/param.h sys/socket.h sys/un.h sys/stat.h \
  sys/time.h sys/times.h sys/types.h sys/wait.h)
 AC_CHECK_HEADERS(netinet/in.h arpa/inet.h)

diff --git a/externs.h b/externs.h
index fa0603d3..1315866c 100644
--- a/externs.h
+++ b/externs.h
@@ -270,6 +270,9 @@ extern int isnetconn __P((int));
 /* declarations for functions defined in lib/sh/netopen.c */
 extern int netopen __P((char *));

+/* declarations for functions defined in lib/sh/usockopen.c */
+extern int usockopen __P((char *));
+
 /* Declarations for  functions defined in lib/sh/oslib.c */

 #if !defined (HAVE_DUP2) || defined (DUP2_BROKEN)
diff --git a/lib/sh/Makefile.in b/lib/sh/Makefile.in
index 2ca921b3..3d357997 100644
--- a/lib/sh/Makefile.in
+++ b/lib/sh/Makefile.in
@@ -84,7 +84,7 @@ LIBRARY_NAME = libsh.a
 CSOURCES = clktck.c clock.c getcwd.c getenv.c oslib.c setlinebuf.c \
    strcasecmp.c strerror.c strtod.c strtol.c strtoul.c \
    vprint.c itos.c rename.c zread.c zwrite.c shtty.c \
-   inet_aton.c netconn.c netopen.c strpbrk.c timeval.c makepath.c \
+   inet_aton.c netconn.c netopen.c usockopen.c strpbrk.c timeval.c makepath.c \
    pathcanon.c pathphys.c tmpfile.c stringlist.c stringvec.c spell.c \
    shquote.c strtrans.c strcasestr.c snprintf.c mailstat.c \
    fmtulong.c fmtullong.c fmtumax.c shmatch.c strnlen.c \
@@ -101,7 +101,7 @@ HSOURCES =
 LIBOBJS = @LIBOBJS@
 OBJECTS = clktck.o clock.o getenv.o oslib.o setlinebuf.o strnlen.o \
   itos.o zread.o zwrite.o shtty.o shmatch.o eaccess.o \
-  netconn.o netopen.o timeval.o makepath.o pathcanon.o \
+  netconn.o netopen.o usockopen.o timeval.o makepath.o pathcanon.o \
   pathphys.o tmpfile.o stringlist.o stringvec.o spell.o shquote.o \
   strtrans.o snprintf.o mailstat.o fmtulong.o \
   fmtullong.o fmtumax.o zcatfd.o zmapfd.o winsize.o wcsdup.o \
@@ -166,6 +166,7 @@ memset.o: memset.c
 mktime.o: mktime.c
 netconn.o: netconn.c
 netopen.o: netopen.c
+usockopen.o: usockopen.c
 oslib.o: oslib.c
 pathcanon.o: pathcanon.c
 pathphys.o: pathphys.c
@@ -243,6 +244,7 @@ memset.o: ${BUILD_DIR}/config.h
 mktime.o: ${BUILD_DIR}/config.h
 netconn.o: ${BUILD_DIR}/config.h
 netopen.o: ${BUILD_DIR}/config.h
+usockopen.o: ${BUILD_DIR}/config.h
 oslib.o: ${BUILD_DIR}/config.h
 pathcanon.o: ${BUILD_DIR}/config.h
 pathphys.o: ${BUILD_DIR}/config.h
@@ -341,6 +343,8 @@ netopen.o: ${BUILD_DIR}/pathnames.h ${topdir}/externs.h
 netopen.o: ${topdir}/bashintl.h ${LIBINTL_H} $(BASHINCDIR)/gettext.h
 #netopen.o: ${BUILD_DIR}/version.h

+usockopen.o: ${topdir}/bashansi.h ${topdir}/bashintl.h
+
 oslib.o: ${topdir}/bashtypes.h ${topdir}/bashansi.h ${BASHINCDIR}/maxpath.h
 oslib.o: ${topdir}/shell.h ${topdir}/syntax.h ${topdir}/bashjmp.h
${BASHINCDIR}/posixjmp.h
 oslib.o: ${topdir}/command.h ${BASHINCDIR}/stdc.h ${topdir}/error.h
diff --git a/lib/sh/usockopen.c b/lib/sh/usockopen.c
new file mode 100644
index 00000000..56b164fb
--- /dev/null
+++ b/lib/sh/usockopen.c
@@ -0,0 +1,117 @@
+/*
+ * usockopen.c -- functions to make unix domain socket connections
+ *
+ * Zartaj T. Majeed
+ */
+
+/* Copyright (C) 1987-2017 Free Software Foundation, Inc.
+
+   This file is part of GNU Bash, the Bourne Again SHell.
+
+   Bash is free software: you can redistribute it and/or modify
+   it under the terms of the GNU General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   Bash is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU General Public License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with Bash.  If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#include <config.h>
+
+#if defined (HAVE_UNISTD_H)
+#  include <unistd.h>
+#endif
+
+#include <stdio.h>
+#include <sys/types.h>
+
+#if defined (HAVE_SYS_SOCKET_H)
+#  include <sys/socket.h>
+#endif
+
+#if defined (HAVE_SYS_UN_H)
+#  include <sys/un.h>
+#endif
+
+#include <bashansi.h>
+#include <bashintl.h>
+
+#include <errno.h>
+
+#ifndef errno
+extern int errno;
+#endif
+
+static int _usockopen __P((char *, int));
+
+/*
+ * Open Unix domain socket connection
+ * Returns the connected socket or -1 on error.
+ */
+static int
+_usockopen (path, typ)
+     char *path;
+     int typ;
+{
+  int s, e;
+  struct sockaddr_un addr;
+  int socktyp = typ == 's'? SOCK_STREAM: SOCK_DGRAM;
+  size_t len = strlen(path);
+
+  if (len >= sizeof addr.sun_path)
+    {
+      internal_error ("path too long \"%s\"", path);
+      errno = EINVAL;
+      return -1;
+    }
+
+  if ((s = socket (AF_UNIX, socktyp, 0)) < 0)
+    {
+      sys_error ("unix socket");
+      return -1;
+    }
+
+  memset (&addr, 0, sizeof addr);
+  addr.sun_family = AF_UNIX;
+  strncpy (addr.sun_path, path, sizeof(addr.sun_path) - 1);
+
+  if (connect (s, &addr, sizeof addr) < 0)
+    {
+      e = errno;
+      sys_error ("unix connect");
+      close (s);
+      errno = e;
+      return -1;
+    }
+  return s;
+}
+
+/*
+ * Open Unix domain socket connection to a path like
/dev/unixstream/tmp/xyz.sock or /dev/unixdgram/tmp/xyz.sock
+ * Returns the connected socket or -1 on error.
+ */
+int
+usockopen (path)
+     char *path;
+{
+  char *s;
+  int fd;
+
+  s = strchr (path+9, '/');
+  /* relative path starts with '"./" or "../" */
+  if (s[1] == '.' && s[2] == '/' ||
+      s[1] == '.' && s[2] == '.' && s[3] == '/')
+    {
+      ++s;
+    }
+  fd = _usockopen (s, path[9]);
+
+  return fd;
+}
+
diff --git a/redir.c b/redir.c
index 25488eaf..e026cc12 100644
--- a/redir.c
+++ b/redir.c
@@ -519,6 +519,8 @@ here_document_to_fd (redirectee, ri)
 #define RF_DEVSTDOUT 4
 #define RF_DEVTCP 5
 #define RF_DEVUDP 6
+#define RF_DEVUSTRM 7
+#define RF_DEVUDGRM 8

 /* A list of pattern/value pairs for filenames that the redirection
    code handles specially. */
@@ -535,6 +537,10 @@ static STRING_INT_ALIST _redir_special_filenames[] = {
   { "/dev/tcp/*/*", RF_DEVTCP },
   { "/dev/udp/*/*", RF_DEVUDP },
 #endif
+#if defined (UNIXSOCK_REDIRECTIONS)
+  { "/dev/unixstream/*", RF_DEVUSTRM },
+  { "/dev/unixdgram/*", RF_DEVUDGRM },
+#endif
   { (char *)NULL, -1 }
 };

@@ -588,6 +594,12 @@ redir_special_open (spec, filename, flags, mode, ri)
 #endif
       break;
 #endif /* NETWORK_REDIRECTIONS */
+
+#if defined (UNIXSOCK_REDIRECTIONS)
+    case RF_DEVUSTRM:
+    case RF_DEVUDGRM:
+      fd = usockopen (filename);
+#endif /* UNIXSOCK_REDIRECTIONS */
     }

   return fd;
diff --git a/tests/misc/devunix.tests b/tests/misc/devunix.tests
new file mode 100644
index 00000000..457a40f0
--- /dev/null
+++ b/tests/misc/devunix.tests
@@ -0,0 +1,18 @@
+sock=/tmp/devunixtest.sock
+out=/tmp/devunixtest.out
+s=abcd.$$
+
+nc -U -l $sock >$out&
+sleep 1
+exec 9>/dev/unixstream$sock
+
+echo "$s" >&9
+exec 9>&-
+
+read t <$out
+
+if [[ $s != $t ]]; then
+  echo "out \"$s\" in \"$t\""
+fi
+
+rm $sock $out


From MAILER-DAEMON Wed Jun 21 09:13:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNfSH-0004nj-Sw
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 09:13:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41588)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNfSB-0004ih-Qo
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:13:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNfS7-0007sm-Om
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:13:51 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:46169
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNfS7-0007sG-Jv
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:13:47 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANL98763; Wed, 21 Jun 2017 09:13:46 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGF24709 (AUTH cpr);
	Wed, 21 Jun 2017 09:13:45 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: devel: Builtin wait infinite loop when SIGINT received
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170620050631.4ok7kocrcanfoxot@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <d79b37e2-f05b-4cfa-c180-ec3ef74d2152@case.edu>
Date: Wed, 21 Jun 2017 09:13:45 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170620050631.4ok7kocrcanfoxot@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.21.120616:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_400_499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 13:13:56 -0000

On 6/20/17 1:06 AM, Eduardo A. Bustamante López wrote:
> There's something weird about the wait builtin + SIGINT handling in the latest
> `devel' branch (i.e. 6374eecf232e70e45fe9c49cc8335e8779c07979)

Well, that comment in the code certainly proved out. Thanks for the report.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 21 09:51:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNg2f-0000BW-Hm
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 09:51:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53725)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNg2c-00008Z-Pd
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:51:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNg2Z-0008Hp-LV
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:51:30 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:43902
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNg2Z-0008Hb-F3
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:51:27 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANR02067; Wed, 21 Jun 2017 09:51:25 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFW91305 (AUTH cpr);
	Wed, 21 Jun 2017 09:51:25 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Kevin Brodsky <corax26@gmail.com>, bug-bash@gnu.org
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <549a6958-70bc-56ce-4f1b-607baf6b8f3e@case.edu>
Date: Wed, 21 Jun 2017 09:51:24 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.21.130615:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_500_599, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 13:51:31 -0000

On 6/19/17 8:13 PM, Kevin Brodsky wrote:
> Hi,
> 
> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
> and not the expected IFS=$' \t\n'. All the other unquoted mass
> expansions ($@, array[*], array[@]) are word-split as if IFS=$'
> \t\n'.

Thanks for the report. This will be fixed in the next devel branch push.

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 21 09:55:05 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNg65-0002LL-6k
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 09:55:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54456)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNg62-0002K4-Mp
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:55:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNg5z-0001kF-Ls
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:55:02 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:7528
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNg5z-0001ji-GJ
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:54:59 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH00957; Wed, 21 Jun 2017 09:54:57 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGF31243 (AUTH cpr);
	Wed, 21 Jun 2017 09:54:57 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	Kevin Brodsky <corax26@gmail.com>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
Date: Wed, 21 Jun 2017 09:54:57 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <20170620053308.kxwjqs6gmi2ncoii@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.21.132416:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1000_1099,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 13:55:03 -0000

On 6/20/17 1:33 AM, Eduardo A. Bustamante López wrote:
> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
> [...]
>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>> and not the expected IFS=$' \t\n'. All the other unquoted mass
>> This is a regression that appeared in 4.3 and is still present on devel
> [...]
> 
> AFAICT, the following patch fixes this.

It's on the right track, but you still need to differentiate between the
cases where IFS is unset (in which case the positional parameters need to
be separated into individual words, and those individual words need to be
split on $' \t\n') and where IFS is null (in which case split_on_spaces is
used as an internal flag to satisfy the Posix requirement that $* expand
into separate words no matter what IFS is set to).

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 21 09:59:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNgAj-0004FT-Le
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 09:59:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55383)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNgAh-0004FN-SJ
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:59:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <zartaj@gmail.com>) id 1dNgAg-0003jc-QR
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:59:51 -0400
Received: from mail-oi0-x22a.google.com ([2607:f8b0:4003:c06::22a]:36170)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <zartaj@gmail.com>) id 1dNgAg-0003jW-MG
	for bug-bash@gnu.org; Wed, 21 Jun 2017 09:59:50 -0400
Received: by mail-oi0-x22a.google.com with SMTP id p187so32633647oif.3
	for <bug-bash@gnu.org>; Wed, 21 Jun 2017 06:59:50 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to; 
	bh=FvxGUL2fNaKHv7bTdL39Dy0KXIKQCz32koSEjSirUQA=;
	b=q90pu1W0VXGjXCvIBdz3qq9/uR1fcCLXObFRW7HP48wKDEaVntIaDpbrKgxu4MYMNj
	UIbAaSXJ1wyMRTER72yjI6S6EgMc2bVxRcGLtSL0VZfkANnQ1xzrH+THQyd4xdBvYaXl
	bgK9vmpK24rSJedAk2CgLU19TSxcal2ZqUfsik8lAcEx8LoKX+nPJZlxLA5dXSq4xSbJ
	+mHTuDtQLxJdSBNwm8dN+nyIqvGFBCOeWvtwbpT9zb15BdYHdsiNf4sZsLRDQGDL9b0S
	wSHtHt421Rald3mxH4zWhye95qP8j6xVpH4ThGuS1YqcDR9ZcmDLEpZ4nTHEM+CLX2Ps
	5ccA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to;
	bh=FvxGUL2fNaKHv7bTdL39Dy0KXIKQCz32koSEjSirUQA=;
	b=a+gbXkJe2uBLJeoGcwLIcbyZr42/Kb3pEBPStc/Z4/Yhc5eWhnJTLt7R/iEVqfPM/W
	NlygDXPjyySRD9mDQGJaJOWyhD40h3ptyqoDNg98+5Je4wfqcSv8xZSP5mFjvlnRZhH5
	UD6cHaLOgsNYAEh44M2075tjFXDvFLmCVtCeSRCWP+18p93qohdSKmfnDtnaSaAaqzd6
	dYS53IOX3RjHTZRSeGZ5mgs1lZvejNFxBS8bVyCuE/Ja+5ys0nCxsKvgICnhFmCeauyR
	vBjqyMh77nxeuKT8BGAOHFco9p2SwDCQoNbqJvjyCQ40f2+YkFm7+ohloXRzb0ZAiqH8
	ZhQA==
X-Gm-Message-State: AKS2vOzuiRcynmvgS3fRJ49pjhzUOt9sObyVh1cMzyiUjCCy2BifK61X
	SbDxL60dq1Gv7e+qNHdN4CUNp9QgihiM
X-Received: by 10.202.170.210 with SMTP id t201mr19752552oie.27.1498053589461; 
	Wed, 21 Jun 2017 06:59:49 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.74.39.68 with HTTP; Wed, 21 Jun 2017 06:59:49 -0700 (PDT)
In-Reply-To: <CAEU1kBrQ1FiGng_qgAwKG6uvd0t=w85+mnR2R8DLS=WM=VXU3g@mail.gmail.com>
References: <CAEU1kBrQ1FiGng_qgAwKG6uvd0t=w85+mnR2R8DLS=WM=VXU3g@mail.gmail.com>
From: Zartaj Majeed <zartaj@gmail.com>
Date: Wed, 21 Jun 2017 09:59:49 -0400
Message-ID: <CAEU1kBpGy=bkkDQi3=8pUPm8t13=BMY4=SQdL0y2k0Bwn6hriw@mail.gmail.com>
Subject: Re: [PATCH] Unix domain socket filename redirection (patch update)
To: bug-bash@gnu.org
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22a
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 13:59:53 -0000

need to use strncmp for relative path check:

if (!strncmp (s, "/./", 3) || !strncmp (s, "/../", 4))
  {
     ++s;
  }


On Wed, Jun 21, 2017 at 8:53 AM, Zartaj Majeed <zartaj@gmail.com> wrote:

> This update to the patch adds the following:
>
> 1. Check socket file path length less than sizeof sun_path array in
> struct sockaddr_un
> 2. Allow relative socket file paths starting with "./" or "../". This
> means the pseudo filename opened in bash is of the form
> "/dev/unixstream/./xyz.sock" or "/dev/unixdgram/../xyz.sock"
>
>
> +  s = strchr (path+9, '/');
> +  /* relative path starts with '"./" or "../" */
> +  if (s[1] == '.' && s[2] == '/' ||
> +      s[1] == '.' && s[2] == '.' && s[3] == '/')
> +    {
> +      ++s;
> +    }
> +  fd = _usockopen (s, path[9]);
> +
>

From MAILER-DAEMON Wed Jun 21 14:43:16 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNkax-0001ND-U5
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 14:43:15 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40398)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNkav-0001Mp-3J
	for bug-bash@gnu.org; Wed, 21 Jun 2017 14:43:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNkar-0007Dz-6N
	for bug-bash@gnu.org; Wed, 21 Jun 2017 14:43:13 -0400
Received: from mail-wr0-x235.google.com ([2a00:1450:400c:c0c::235]:33586)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <corax26@gmail.com>) id 1dNkar-0007Bk-09
	for bug-bash@gnu.org; Wed, 21 Jun 2017 14:43:09 -0400
Received: by mail-wr0-x235.google.com with SMTP id r103so146649804wrb.0
	for <bug-bash@gnu.org>; Wed, 21 Jun 2017 11:43:07 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-transfer-encoding:content-language;
	bh=t9kVWuu/Y60wO7GEZ+2m52UPo5SN9nChEgXlqCiSVQ0=;
	b=mnlSCTNQ4CmaKRFH7yRy297JEVkno4jebafskcdPJW4W0bxzkEg8DE2O6ptNylYz3M
	8oW5ocMdfS+vWBDGILyC3OdYIfZY4cEK7JHbwJfbriQr4ikeHkexyvkEGxIHxdcRPwLE
	o5B5+gWea3WePF7cva0bLw4bvdN4ZVBwmyskCcxq5DgP/7ph4mChiFOjCTXp9RlU6UBD
	hXm6LDdHZCBN9ICmlBVVigEdoWamnMJdN2YagPd0dHRLgMfkwMP4NbR8cseQVIfur0e+
	VR44GJCR2/+DRnwPyqYQmvSVyTNPUSW1l8Dzq0RdxhrSQx3tXErYUCbngoH68Wv+sX/w
	OiVQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:cc:references:from:message-id:date
	:user-agent:mime-version:in-reply-to:content-transfer-encoding
	:content-language;
	bh=t9kVWuu/Y60wO7GEZ+2m52UPo5SN9nChEgXlqCiSVQ0=;
	b=by06DbALPcLA+/fbeLY08bagr/kv7NF8wS9+LDq6HaIKLt5ZAPLzUpaVrrZ7wi7/jC
	bFmmxWRcxX6dFYbh+D2WH8Xu1eANcnxF2keG/MVYR/2zoPNq855OcC77NwxigghDdYRA
	Qr75wFobzsjqdgg4n3PTOTR6rPGoP+OIzKjgR3DM7symd+LrcXCgdso2qA8faqC/Czev
	lLQ8TXMVQyzC84sWpVds2aWVA/7z4i2B/nyWhj3qftPOidh0KfZ5Lxnz/hqAz5LjL4Ak
	8MhujMvc7aniODHsyrlqDynProuf/P79CdeoGz8/iE8V9h8pvphI/KYAlBgj+bF9QKHE
	9TOw==
X-Gm-Message-State: AKS2vOz+8/uiGj8E3ttPPf2rMXU651f2cExxfKWBftJt4NyfGiYfYFEU
	VI2fF2xBg0VclDUB
X-Received: by 10.28.230.85 with SMTP id d82mr7963193wmh.87.1498070586079;
	Wed, 21 Jun 2017 11:43:06 -0700 (PDT)
Received: from [192.168.0.10] (15.162.125.91.dyn.plus.net. [91.125.162.15])
	by smtp.googlemail.com with ESMTPSA id
	d66sm12161608wma.21.2017.06.21.11.43.04
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Wed, 21 Jun 2017 11:43:05 -0700 (PDT)
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: chet.ramey@case.edu, =?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=
	<dualbus@gmail.com>
Cc: bug-bash@gnu.org
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
From: Kevin Brodsky <corax26@gmail.com>
Message-ID: <777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
Date: Wed, 21 Jun 2017 19:43:04 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Content-Language: en-GB
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 18:43:14 -0000

On 21/06/2017 14:54, Chet Ramey wrote:
> On 6/20/17 1:33 AM, Eduardo A. Bustamante López wrote:
>> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
>> [...]
>>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>>> and not the expected IFS=$' \t\n'. All the other unquoted mass
>>> This is a regression that appeared in 4.3 and is still present on devel
>> [...]
>>
>> AFAICT, the following patch fixes this.
> It's on the right track, but you still need to differentiate between the
> cases where IFS is unset (in which case the positional parameters need to
> be separated into individual words, and those individual words need to be
> split on $' \t\n') and where IFS is null (in which case split_on_spaces is
> used as an internal flag to satisfy the Posix requirement that $* expand
> into separate words no matter what IFS is set to).

That is also my reading of POSIX (and that's more or less what Bash's
manpage says as well), but it doesn't seem to be the case (even in <=4.2):

  $ set -- 'a b'
  $ IFS=''
  $ nb_args $*
  1
  $ nb_args $@
  1

Am I missing something? Other shells like dash or zsh seem to behave
exactly in the same way, so I must be...

Kevin


From MAILER-DAEMON Wed Jun 21 15:30:13 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNlKP-0007p2-Pg
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 15:30:13 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50168)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNlKN-0007ls-0G
	for bug-bash@gnu.org; Wed, 21 Jun 2017 15:30:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNlKJ-0001Aq-TZ
	for bug-bash@gnu.org; Wed, 21 Jun 2017 15:30:11 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:16159
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNlKJ-000172-O3
	for bug-bash@gnu.org; Wed, 21 Jun 2017 15:30:07 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMH23874; Wed, 21 Jun 2017 15:30:02 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFX52490 (AUTH cpr);
	Wed, 21 Jun 2017 15:30:00 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Kevin Brodsky <corax26@gmail.com>,
	"=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
Date: Wed, 21 Jun 2017 15:29:59 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.21.182716:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	URI_ENDS_IN_PHP, __ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __CP_NOT_1,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__MULTIPLE_URI_TEXT, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1400_1499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 19:30:12 -0000

On 6/21/17 2:43 PM, Kevin Brodsky wrote:

> That is also my reading of POSIX (and that's more or less what Bash's
> manpage says as well), but it doesn't seem to be the case (even in <=4.2):

That's a relatively new requirement.  The portion of the relevant sentence
that reads "initially producing one field for each positional parameter
that is set" is new as of issue 7 TC2. Without that, the splitting rules
for $* were effectively identical whether it was quoted or not quoted --
they were separated using the first character of $IFS. In a context where
they were not quoted and word splitting took place, this had the side
effect of splitting them in an unquoted context. When IFS is null, that
resulted in no splitting.

There were long discussions on the Posix list about this starting in late
2014, resulting in Posix interp 888.

http://austingroupbugs.net/view.php?id=888

There are still some cases where I haven't completely made bash conform to
the new spec.

> 
>   $ set -- 'a b'
>   $ IFS=''
>   $ nb_args $*
>   1
>   $ nb_args $@
>   1

This is a different situation: when IFS is null, there is no splitting. So
N fields are produced, one for each of N positional parameters, but they
are not split any further.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Wed Jun 21 18:01:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNnh3-0006A4-I4
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 18:01:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53828)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNnh1-00068x-8b
	for bug-bash@gnu.org; Wed, 21 Jun 2017 18:01:44 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <corax26@gmail.com>) id 1dNngy-0003jZ-2O
	for bug-bash@gnu.org; Wed, 21 Jun 2017 18:01:43 -0400
Received: from mail-wr0-x234.google.com ([2a00:1450:400c:c0c::234]:34943)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <corax26@gmail.com>) id 1dNngx-0003jB-SW
	for bug-bash@gnu.org; Wed, 21 Jun 2017 18:01:40 -0400
Received: by mail-wr0-x234.google.com with SMTP id k67so2952718wrc.2
	for <bug-bash@gnu.org>; Wed, 21 Jun 2017 15:01:39 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:cc:references:from:message-id:date:user-agent
	:mime-version:in-reply-to:content-transfer-encoding:content-language;
	bh=Nr2SCIUTi7OXFNnqP6jji6CmLWkgrddwS/0/xxVcF6A=;
	b=hlUC73Rpt+2TaemHfc+ODjH2DtWJkW0+fFco0wl6ucAd5w9pQd1/AZc1BoWHo+gHcP
	xxqyP2L125HCxBaH/+zY11ja33BgE2JapO0oDXi4uWnR2HURNCfp1XkX9fWSAvc+QIh7
	WNnRG28CXntYlYoMALveWSPuH2JdDSyofb5w7J5MowytvQUqhD/liEwXKyS3nd0/5QXB
	go2VzaoC6M1byMAc8QmRStk36ACnA7o8Y9F9QMD5FIXJWxwDOQBuAoMG85Cy56EwXprY
	8NZybbKRLsTcJv0SkNEcf/Rx+2hQTJQhKBr17qbLnH+3cf01bCrFp76WGfaWxCNWeg6z
	JINA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:cc:references:from:message-id:date
	:user-agent:mime-version:in-reply-to:content-transfer-encoding
	:content-language;
	bh=Nr2SCIUTi7OXFNnqP6jji6CmLWkgrddwS/0/xxVcF6A=;
	b=deT92gfmf3gn5++h6SA23bstZadeEOkz+ddXlmrGyCCntHebdkIiuKHtTLluXvZkJn
	wh6VtFmVlaLrBLTW0Q0C4s+tZn0QEkLcNmeyCdm95qxLyBOWksR7GmXpxX6KGmV2QpsT
	6jiEX94CeS+x+S48q0hRo6czlxjkpPEQMjYJh2kTB3HgUg8ACb5xc24vXYLrsE+XtPHk
	yyb7xyZKzaKJEGfKjtvhPvKFIo5/hqQU7FCX1vvbBKS/g37X6c+jIYXKfjfbtdYa6pRV
	//2XxTgJsJDIUetKfeqAw9cvMkEVh1zJNz5RmLoDa/fTC3ZMgA3QdWqGTDYPzUyaepFV
	3iVw==
X-Gm-Message-State: AKS2vOyN3sxwA1VYAi9aNp6fkxFzFVjLSG5fdVL9J82zxKmgN0cUXfMM
	v+tRSwZvjj55t7td
X-Received: by 10.223.139.211 with SMTP id w19mr10405937wra.146.1498082498249; 
	Wed, 21 Jun 2017 15:01:38 -0700 (PDT)
Received: from [192.168.0.10] (15.162.125.91.dyn.plus.net. [91.125.162.15])
	by smtp.googlemail.com with ESMTPSA id
	e130sm7445wmf.10.2017.06.21.15.01.36
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Wed, 21 Jun 2017 15:01:37 -0700 (PDT)
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: chet.ramey@case.edu, =?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=
	<dualbus@gmail.com>
Cc: bug-bash@gnu.org
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
From: Kevin Brodsky <corax26@gmail.com>
Message-ID: <4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
Date: Wed, 21 Jun 2017 23:01:36 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101
	Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
Content-Language: en-GB
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2a00:1450:400c:c0c::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 21 Jun 2017 22:01:44 -0000

On 21/06/2017 20:29, Chet Ramey wrote:
> On 6/21/17 2:43 PM, Kevin Brodsky wrote:
>
>> That is also my reading of POSIX (and that's more or less what Bash's
>> manpage says as well), but it doesn't seem to be the case (even in <=4.2):
> That's a relatively new requirement.  The portion of the relevant sentence
> that reads "initially producing one field for each positional parameter
> that is set" is new as of issue 7 TC2. Without that, the splitting rules
> for $* were effectively identical whether it was quoted or not quoted --
> they were separated using the first character of $IFS. In a context where
> they were not quoted and word splitting took place, this had the side
> effect of splitting them in an unquoted context. When IFS is null, that
> resulted in no splitting.

I have to admit I am now a bit confused as to what word splitting is
supposed to happen when expanding $* (with the old and new spec). I
thought it was very simple:
* If quoted, there is no splitting whatsoever, and arguments are
concatenated into a single string.
* If not quoted, then each argument expands into a field, and all fields
are split according to IFS (i.e. no splitting if IFS is null).

IIUC, before this sentence was added, then 'IFS=""; set -- a b; nb_args
$*' should give 1, as no splitting occurs when IFS is null. However,
this not the case on Bash 4.2.

Do you have an example that results in a different number of arguments
(after splitting) between Bash 4.2 and 4.3?

> There were long discussions on the Posix list about this starting in late
> 2014, resulting in Posix interp 888.
>
> http://austingroupbugs.net/view.php?id=888
>
> There are still some cases where I haven't completely made bash conform to
> the new spec.
>
>>   $ set -- 'a b'
>>   $ IFS=''
>>   $ nb_args $*
>>   1
>>   $ nb_args $@
>>   1
> This is a different situation: when IFS is null, there is no splitting. So
> N fields are produced, one for each of N positional parameters, but they
> are not split any further.

Yes I realise now that this has to be true, as IFS being null means at
least that fields are not further split.

Kevin


From MAILER-DAEMON Wed Jun 21 22:30:31 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dNrt9-0005NT-OJ
	for mharc-bug-bash@gnu.org; Wed, 21 Jun 2017 22:30:31 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47359)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNrt8-0005NN-1M
	for bug-bash@gnu.org; Wed, 21 Jun 2017 22:30:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dNrt4-000124-UT
	for bug-bash@gnu.org; Wed, 21 Jun 2017 22:30:30 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:5086
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dNrt4-00011k-Ow
	for bug-bash@gnu.org; Wed, 21 Jun 2017 22:30:26 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMM35215; Wed, 21 Jun 2017 22:30:24 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HRN15044 (AUTH cpr);
	Wed, 21 Jun 2017 22:30:24 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Kevin Brodsky <corax26@gmail.com>,
	"=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <db46801d-6048-233f-f444-b30e7256a164@case.edu>
Date: Wed, 21 Jun 2017 22:30:22 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.22.15416:17:8.707, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, URI_ENDS_IN_HTML,
	__URI_NO_WWW, __CP_URI_IN_BODY, __CP_NOT_1,
	__FRAUD_MONEY_CURRENCY_DOLLAR, BODY_PARA_IS_SENTENCE_URL,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_2000_2999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 22 Jun 2017 02:30:31 -0000

On 6/21/17 6:01 PM, Kevin Brodsky wrote:
> On 21/06/2017 20:29, Chet Ramey wrote:
>> On 6/21/17 2:43 PM, Kevin Brodsky wrote:
>>
>>> That is also my reading of POSIX (and that's more or less what Bash's
>>> manpage says as well), but it doesn't seem to be the case (even in <=4.2):
>> That's a relatively new requirement.  The portion of the relevant sentence
>> that reads "initially producing one field for each positional parameter
>> that is set" is new as of issue 7 TC2. Without that, the splitting rules
>> for $* were effectively identical whether it was quoted or not quoted --
>> they were separated using the first character of $IFS. In a context where
>> they were not quoted and word splitting took place, this had the side
>> effect of splitting them in an unquoted context. When IFS is null, that
>> resulted in no splitting.
> 
> I have to admit I am now a bit confused as to what word splitting is
> supposed to happen when expanding $* (with the old and new spec). I
> thought it was very simple:
> * If quoted, there is no splitting whatsoever, and arguments are
> concatenated into a single string.
> * If not quoted, then each argument expands into a field, and all fields
> are split according to IFS (i.e. no splitting if IFS is null).
> 
> IIUC, before this sentence was added, then 'IFS=""; set -- a b; nb_args
> $*' should give 1, as no splitting occurs when IFS is null. However,
> this not the case on Bash 4.2.

Bash always had code to make unquoted $* essentially the same as unquoted
$@, with a lot of special-case code to cover various values of IFS and
figure out whether word splitting was going to take place at all.  That
was arguably a violation of the spec, and part of the discussion was
aimed at figuring that out.

However, not all shells were consistent in their interpretation of the
Posix rules. For instance, dash, which bills itself as being completely
Posix conformant, produces 1 for that case (and expands to "ab").  The
Bourne shell (SVR4.2 version) produces 1 as well, but expands it
differently ("a b"). Debian's posh produces the same results as the Bourne
shell. And so on.


> Do you have an example that results in a different number of arguments
> (after splitting) between Bash 4.2 and 4.3?

I don't, but you can look at the discussions around the time of the change
you identified. This is one:

http://lists.gnu.org/archive/html/bug-bash/2013-01/msg00167.html

There are some others on the Posix mailing list.

There was a lot of discussion back in March and April:

http://lists.gnu.org/archive/html/bug-bash/2017-03/msg00182.html
http://lists.gnu.org/archive/html/bug-bash/2017-04/msg00001.html

and a few others.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 22 07:51:48 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dO0eK-0002Ez-C6
	for mharc-bug-bash@gnu.org; Thu, 22 Jun 2017 07:51:48 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:32930)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dO0eI-0002En-7E
	for bug-bash@gnu.org; Thu, 22 Jun 2017 07:51:47 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dO0eE-0002lz-AY
	for bug-bash@gnu.org; Thu, 22 Jun 2017 07:51:46 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:41108 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dO0eE-0002Z0-2h
	for bug-bash@gnu.org; Thu, 22 Jun 2017 07:51:42 -0400
Received: (qmail 26362 invoked from network); 22 Jun 2017 11:51:12 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 22 Jun 2017 07:51:12 -0400
Received: (qmail 16589 invoked by uid 563); 22 Jun 2017 11:51:12 -0000
Date: Thu, 22 Jun 2017 07:51:12 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
Message-ID: <20170622115111.GQ22519@eeg.ccf.org>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <db46801d-6048-233f-f444-b30e7256a164@case.edu>
User-Agent: Mutt/1.4.2.3i
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 22 Jun 2017 11:51:47 -0000

On Wed, Jun 21, 2017 at 10:30:22PM -0400, Chet Ramey wrote:
> However, not all shells were consistent in their interpretation of the
> Posix rules. For instance, dash, which bills itself as being completely
> Posix conformant, produces 1 for that case (and expands to "ab").  The
> Bourne shell (SVR4.2 version) produces 1 as well, but expands it
> differently ("a b"). Debian's posh produces the same results as the Bourne
> shell. And so on.

Oh, wow.  I didn't realize it was quite this bad.

$ dash
$ set -- a b
$ IFS=
$ args $*
1 args: <ab>
$ args $@
1 args: <ab>
$ args "$*"
1 args: <ab>
$ args "$@"
2 args: <a> <b>

$ ksh
$ set -- a b
$ IFS=
$ args $*
2 args: <a> <b>
$ args $@
2 args: <a> <b>
$ args "$*"
1 args: <ab>
$ args "$@"
2 args: <a> <b>

OK, going forward, I am officially considering any use of unquoted $*
or $@ in a script to be a BUG, an invocation of undefined behavior,
not acceptable, no excuses.


From MAILER-DAEMON Thu Jun 22 09:05:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dO1nH-0001kh-5V
	for mharc-bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53037)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dO1nB-0001hO-4D
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:05 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dO1n8-0006Gy-G2
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:01 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:19826
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dO1n8-0006Gk-AG
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:04:58 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMM54559; Thu, 22 Jun 2017 09:04:56 -0400 (EDT)
Received: from v129-22-118-156.tisvpn.CWRU.Edu (EHLO
	v129-22-118-156.tisvpn.CWRU.Edu) ([129.22.118.156])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BFY25205 (AUTH cpr);
	Thu, 22 Jun 2017 09:04:56 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: AddressSanitizer: heap-use-after-free in readtok |
	PS1='$((b[x++}]))'
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170620145842.ntlrjgbzaol6tmxh@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <9739ce6a-f849-c86c-a089-0987e2e537d8@case.edu>
Date: Thu, 22 Jun 2017 09:04:55 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170620145842.ntlrjgbzaol6tmxh@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.22.124216:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_400_LESS,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_300_399,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 22 Jun 2017 13:05:05 -0000

On 6/20/17 10:58 AM, Eduardo A. Bustamante López wrote:
> I don't know how to fix this.

I fixed it, it's in today's devel branch push.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 22 09:05:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dO1nL-0001py-DF
	for mharc-bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53048)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <pyroinajar@gmail.com>) id 1dO1nD-0001il-Q8
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <pyroinajar@gmail.com>) id 1dO1nC-0006Ho-Sx
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:03 -0400
Received: from mail-yw0-x229.google.com ([2607:f8b0:4002:c05::229]:35351)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <pyroinajar@gmail.com>)
	id 1dO1nC-0006HN-Ni
	for bug-bash@gnu.org; Thu, 22 Jun 2017 09:05:02 -0400
Received: by mail-yw0-x229.google.com with SMTP id v7so5621384ywc.2
	for <bug-bash@gnu.org>; Thu, 22 Jun 2017 06:05:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:sender:in-reply-to:references:from:date:message-id
	:subject:to:cc;
	bh=OUTbZaQUHH/PdKOvKRYS13BBuMJ6N1BNHo3YcONzzBo=;
	b=pM6vh4GEy2+Li1XQmTKaWI7V25Tg1Jl838nGpzyWGuw86TTmTmT8PVl9+sLro2Rnps
	WXfxhYDjFw4Y7mluLNMBSD1kP0uxf3FsTvrzacu85q+/bm7SwvBXD+uvNhNpnjzMmQLU
	naQcxwU9mK6YQUF5TfvdNBn6UMneydcm5ZX2xTSnEnO//QFSsjLhxMXicn1ZJR68pySC
	C7PmIMM64dhhfZzOGLemhw+X9bdTDkdM08NRnkVnkeFkven6UbQCosjGem+ULDyn3BVv
	eZfPbkfUUZELIVkuWbD1zo8RlpcVjTZmCdsdh60KSURcmuj52nsPZQG1wEPgOueglaDa
	dBYw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:sender:in-reply-to:references:from
	:date:message-id:subject:to:cc;
	bh=OUTbZaQUHH/PdKOvKRYS13BBuMJ6N1BNHo3YcONzzBo=;
	b=gVisEZRni8EgiFOFjhLtiLayZ31oE6OklhDYSZVc0gk018+hTpZicb5snWChGIC4gK
	qWoF1ITSy3VDP6Di1JzX8u159KDWmUYLZkIN2UjBb7mjCBM4xKNG2hvNLce+2Y05SsWm
	CCDuzqf+6Ipa8fzw/AZZ/iw9kAth50mPsWV5HtM24CZufZ/b2dkz2dU/XF5GUScBBERU
	GvCsCBa66ci1fT5+9jNrUT9EggDS8lcqY0v4OtqRhPTw9XfjaNWaoJgQj+Yt8qeKILJE
	QyHregK2to5BPmTkPe1yHeD8cBKeytJJrDUIJvDozwGgTH+QtpXOroPQ6OxjzHFd4GOp
	R99w==
X-Gm-Message-State: AKS2vOye2SXCYIq7swW7L5fZUicMQXJtz+9EQ5rCO3P6TDqbHpzRmcjb
	EAl20O7tffRiaubOwXJnz3YBi+A/aw==
X-Received: by 10.129.0.9 with SMTP id 9mr1789206ywa.170.1498136700301; Thu,
	22 Jun 2017 06:05:00 -0700 (PDT)
MIME-Version: 1.0
Sender: pyroinajar@gmail.com
Received: by 10.129.4.86 with HTTP; Thu, 22 Jun 2017 06:04:59 -0700 (PDT)
In-Reply-To: <20170622115111.GQ22519@eeg.ccf.org>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<20170622115111.GQ22519@eeg.ccf.org>
From: DJ Mills <danielmills1@gmail.com>
Date: Thu, 22 Jun 2017 09:04:59 -0400
X-Google-Sender-Auth: oKkWLLTyUsW88c45wQDdF2y2T-c
Message-ID: <CAPg6Z0-Q-Rc7A=6hvLB+MP-fR4=bRoP7_KE3h=qMwSpC1Acqjw@mail.gmail.com>
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Greg Wooledge <wooledg@eeg.ccf.org>
Cc: bug-bash <bug-bash@gnu.org>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4002:c05::229
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 22 Jun 2017 13:05:09 -0000

On Thu, Jun 22, 2017 at 7:51 AM, Greg Wooledge <wooledg@eeg.ccf.org> wrote:

> On Wed, Jun 21, 2017 at 10:30:22PM -0400, Chet Ramey wrote:
>
> OK, going forward, I am officially considering any use of unquoted $*
> or $@ in a script to be a BUG, an invocation of undefined behavior,
> not acceptable, no excuses.
>
>
I think this is pretty true of any unquoted expansion. You should be able
to get the
behavior you want without relying on wordsplitting

From MAILER-DAEMON Fri Jun 23 11:28:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOQVZ-00010X-Jh
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 11:28:29 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:42690)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOQVX-0000zJ-9H
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:28:28 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOQVW-0000jn-9e
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:28:27 -0400
Received: from [2001:3c8:9009:181::2] (port=61645 helo=munnari.OZ.AU)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <kre@munnari.OZ.AU>) id 1dOQVV-0000Zb-K6
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:28:26 -0400
Received: from andromeda.noi.kre.to (localhost [IPv6:::1]) by munnari.OZ.AU
	with ESMTP id v5NFRv8n001502; Fri, 23 Jun 2017 22:28:00 +0700 (ICT)
Received: from andromeda.noi.kre.to (localhost [127.0.0.1])
	by andromeda.noi.kre.to (8.15.1/8.14.2) with ESMTP id v5NFRii8010691;
	Fri, 23 Jun 2017 22:27:45 +0700 (ICT)
From: Robert Elz <kre@munnari.OZ.AU>
To: Greg Wooledge <wooledg@eeg.ccf.org>
cc: bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
In-Reply-To: <20170622115111.GQ22519@eeg.ccf.org>
References: <20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Fri, 23 Jun 2017 22:27:44 +0700
Message-ID: <3693.1498231664@andromeda.noi.kre.to>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2001:3c8:9009:181::2
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 15:28:28 -0000

    Date:        Thu, 22 Jun 2017 07:51:12 -0400
    From:        Greg Wooledge <wooledg@eeg.ccf.org>
    Message-ID:  <20170622115111.GQ22519@eeg.ccf.org>


  | $ dash
  | $ set -- a b
  | $ IFS=
  | $ args $*
  | 1 args: <ab>

That is simply broken.  Always has been, whatever mistakes were
in the wording posix used to use to try and explain how it works.

  | $ ksh
  | $ set -- a b
  | $ IFS=
  | $ args $*
  | 2 args: <a> <b>

This has always been the correct behaviour.  There is no field splitting
happening, but when unquoted, there's no joining happening either.
$* is just $1 $2 ... (for as many params as set) as separate words.

That is, if you knew how many words existed, and wrote it out in longhand
in the first place.  $* is just convenient when you don't know how many
params there are.

When quoted ("$*"), IFS[0] is used to turn the words into the string required,
when unquoted they are just words.  "$@" is the one slightly weird special
case, but only because it is defined to be "$1" "$2" ... (for as many
params as exist, including 0).

kre



From MAILER-DAEMON Fri Jun 23 11:40:21 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOQh3-0003tc-1L
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 11:40:21 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45895)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dOQh0-0003tS-GW
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:40:19 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dOQgw-0004gL-Jx
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:40:18 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:41851 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dOQgw-0004W2-BG
	for bug-bash@gnu.org; Fri, 23 Jun 2017 11:40:14 -0400
Received: (qmail 36790 invoked from network); 23 Jun 2017 15:39:46 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Fri, 23 Jun 2017 11:39:46 -0400
Received: (qmail 4226 invoked by uid 563); 23 Jun 2017 15:39:45 -0000
Date: Fri, 23 Jun 2017 11:39:45 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: Robert Elz <kre@munnari.OZ.AU>
Cc: bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
Message-ID: <20170623153945.GA4028@eeg.ccf.org>
References: <20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <3693.1498231664@andromeda.noi.kre.to>
User-Agent: Mutt/1.8.3 (2017-05-23)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 15:40:19 -0000

On Fri, Jun 23, 2017 at 10:27:44PM +0700, Robert Elz wrote:
> $* is just $1 $2 ... (for as many params as set) as separate words.

That's what I always thought too, but if commonly used shells like
dash can't even agree on this, then I simply upgrade my response level
from "bad practice" to "completely wrong, don't ever do this" when
someone uses unquoted $* or $@.

It's not like it's ever *OK* to use them, really.  Now I just consider
it totally unacceptable instead of something that needs a stern warning.


From MAILER-DAEMON Fri Jun 23 12:09:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOR8u-0001ly-4o
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 12:09:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54936)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOR8s-0001ls-D8
	for bug-bash@gnu.org; Fri, 23 Jun 2017 12:09:07 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOR8n-0001dJ-BU
	for bug-bash@gnu.org; Fri, 23 Jun 2017 12:09:06 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:21363
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dOR8n-0001c3-5V
	for bug-bash@gnu.org; Fri, 23 Jun 2017 12:09:01 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN17138; Fri, 23 Jun 2017 12:08:53 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSQ89544 (AUTH cpr);
	Fri, 23 Jun 2017 12:08:53 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Robert Elz <kre@munnari.OZ.AU>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <4291916f-0913-153e-c318-eadd7c5c1a1e@case.edu>
Date: Fri, 23 Jun 2017 12:08:51 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <3693.1498231664@andromeda.noi.kre.to>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.23.150317:17:8.510, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__STOCK_PHRASE_24, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG, __HAS_HTML,
	HTML_NO_HTTP, BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_800_899,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_10,
	__FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS, IN_REP_TO,
	MSG_THREAD, __FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 16:09:07 -0000

On 6/23/17 11:27 AM, Robert Elz wrote:
>     Date:        Thu, 22 Jun 2017 07:51:12 -0400
>     From:        Greg Wooledge <wooledg@eeg.ccf.org>
>     Message-ID:  <20170622115111.GQ22519@eeg.ccf.org>
> 
> 
>   | $ dash
>   | $ set -- a b
>   | $ IFS=
>   | $ args $*
>   | 1 args: <ab>
> 
> That is simply broken.  Always has been, whatever mistakes were
> in the wording posix used to use to try and explain how it works.

The historical Bourne shell produces <a b>.  (Of course, the historical
Bourne shell didn't allow IFS to be unset, either, so it's not a valid
reference implementation.)  Some current shells, like posh, do the same
thing.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 23 15:54:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOUev-00029J-Gl
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 15:54:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59331)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dOUet-00029A-Dh
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:54:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dOUeq-0002sZ-D2
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:54:23 -0400
Received: from homie.mail.dreamhost.com ([208.97.132.208]:55490
	helo=homiemail-a62.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <jidanni@jidanni.org>) id 1dOUeq-0002re-48
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:54:20 -0400
Received: from homiemail-a62.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a62.g.dreamhost.com (Postfix) with ESMTP id 2815B634075
	for <bug-bash@gnu.org>; Fri, 23 Jun 2017 12:54:18 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to
	:subject:date:message-id:mime-version:content-type; s=
	jidanni.org; bh=36EK9Jj334DrkiUJr6xTdZLNRxo=; b=Z3Q2qZfvP8UydOEu
	zV1RQMdv1DnRnB4sZy12aixFLGirms3tp2/oDeRnSYSz6KPjjSdW8lTZA97qaPJo
	an/qWEM+OwwpMV4AQQanSqVPSR+ZT5iIcvXqMJ+z7uv2gdtCytbyL1Wtd3ULdRWE
	KSoZb/xsIh94sg7eo1n4G34aNN4=
Received: from jidanni.org (114-41-1-177.dynamic-ip.hinet.net [114.41.1.177])
	(using TLSv1 with cipher AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: jidanni@jidanni.org)
	by homiemail-a62.g.dreamhost.com (Postfix) with ESMTPSA id E8B5263406E
	for <bug-bash@gnu.org>; Fri, 23 Jun 2017 12:54:17 -0700 (PDT)
From: =?utf-8?B?56mN5Li55bC8?= Dan Jacobson <jidanni@jidanni.org>
To: bug-bash@gnu.org
Subject: expand x*y concludes with one
Date: Sat, 24 Jun 2017 03:54:14 +0800
Message-ID: <874lv64h09.fsf@jidanni.org>
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy]
X-Received-From: 208.97.132.208
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 19:54:24 -0000

# su - nobody
$ touch kaaaaam kaam kam
$ : k*m<TAB> #becomes:
$ : kaaaaam
$ sh
sh-4.4$ : k*m<TAB> #does a better job it seems:
kaaaaam  kaam     kam
sh-4.4$ : k*m


From MAILER-DAEMON Fri Jun 23 15:58:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOUiu-0003Hb-0L
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 15:58:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:60125)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOUir-0003GK-IV
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:58:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOUio-0004jG-IL
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:58:29 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:18949
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dOUio-0004j4-Cn
	for bug-bash@gnu.org; Fri, 23 Jun 2017 15:58:26 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI29519; Fri, 23 Jun 2017 15:58:21 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSE07962 (AUTH cpr);
	Fri, 23 Jun 2017 15:58:21 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: expand x*y concludes with one
To: =?UTF-8?B?56mN5Li55bC8IERhbiBKYWNvYnNvbg==?= <jidanni@jidanni.org>,
	bug-bash@gnu.org
References: <874lv64h09.fsf@jidanni.org>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <52c3b5fd-ac38-862c-90c6-b9b38f41f94a@case.edu>
Date: Fri, 23 Jun 2017 15:58:19 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <874lv64h09.fsf@jidanni.org>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.23.192716:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __HIGHBITS,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__CHAR_CHINESE_UTF8, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_500_599, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, LOCALE_CHINESE, IN_REP_TO,
	MSG_THREAD, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 19:58:30 -0000

On 6/23/17 3:54 PM, 積丹尼 Dan Jacobson wrote:
> # su - nobody
> $ touch kaaaaam kaam kam
> $ : k*m<TAB> #becomes:
> $ : kaaaaam
> $ sh
> sh-4.4$ : k*m<TAB> #does a better job it seems:
> kaaaaam  kaam     kam
> sh-4.4$ : k*m

This has little information about the version of bash you're using and
whether or not you have bash-completion installed.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Fri Jun 23 16:14:54 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOUyj-0007nU-Ug
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 16:14:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:34528)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dOUyi-0007nO-5u
	for bug-bash@gnu.org; Fri, 23 Jun 2017 16:14:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dOUyf-00040r-1d
	for bug-bash@gnu.org; Fri, 23 Jun 2017 16:14:52 -0400
Received: from homie.mail.dreamhost.com ([208.97.132.208]:37164
	helo=homiemail-a62.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <jidanni@jidanni.org>) id 1dOUye-00040M-On
	for bug-bash@gnu.org; Fri, 23 Jun 2017 16:14:48 -0400
Received: from homiemail-a62.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a62.g.dreamhost.com (Postfix) with ESMTP id 8D08E634075;
	Fri, 23 Jun 2017 13:14:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc
	:subject:references:date:message-id:mime-version:content-type;
	s=jidanni.org; bh=Lkf4/ZTqe6/peeQkTW/bp8c0EZU=; b=FM2aQ6TOBrTdN
	oRiekbGPnZdfw5qWg2VQp7TcNsYt87GuiBkV33+O0+eLAoN/Dn+mvzpidxSR28wN
	TCuucE45zlxsc4+Hti4o1wgg4GMcf7odr14lTwfdWAEQm24/ZVuTYhQy5kEWfPTK
	1/fPsu6yoPakaZnhOkGLEdYcD87juE=
Received: from jidanni.org (114-41-1-177.dynamic-ip.hinet.net [114.41.1.177])
	(using TLSv1 with cipher AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: jidanni@jidanni.org)
	by homiemail-a62.g.dreamhost.com (Postfix) with ESMTPSA id 51A6363406E; 
	Fri, 23 Jun 2017 13:14:42 -0700 (PDT)
From: =?utf-8?B?56mN5Li55bC8?= Dan Jacobson <jidanni@jidanni.org>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: expand x*y concludes with one
References: <874lv64h09.fsf@jidanni.org>
Date: Sat, 24 Jun 2017 04:14:36 +0800
Message-ID: <87zicy31hv.fsf@jidanni.org>
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy]
X-Received-From: 208.97.132.208
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Fri, 23 Jun 2017 20:14:53 -0000

$ apt-cache policy bash bash-completion
bash:
  Installed: 4.4-5 ...
bash-completion:
  Installed: 1:2.1-4.3 ...
OK
$ INPUTRC=/dev/null bash
$ : k*m<TAB>
kaaaaam  kaam     kam

OK I suppose I should report a bug against the bash-completion package.


From MAILER-DAEMON Fri Jun 23 22:36:14 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOavl-0000hS-VN
	for mharc-bug-bash@gnu.org; Fri, 23 Jun 2017 22:36:13 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:58945)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOavj-0000hK-Nk
	for bug-bash@gnu.org; Fri, 23 Jun 2017 22:36:12 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOavi-0002sb-QK
	for bug-bash@gnu.org; Fri, 23 Jun 2017 22:36:11 -0400
Received: from [2001:3c8:9009:181::2] (port=59712 helo=munnari.OZ.AU)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <kre@munnari.OZ.AU>) id 1dOavi-0002oR-3Z
	for bug-bash@gnu.org; Fri, 23 Jun 2017 22:36:10 -0400
Received: from andromeda.noi.kre.to (localhost [IPv6:::1]) by munnari.OZ.AU
	with ESMTP id v5O2ZmB0019451; Sat, 24 Jun 2017 09:35:49 +0700 (ICT)
Received: from andromeda.noi.kre.to (localhost [127.0.0.1])
	by andromeda.noi.kre.to (8.15.1/8.14.2) with ESMTP id v5O2ZYVD027749;
	Sat, 24 Jun 2017 09:35:36 +0700 (ICT)
From: Robert Elz <kre@munnari.OZ.AU>
To: Greg Wooledge <wooledg@eeg.ccf.org>
cc: bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
In-Reply-To: <20170623153945.GA4028@eeg.ccf.org>
References: <20170623153945.GA4028@eeg.ccf.org>
	<20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Sat, 24 Jun 2017 09:35:34 +0700
Message-ID: <6237.1498271734@andromeda.noi.kre.to>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2001:3c8:9009:181::2
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 02:36:12 -0000

    Date:        Fri, 23 Jun 2017 11:39:45 -0400
    From:        Greg Wooledge <wooledg@eeg.ccf.org>
    Message-ID:  <20170623153945.GA4028@eeg.ccf.org>

  | That's what I always thought too, but if commonly used shells like
  | dash can't even agree on this, then I simply upgrade my response level
  | from "bad practice" to "completely wrong, don't ever do this" when
  | someone uses unquoted $* or $@.

As Chet said in an earlier response, unquoted expansions are more often
bugs than not - but not always.  Anything that you attempt to apply as a
"one rule to govern them all" is going to be inappropriate sometimes.

Most of these issues only arise when IFS='' and while that's a perfectly
valid thing to do, and useful when appropriate, it is not particularly common.

In cases where IFS is not a null string, the broken implementations mostly
tend to work OK (sometimes perhaps only by a fluke), and even more work
properly if IFS has its default value or something similar, that is
where IFS[0] == ' ' to borrow an inappropriate way of writing it.

  | It's not like it's ever *OK* to use them, really.  Now I just consider
  | it totally unacceptable instead of something that needs a stern warning.

No, it is, and is required, if you have what is essentially a command in
the args, but which is yet to be pathname expanded, you cannot use quotes
or the pathname expansion doesn't happen, you can't do
	eval "$*"
as that will re-tokenise the input, and perhaps not split at the correct
places, there are times where only a bare $* (or $@ which is the same thing,
when unquoted, of course) will do.

These may be rare, but just saying "never do it" is too much.

kre

ps: I am not saying that there is not some bash private way of accomplishing
the same thing, I have no idea, but if there is, and it was used, that would
then make the script non-portable.



From MAILER-DAEMON Sat Jun 24 08:59:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOkf6-0001QY-5X
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 08:59:40 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37345)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOkf2-0001QC-9t
	for bug-bash@gnu.org; Sat, 24 Jun 2017 08:59:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOkex-0006tB-H2
	for bug-bash@gnu.org; Sat, 24 Jun 2017 08:59:36 -0400
Received: from mail-ot0-x22b.google.com ([2607:f8b0:4003:c0f::22b]:35043)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOkex-0006sa-AW
	for bug-bash@gnu.org; Sat, 24 Jun 2017 08:59:31 -0400
Received: by mail-ot0-x22b.google.com with SMTP id u13so46235530otd.2
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 05:59:29 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=4EhxuS+1rv46WCF/6LloU1TLuVwP9WKUfxv8dodzq2g=;
	b=q3Cqnb7OIpchrcT7ELOiCIQEmk7QpjVPuh1+DxEbg2gwg0dtYEgp9L7cbp2HY3hcGT
	PC4dd9G07ybx5q7cbRbr9GSJUZqubXtthE48v/B3oXMb1+ZBrDH5TEjPlL6ly3YyRI/T
	U8yC4epxnzV+rtQtcUzK/gPzcaX7u79XpSrtkpiRycdKK38C7FMFFV3CXvjnnUUkMUiJ
	jWwTu0+aM0k0yaAuGmaKGhJxrkenW+y0KHLO8xom+xQWoErr8j/magbR0UTbIWjmTyHe
	Gke3e9srUe1JXzL+x+URrL2MAhrVuSkRaennxp+Ye/11ChVULt78rejIxxyfwcz3uHfd
	TKmA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=4EhxuS+1rv46WCF/6LloU1TLuVwP9WKUfxv8dodzq2g=;
	b=IhVa9wVhXd7RNuwb+0OKFVjs/DwHlsdtOKrSKqcpulm4sVY3Wvqac06vBGfJ55VXiD
	slxk/+H0TSdPfE90d+7QhXWCHdI9RIrfv5sY1gowtE6cgKFlcfL7GAWn5LyRnjIh1SQg
	tRNJYwgO2NA8O3CPx13fjYR1gZt8MeuX+3K414eZMBk+YksEpbcvD930Q86Yg/2eGCwL
	vDVjCl3it7/q16ujl8iMKwxHMoztRJN+56VgnlGDNIW6eytweiVlShB5Hi5QbwedqlT/
	Qj2XmEL7QMqmi0JuobDxytKq5ylEWX9btcdsFCM4ClbbyqRqorNr78OPnTTXfBsbAtn/
	8lrg==
X-Gm-Message-State: AKS2vOzvl/ioZ7zyi9zQ6X/WnJTwf+Nq4S5szttKT27YLs07R5gtwsJU
	zUosdrIUtrKMqw==
X-Received: by 10.157.42.234 with SMTP id e97mr6146816otb.150.1498309168668;
	Sat, 24 Jun 2017 05:59:28 -0700 (PDT)
Received: from localhost ([201.157.174.156])
	by smtp.gmail.com with ESMTPSA id o2sm3884938otb.47.2017.06.24.05.59.27
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 05:59:27 -0700 (PDT)
Date: Sat, 24 Jun 2017 07:59:25 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Robert Elz <kre@munnari.OZ.AU>
Cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
Message-ID: <20170624125925.7vnb4kk35gh3obbk@debian>
References: <20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
	<6237.1498271734@andromeda.noi.kre.to>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <6237.1498271734@andromeda.noi.kre.to>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22b
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 12:59:38 -0000

On Sat, Jun 24, 2017 at 09:35:34AM +0700, Robert Elz wrote:
[...]
> In cases where IFS is not a null string, the broken implementations mostly
> tend to work OK (sometimes perhaps only by a fluke), and even more work
> properly if IFS has its default value or something similar, that is
> where IFS[0] == ' ' to borrow an inappropriate way of writing it.
[...]
> These may be rare, but just saying "never do it" is too much.

Greg's advice is directed towards novice / intermediate shell script
programmers. I think we can all agree that the rules (and bugs) around
the expansion of $* are too complex. As a shell script writer trying to
make use $*, you'd have to verify that it works as expected across all
the shells (and even between different versions of the same shell).

IMO, it's easier to just document this kind of expansion as "undefined
behavior". Pretty much like we do with `errexit' already.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 09:25:23 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOl3y-0006ct-UI
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 09:25:22 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57671)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <skynet@top-email.net>) id 1dOjVx-0002s8-AB
	for bug-bash@gnu.org; Sat, 24 Jun 2017 07:46:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <skynet@top-email.net>) id 1dOjVu-0008B2-7d
	for bug-bash@gnu.org; Sat, 24 Jun 2017 07:46:09 -0400
Received: from shout02.mail.de ([213.128.151.217]:58499)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <skynet@top-email.net>)
	id 1dOjVt-0008AL-UD
	for bug-bash@gnu.org; Sat, 24 Jun 2017 07:46:06 -0400
Received: from postfix01.mail.de (postfix01.bt.mail.de [10.0.121.125])
	by shout02.mail.de (Postfix) with ESMTP id 4D28A5FFCE
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 13:46:01 +0200 (CEST)
Received: from smtp03.mail.de (smtp03.bt.mail.de [10.0.121.213])
	by postfix01.mail.de (Postfix) with ESMTP id 30C6449DDC
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 13:46:01 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=top-email.net;
	s=top-email201307; t=1498304761;
	bh=w7zua1cCJ5ZN/8Po2gXMslZyp4dUbiJDnSRtdrlTqtI=;
	h=From:To:Subject:Date:From;
	b=hJvt1RqOZIktGWFWyE9YUq9tcjCns7+1dKmqVQtW2oGWk+XAZETby1NxgF8aUUZD+
	qnDO2G7yJoNoWx2djXCBMTfQgoWoplUowRqvRVJ1y6gqU/cZhUvyrNuWehOYpu+Zhk
	HjYgnEgeZMzLBTrifVsZ24SS22WA/u6hdwH5jRaA=
Received: from [127.0.0.1] (localhost [127.0.0.1])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by smtp03.mail.de (Postfix) with ESMTPSA id 081F54204E
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 13:46:00 +0200 (CEST)
From: "skynet@top-email.net" <skynet@top-email.net>
To: bug-bash@gnu.org
Subject: Bug in select-command
Date: Sat, 24 Jun 2017 13:46:00 +0200
Message-ID: <3422067.bOg8qTKhfZ@pc0>
MIME-Version: 1.0
Content-Transfer-Encoding: 7Bit
Content-Type: text/plain; charset="us-ascii"
X-purgate: clean
X-purgate: This mail is considered clean (visit http://www.eleven.de for
	further information)
X-purgate-type: clean
X-purgate-Ad: Categorized by eleven eXpurgate (R) http://www.eleven.de
X-purgate: This mail is considered clean (visit http://www.eleven.de for
	further information)
X-purgate: clean
X-purgate-size: 1163
X-purgate-ID: 154282::1498304761-00000CF2-AF5E0FC8/0/0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 213.128.151.217
X-Mailman-Approved-At: Sat, 24 Jun 2017 09:25:22 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 11:46:10 -0000

It is necessary to refresh the variable $COLUMNS in a script (COLUMNS="tput 
cols") otherwise the command "select" will not set the number of columns 
correctly for actual screen resolution.

Information:		checkwinsize    on

Please try this script-example to see the effect:
#!/bin/bash

### SET VARIABLES ###
	PS3="Select: "


# EXECUTE THE SCRIPT WITH THE NEXT LINE (correctly set number of columns) AND 
WITHOUT (just 2 columns) TO SEE THE EFFECT !!!
	COLUMNS="$(tput cols)"


### DEFINE PRE-FUNCTIONS ###
echo() { builtin echo -e "$@" ;}
read() { builtin read -re "$@" ;}
bc() { echo "scale=2;$1" | $(which bc) -l ;}

### DEFINE FUNCTIONS ###
_config-keymap() {
	# Select keymap
		# find keymap list, cut directory path and sort
			local list_keymaps=( $(find /usr/share/kbd/keymaps/ -type f -name 
*.map.gz | grep -Eo [^/]*.map.gz | sort -V) )
		# cut suffixes
			list_keymaps=( ${list_keymaps[@]%%.*} )

		select locale_keymap in ${list_keymaps[@]}; do
			if [[ "$REPLY" -ge 1 && "$REPLY" -lt ${#list_keymaps[@]} ]]; then
				echo ${locale_keymap}; break
			fi
		done
}

### MAIN PROGRAMM ###
clear
_config-keymap


From MAILER-DAEMON Sat Jun 24 10:11:38 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOlmk-00061x-C2
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 10:11:38 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45324)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOlmi-00061o-Nu
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:11:37 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <kre@munnari.OZ.AU>) id 1dOlmh-0008J9-Vk
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:11:36 -0400
Received: from [2001:3c8:9009:181::2] (port=57988 helo=munnari.OZ.AU)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <kre@munnari.OZ.AU>) id 1dOlmh-0008FA-8n
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:11:35 -0400
Received: from andromeda.noi.kre.to (localhost [IPv6:::1]) by munnari.OZ.AU
	with ESMTP id v5OEAjIb002259; Sat, 24 Jun 2017 21:10:47 +0700 (ICT)
Received: from andromeda.noi.kre.to (localhost [127.0.0.1])
	by andromeda.noi.kre.to (8.15.1/8.14.2) with ESMTP id v5OEAYtN005735;
	Sat, 24 Jun 2017 21:10:35 +0700 (ICT)
From: Robert Elz <kre@munnari.OZ.AU>
To: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
In-Reply-To: <20170624125925.7vnb4kk35gh3obbk@debian>
References: <20170624125925.7vnb4kk35gh3obbk@debian>
	<20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
	<6237.1498271734@andromeda.noi.kre.to>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Date: Sat, 24 Jun 2017 21:10:34 +0700
Message-ID: <26275.1498313434@andromeda.noi.kre.to>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2001:3c8:9009:181::2
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 14:11:37 -0000

    Date:        Sat, 24 Jun 2017 07:59:25 -0500
    From:        Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
    Message-ID:  <20170624125925.7vnb4kk35gh3obbk@debian>

  | I think we can all agree that the rules (and bugs) around
  | the expansion of $* are too complex.

The bugs in various implementations cause problems, yes, dealing with
someone else's mistakes (and especially doing it in a way that things
still work when the bugs get fixed) can be difficult.

But the rules, no, the rules for $* are actually trivial.

Unquoted, $* (or $@ which is identical) is exactly the same
as the sequence

	$1 $2 $3 ...

would be, if we knew in advance how many of those we should write
(which can be 0 of them of course.)

It is exactly that simple (ignoring implementation bugs.)

The only slight complication is when we have a$*b (for any a and b).
But that's just as simple really, "a" gets attached to the first of the
$n's produced (usually $1 unless $# is 0), and "b" gets attached to the
last.   So if $# is 3 we get
	a$1 $2 $3b
(with the obvious extension to bigger $# values).  For $# = 2 it
is just a$1 $2b , for $# = 1, a$1b and for $# = 0 we get just ab

No-one has any problem understanding what $1 means or what a
sequence of args means, and $* just combines those two.

When quoted, $@ (ie: "$@") is just as simple, except each $n generated
is quoted "$1" "$2" "$3" (and the combining rule for adjacent text is
the same as above.)   And just as above $# can be 0, and nothing (assuming
no attached text) is generated.

All that is left is "$*" which just produces "$1x$2x$3x" for as many
args that exist, where 'x' is the first char of IFS (and may be nothing
at all).   In this one the "" string is always generated, even when $# is 0,
it is just empty then.

kre



From MAILER-DAEMON Sat Jun 24 10:46:58 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOmKw-0004od-JJ
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 10:46:58 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:49300)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmKt-0004oJ-5k
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:46:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmKq-0008WA-1O
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:46:55 -0400
Received: from mail-oi0-x244.google.com ([2607:f8b0:4003:c06::244]:34666)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOmKp-0008Ur-QD
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:46:51 -0400
Received: by mail-oi0-x244.google.com with SMTP id b6so6099822oia.1
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 07:46:51 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=4A6q9nd7GR7xrQlDhFu3MWwRdMCcbdjNiIAPyrs+xxo=;
	b=dUQWWwVkgn9Hh/HtRBtREDMghRvRJb+QJII+8meL8yu9NobYPlhvZMKiEx/8PDLPtO
	1M9fr6J8mKv1gdL4XyBEIUEtJSEyrpY2G3RUdmFK7hXp0v8xiOtSrxxCc07Lk/Bg8FqO
	p1cCtt4PTw25H1uWp58eY6zt7mjiOdvei1uOS+q/4+N81E/9AfyZf9aNi5YcLrRvDM5w
	xSPysUjRjKnTSWt9BTYlWvh8z11XnWt4wNUbWv5EhmonVmPKd5bP7p0Vj2iuy8LKmYsm
	fuVklvHHjsuFEM3qGDTPbNvQJdv7cIEfPttcjeZQA1Ld4naR95/N2if2elXPk2RQJNtm
	2pNw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=4A6q9nd7GR7xrQlDhFu3MWwRdMCcbdjNiIAPyrs+xxo=;
	b=MvRBIHgImOLJ8/Vy0MD6SLPr7/QVeg8AiWreO4EmyJe61HjeQeoMqeYx3GczYIEkyW
	5OqPiCcYdogClii8XuntkQI2Ti1N+VVKL+luQI+W/whvbpygbttrM2HXJX2ULvO7uEP+
	Bz//cKQCvKA1AcEUK9cSFpj3K6yZ1RUZE8auSZSNwu7+qveoz3Q6iPk2iP/VEdz2FkYz
	AfZq/JYMZE8Oui8qpdZ3k/FIcrCBKOgnmipjWJAcDxQGLJl+oTDsaeT73K83FXkf006J
	qFfjfqTWyH3IksBmkAAP3QJqLUFzxdxJJzMf7wOniU2MQxqtYGQS33LCYGJje07NA+aV
	5QYg==
X-Gm-Message-State: AKS2vOydNzX/k6hB0vh0WLtnFZmyHRZGoYW7hW8minS5KqbesjVWBelv
	TaHU1JhbaprdX8x7
X-Received: by 10.202.80.85 with SMTP id e82mr4536243oib.0.1498315610872;
	Sat, 24 Jun 2017 07:46:50 -0700 (PDT)
Received: from localhost ([201.157.174.156])
	by smtp.gmail.com with ESMTPSA id 67sm3768488ott.42.2017.06.24.07.46.49
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 07:46:49 -0700 (PDT)
Date: Sat, 24 Jun 2017 09:46:47 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: "skynet@top-email.net" <skynet@top-email.net>
Cc: bug-bash@gnu.org
Subject: Re: Bug in select-command
Message-ID: <20170624144647.6lp2axilj7p3y5ps@debian>
References: <3422067.bOg8qTKhfZ@pc0>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <3422067.bOg8qTKhfZ@pc0>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::244
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 14:46:56 -0000

On Sat, Jun 24, 2017 at 01:46:00PM +0200, skynet@top-email.net wrote:
[...]
> 
> ### DEFINE FUNCTIONS ###
> _config-keymap() {
> 	# Select keymap
> 		# find keymap list, cut directory path and sort
> 			local list_keymaps=( $(find /usr/share/kbd/keymaps/ -type f -name 
> *.map.gz | grep -Eo [^/]*.map.gz | sort -V) )
> 		# cut suffixes
> 			list_keymaps=( ${list_keymaps[@]%%.*} )
> 
> 		select locale_keymap in ${list_keymaps[@]}; do
> 			if [[ "$REPLY" -ge 1 && "$REPLY" -lt ${#list_keymaps[@]} ]]; then
> 				echo ${locale_keymap}; break
> 			fi
> 		done
> }
> 
> ### MAIN PROGRAMM ###
> clear
> _config-keymap
> 
I don't have `/usr/share/kbd/keymaps/' in my system.

    dualbus@debian:~$ ls -l /usr/share/kbd/keymaps/
    ls: cannot access '/usr/share/kbd/keymaps/': No such file or directory

>From what I can tell, I get these keymaps by installing `console-data'
in my Debian system, although these are installed under `/usr/share/keymaps/',
and have different extensions (e.g.
`/usr/share/keymaps/i386/qwerty/pc110.kmap.gz')

~~~~~

I think this is an easier way to reproduce the problem. I have a terminal
window with the following dimensions:

  dualbus@debian:~$ declare -p COLUMNS LINES
  declare -- COLUMNS="191"
  declare -- LINES="49"

  dualbus@debian:~$ bash --version | head -n1
  GNU bash, version 4.4.12(1)-release (x86_64-pc-linux-gnu)

Running the script in `interactive' mode (which triggers calls to
`get_new_window_size' through `get_tty_state' when checkwinsize is
enabled), lays out the options on seven columns:

  dualbus@debian:~$ bash -i script 
  $- himB
  cols 191
  1) aaaaaaaaaaaaaaaaaaaa    8) aaaaaaaaaaaaaaaaaaaa  15) bbbbbbbbbbbbbbbbbbbb  22) cccccccccccccccccccc  29) dddddddddddddddddddd  36) eeeeeeeeeeeeeeeeeeee  43) ffffffffffffffffffff
  2) aaaaaaaaaaaaaaaaaaaa    9) bbbbbbbbbbbbbbbbbbbb  16) bbbbbbbbbbbbbbbbbbbb  23) cccccccccccccccccccc  30) dddddddddddddddddddd  37) eeeeeeeeeeeeeeeeeeee  44) ffffffffffffffffffff
  3) aaaaaaaaaaaaaaaaaaaa   10) bbbbbbbbbbbbbbbbbbbb  17) cccccccccccccccccccc  24) cccccccccccccccccccc  31) dddddddddddddddddddd  38) eeeeeeeeeeeeeeeeeeee  45) ffffffffffffffffffff
  4) aaaaaaaaaaaaaaaaaaaa   11) bbbbbbbbbbbbbbbbbbbb  18) cccccccccccccccccccc  25) dddddddddddddddddddd  32) dddddddddddddddddddd  39) eeeeeeeeeeeeeeeeeeee  46) ffffffffffffffffffff
  5) aaaaaaaaaaaaaaaaaaaa   12) bbbbbbbbbbbbbbbbbbbb  19) cccccccccccccccccccc  26) dddddddddddddddddddd  33) eeeeeeeeeeeeeeeeeeee  40) eeeeeeeeeeeeeeeeeeee  47) ffffffffffffffffffff
  6) aaaaaaaaaaaaaaaaaaaa   13) bbbbbbbbbbbbbbbbbbbb  20) cccccccccccccccccccc  27) dddddddddddddddddddd  34) eeeeeeeeeeeeeeeeeeee  41) ffffffffffffffffffff  48) ffffffffffffffffffff
  7) aaaaaaaaaaaaaaaaaaaa   14) bbbbbbbbbbbbbbbbbbbb  21) cccccccccccccccccccc  28) dddddddddddddddddddd  35) eeeeeeeeeeeeeeeeeeee  42) ffffffffffffffffffff
  #? q

Whereas running the same script in `non-interactive' mode results in three
columns.

  dualbus@debian:~$ bash  script 
  $- hB
  cols 191
   1) aaaaaaaaaaaaaaaaaaaa  17) cccccccccccccccccccc  33) eeeeeeeeeeeeeeeeeeee
   2) aaaaaaaaaaaaaaaaaaaa  18) cccccccccccccccccccc  34) eeeeeeeeeeeeeeeeeeee
   3) aaaaaaaaaaaaaaaaaaaa  19) cccccccccccccccccccc  35) eeeeeeeeeeeeeeeeeeee
   4) aaaaaaaaaaaaaaaaaaaa  20) cccccccccccccccccccc  36) eeeeeeeeeeeeeeeeeeee
   5) aaaaaaaaaaaaaaaaaaaa  21) cccccccccccccccccccc  37) eeeeeeeeeeeeeeeeeeee
   6) aaaaaaaaaaaaaaaaaaaa  22) cccccccccccccccccccc  38) eeeeeeeeeeeeeeeeeeee
   7) aaaaaaaaaaaaaaaaaaaa  23) cccccccccccccccccccc  39) eeeeeeeeeeeeeeeeeeee
   8) aaaaaaaaaaaaaaaaaaaa  24) cccccccccccccccccccc  40) eeeeeeeeeeeeeeeeeeee
   9) bbbbbbbbbbbbbbbbbbbb  25) dddddddddddddddddddd  41) ffffffffffffffffffff
  10) bbbbbbbbbbbbbbbbbbbb  26) dddddddddddddddddddd  42) ffffffffffffffffffff
  11) bbbbbbbbbbbbbbbbbbbb  27) dddddddddddddddddddd  43) ffffffffffffffffffff
  12) bbbbbbbbbbbbbbbbbbbb  28) dddddddddddddddddddd  44) ffffffffffffffffffff
  13) bbbbbbbbbbbbbbbbbbbb  29) dddddddddddddddddddd  45) ffffffffffffffffffff
  14) bbbbbbbbbbbbbbbbbbbb  30) dddddddddddddddddddd  46) ffffffffffffffffffff
  15) bbbbbbbbbbbbbbbbbbbb  31) dddddddddddddddddddd  47) ffffffffffffffffffff
  16) bbbbbbbbbbbbbbbbbbbb  32) dddddddddddddddddddd  48) ffffffffffffffffffff
  #? q

The script:

  dualbus@debian:~$ cat script 
  #!/bin/bash
  shopt -s checkwinsize
  
  options=(
  aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa
  bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb
  cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc
  dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd
  eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee
  ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff
  )
  
  echo \$- $-
  echo cols $(tput cols)
  select opt in "${options[@]}"; do
    break
  done


AFAICT, this is intentional. There's another option though. If you read
https://lists.gnu.org/archive/html/help-bash/2015-03/msg00005.html, you'll see
why the following works:

  # seven columns, non-interactive
  dualbus@debian:~$ bash script
  $- hB
  cols 80
  1) aaaaaaaaaaaaaaaaaaaa    8) aaaaaaaaaaaaaaaaaaaa  15) bbbbbbbbbbbbbbbbbbbb  22) cccccccccccccccccccc  29) dddddddddddddddddddd  36) eeeeeeeeeeeeeeeeeeee  43) ffffffffffffffffffff
  2) aaaaaaaaaaaaaaaaaaaa    9) bbbbbbbbbbbbbbbbbbbb  16) bbbbbbbbbbbbbbbbbbbb  23) cccccccccccccccccccc  30) dddddddddddddddddddd  37) eeeeeeeeeeeeeeeeeeee  44) ffffffffffffffffffff
  3) aaaaaaaaaaaaaaaaaaaa   10) bbbbbbbbbbbbbbbbbbbb  17) cccccccccccccccccccc  24) cccccccccccccccccccc  31) dddddddddddddddddddd  38) eeeeeeeeeeeeeeeeeeee  45) ffffffffffffffffffff
  4) aaaaaaaaaaaaaaaaaaaa   11) bbbbbbbbbbbbbbbbbbbb  18) cccccccccccccccccccc  25) dddddddddddddddddddd  32) dddddddddddddddddddd  39) eeeeeeeeeeeeeeeeeeee  46) ffffffffffffffffffff
  5) aaaaaaaaaaaaaaaaaaaa   12) bbbbbbbbbbbbbbbbbbbb  19) cccccccccccccccccccc  26) dddddddddddddddddddd  33) eeeeeeeeeeeeeeeeeeee  40) eeeeeeeeeeeeeeeeeeee  47) ffffffffffffffffffff
  6) aaaaaaaaaaaaaaaaaaaa   13) bbbbbbbbbbbbbbbbbbbb  20) cccccccccccccccccccc  27) dddddddddddddddddddd  34) eeeeeeeeeeeeeeeeeeee  41) ffffffffffffffffffff  48) ffffffffffffffffffff
  7) aaaaaaaaaaaaaaaaaaaa   14) bbbbbbbbbbbbbbbbbbbb  21) cccccccccccccccccccc  28) dddddddddddddddddddd  35) eeeeeeeeeeeeeeeeeeee  42) ffffffffffffffffffff
  #? ^C
  
  dualbus@debian:~$ cat script 
  #!/bin/bash
  shopt -s checkwinsize
  
  options=(
  aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa
  bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb
  cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc
  dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd
  eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee
  ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff
  )
  
  echo \$- $-
  echo cols $(tput cols)
  /bin/true # THIS
  select opt in "${options[@]}"; do
    break
  done

For some reason though, the following fails to update the value of COLUMNS:

  dualbus@debian:~$ cat script 
  #!/bin/bash
  shopt -s checkwinsize
  
  options=(
  aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa
  bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb bbbbbbbbbbbbbbbbbbbb
  cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc cccccccccccccccccccc
  dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd dddddddddddddddddddd
  eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee eeeeeeeeeeeeeeeeeeee
  ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffff
  )
  
  echo \$- $-
  echo cols $(tput cols)
  command true # this should trigger?
  select opt in "${options[@]}"; do
    break
  done

So the trick is to run an external command in foreground. To see why this
works, read:
http://git.savannah.gnu.org/cgit/bash.git/tree/jobs.c?h=devel#n3390

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 10:54:54 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOmSa-0006bp-04
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 10:54:54 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50085)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmSX-0006bU-Qa
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:54:50 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmSU-0000pN-Oz
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:54:49 -0400
Received: from mail-oi0-x241.google.com ([2607:f8b0:4003:c06::241]:33887)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOmSU-0000oP-Ie
	for bug-bash@gnu.org; Sat, 24 Jun 2017 10:54:46 -0400
Received: by mail-oi0-x241.google.com with SMTP id b6so6109265oia.1
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 07:54:46 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=9+o5Wd9wdpyKrcPW5v1Mt4klUNWYwAGFRHdZKSDcWAA=;
	b=pEijSf82DWiYYad6fgF5IlbuubWojyROS2410zoar/5p6a7Ob2G1oQDo4uuYEZMk3y
	fUU3BFHW5ND1rHnBbB1pPeqPYQe7udDOzwRoLxbTLF0bwqtCjAqv9DXonv4MsLPi41q3
	AxTh8yENZBFV+wpDcIByKKSZLCVNgtmNEBvzZjUlVMWc3FR+2CYRZ6nys8FBttU7a9l2
	9OIT7Rdr04T3yuyOqbDC+s0QKW7wLqpVPikD52cuFC1B1xJq1PsDVSVxLCGDYOGma1KC
	bNArMfzwyjYLTD5NThs987ZgKkAdmNoF6ckg7JmIoMpRJBnga0A1uhqYVo0XAPDCwwu1
	+ARQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=9+o5Wd9wdpyKrcPW5v1Mt4klUNWYwAGFRHdZKSDcWAA=;
	b=KGnxCdclluotbZ6JExPz9SV3uqhwnwgcejUkhDK+DGIsqVFwwB4ohb/+KfSzWPQm1c
	nK96T1Qa08l+VeoYdRSYUsOp5Fr+YtPDqzMDnuOCLxMMTcBOwDa1cuzOrb9sDf/qAqjr
	9lXII49Xj7JN3iEcPAgo5N6NQj4MTriRLenmcwjNlyZoIBk3aS+Wxjm+fW5X5WG2ovXX
	KGGOlwDlKgT2fAwvVD32z/mLekwQXVvhEifCd+k5ddpDbt9s963WJGdzeaWFOTsm/xnE
	5XlKLeKDd4jE5itT/C55fqWa9LIx30/A4VGxICrXXrYIwpN7fmtvuseXV8dXg373aIbm
	vq5Q==
X-Gm-Message-State: AKS2vOyvKcG09/JLdBv8mlh5iOtZeSsnm4w+RaWXw8o3ctFaMEO3kP+1
	qHRaPVXXB3TR+g==
X-Received: by 10.202.195.65 with SMTP id t62mr3685445oif.6.1498316085617;
	Sat, 24 Jun 2017 07:54:45 -0700 (PDT)
Received: from localhost ([201.157.174.156])
	by smtp.gmail.com with ESMTPSA id p17sm1789850otd.3.2017.06.24.07.54.44
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 07:54:44 -0700 (PDT)
Date: Sat, 24 Jun 2017 09:54:43 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Robert Elz <kre@munnari.OZ.AU>
Cc: Greg Wooledge <wooledg@eeg.ccf.org>, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
Message-ID: <20170624145443.7bqx5yshglaoxrq5@debian>
References: <707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
	<6237.1498271734@andromeda.noi.kre.to>
	<26275.1498313434@andromeda.noi.kre.to>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <26275.1498313434@andromeda.noi.kre.to>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::241
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 14:54:50 -0000

On Sat, Jun 24, 2017 at 09:10:34PM +0700, Robert Elz wrote:
[...]
> The bugs in various implementations cause problems, yes, dealing with
> someone else's mistakes (and especially doing it in a way that things
> still work when the bugs get fixed) can be difficult.
> 
> But the rules, no, the rules for $* are actually trivial.
> 
> Unquoted, $* (or $@ which is identical) is exactly the same
> as the sequence
> 
> 	$1 $2 $3 ...
> 
> would be, if we knew in advance how many of those we should write
> (which can be 0 of them of course.)
> 
> It is exactly that simple (ignoring implementation bugs.)

I think we are arguing about different things. My point (and which I
think is Greg's point) is that we should start recommending shell script
writers to stay away from the unquoted expansions of $* and $@.

Yes, the POSIX rules might be "trivial", but the actual implementations
are not, and shell script programmers care about running their scripts
on real implementations.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 11:07:16 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOmea-0000bl-75
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 11:07:16 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51350)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmeY-0000be-SX
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:07:15 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmeY-0002JJ-4Y
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:07:14 -0400
Received: from mail-qt0-x229.google.com ([2607:f8b0:400d:c0d::229]:32775)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOmeY-0002IM-03
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:07:14 -0400
Received: by mail-qt0-x229.google.com with SMTP id r30so5072183qtc.0
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 08:07:13 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:in-reply-to:references:from:date:message-id:subject:to
	:cc:content-transfer-encoding;
	bh=DyZMo8wQTzMPEB7sXfWTGagsNHbn6EwJqXVSA7QC2sY=;
	b=D2loZiGE+A+2ch3bY/sqnOMwhFxqUvCwnnfddkKWbvFltNRvfu/oTdmr/A9AmN8S9L
	IQWghSN/SrmIAlwogGSvwd9HzztRTdLWWM2d1JnbZsN2u1pHQ71hVBHbr7+axyYbMHV/
	N+IQ6dnR95iRhOh/74iKNeSssw1v94rn8Eix6uhx1HRT35Vtb1V97DMHL908AEo3gcEP
	p38iPu3CQ9NDhP3qhE4a2ciiadlnxcJna/U7k529VDK26TwK150tjS73bFANmjaN4Dhu
	b43LRLERCa6YLbbDf+dhZHQY3wtRHicqr5UlPpIMqMscOFpAA3pPjA+v85EgCx/10+nM
	IBsQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:in-reply-to:references:from:date
	:message-id:subject:to:cc:content-transfer-encoding;
	bh=DyZMo8wQTzMPEB7sXfWTGagsNHbn6EwJqXVSA7QC2sY=;
	b=F7AgVktWS6m+lFnnZvNLiTPs5bM4xBBigMJdhRDAfrQvogmAADBhq+U5D7O6ssnfJY
	W4wmnJUwWF532kSDdVM/GYWJsrtfZBF55fu9bBKZwgv5yXdbLz5RuynPXhS33Vt3B8sj
	h5bwCfQYSpjZsDO2X28MDD4ZlgwfNQc2s4AKbcv4vxudyp+hUTwrPj09Dq0Oq/xbTv+e
	HdAghsERB4RO3DZ40Q6BYW4Tn5eVahFwctR9G+hXfDPRj7IS/0mVugPIqwXFgCvdnyml
	6feQcAz+gFYk5wiheTb/yUKa+3lRWhDzXffs+jrUxjbzfjL67BVHIEeoL88k0LWw68WI
	PBJw==
X-Gm-Message-State: AKS2vOxU7SP+bQ8vxyTnj7RFRjNVeWjL3J9QiN2RCNeR4kpbw8R/JoRc
	HPfr0gr0arTk0EmGhE1rM0FjRfIbHw==
X-Received: by 10.237.50.71 with SMTP id y65mr14972660qtd.117.1498316833499;
	Sat, 24 Jun 2017 08:07:13 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.12.177.39 with HTTP; Sat, 24 Jun 2017 08:06:53 -0700 (PDT)
In-Reply-To: <20170624144647.6lp2axilj7p3y5ps@debian>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
From: Eduardo Bustamante <dualbus@gmail.com>
Date: Sat, 24 Jun 2017 10:06:53 -0500
Message-ID: <CAOSMAusdqOFT_z1dsDV=9ZGvqPnXUAbOmgKBe6CU+HDk6ReD+Q@mail.gmail.com>
Subject: Re: Bug in select-command
To: "skynet@top-email.net" <skynet@top-email.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::229
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 15:07:15 -0000

On Sat, Jun 24, 2017 at 9:46 AM, Eduardo A. Bustamante L=C3=B3pez
<dualbus@gmail.com> wrote:
[...]
> For some reason though, the following fails to update the value of COLUMN=
S:
[...]
>   echo \$- $-
>   echo cols $(tput cols)
>   command true # this should trigger?
>   select opt in "${options[@]}"; do
>     break
>   done

Bah, ignore this remark. `command true' will run the builtin `true'.
The rest of my email should be accurate though.


From MAILER-DAEMON Sat Jun 24 11:24:07 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOmut-0004OX-Fp
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 11:24:07 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52849)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmur-0004NH-BV
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:24:06 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOmum-0006Kk-EI
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:24:05 -0400
Received: from mail-ot0-x235.google.com ([2607:f8b0:4003:c0f::235]:33100)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOmum-0006Ji-8Q
	for bug-bash@gnu.org; Sat, 24 Jun 2017 11:24:00 -0400
Received: by mail-ot0-x235.google.com with SMTP id y47so47496952oty.0
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 08:24:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=2TO/CYybiNNVMWpQRa9GvmEoR+r6njRjJGaP7uPXVKM=;
	b=a1RK+x4ekV+IoYQ2S/0m3hvOjXIve09RoYbpcffSy/DhSlwrcE8MkYIdH+OsD9HwZG
	aJh26ufhK/bTWF27PVwvrQ2GzN5pX7CbfpDbir/LgTBZNrT7Dc0AnoOM0RgGUs3wbDAw
	jKfG+pWaLsk57sKjBeO7ad24T5zc5MDlUEvgXPBx2UmEOoD50BVU+h0AwjgFKbyRE0XD
	FWIjY7JZTtM2xHcR7VOhVUffQOkuWSVjC4U3dIr/84k6Zf1bduKTyrkLjXtbnlOaYiny
	DyrOB1QICRetj1P+3/hsc0BNOm9hI0psQaULgAycyJF8bCGjsQlpWpbYloQFg5JGVbc2
	Sctg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=2TO/CYybiNNVMWpQRa9GvmEoR+r6njRjJGaP7uPXVKM=;
	b=VJFk3QQYBe2pK+BxlQBwS1pJuj+Xs0B48BNhkuKT1tr1yOLr3yTrkfzZRHhbPCaR3Y
	OCHA1POuIIGrcb/UYGhxscgSOHmu4MraLVW5fOzwFo3EAMP+44onGiNXmhMaabwfdLw6
	t9roNp4EWTwbkSNXv7x+AC6zj91mgS0vTzkMGp92pwxjUITgSMUDBEhdrwvvzLMWo053
	WiHXHSPLTnQzJBWTfdaBO6+UBqG/K2FSUl0/SDQS9TVKrV9uXo1qz/6JfqJ3p1tuaH1l
	Ioe5dTSMq36nabQc2ajRFMftItyndvdEDpedZJw2FpDPGnl97nL/JkRKwc0FyDMjfXkR
	zcTA==
X-Gm-Message-State: AKS2vOy5Uz8sQKk82XQsH5gqta0FTZscdMsdbX/pGV+9qxLtJr9LaJbU
	Y0jRCLltgkYqew==
X-Received: by 10.157.21.39 with SMTP id u36mr6600084otf.187.1498317839442;
	Sat, 24 Jun 2017 08:23:59 -0700 (PDT)
Received: from localhost ([201.157.174.156]) by smtp.gmail.com with ESMTPSA id
	e131sm3506751oia.26.2017.06.24.08.23.58
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 08:23:58 -0700 (PDT)
Date: Sat, 24 Jun 2017 10:23:57 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: "skynet@top-email.net" <skynet@top-email.net>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>, chet.ramey@case.edu
Subject: Re: Bug in select-command
Message-ID: <20170624152357.sfpuc54723mljdwt@debian>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
	<CAOSMAusdqOFT_z1dsDV=9ZGvqPnXUAbOmgKBe6CU+HDk6ReD+Q@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CAOSMAusdqOFT_z1dsDV=9ZGvqPnXUAbOmgKBe6CU+HDk6ReD+Q@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::235
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 15:24:06 -0000

Chet:

I think the patch below could be a useful addition, to make the behavior
in this case a little bit less surprising.


*** /tmp/BdLnYa_shopt.def	2017-06-24 10:21:15.029707643 -0500
--- builtins/shopt.def	2017-06-24 10:17:00.540600773 -0500
***************
*** 134,139 ****
--- 134,140 ----
  static int shopt_set_complete_direxpand __P((char *, int));
  #endif
  
+ static int shopt_set_check_window_size __P((char *, int));
  static int shopt_set_debug_mode __P((char *, int));
  
  static int shopt_login_shell;
***************
*** 164,170 ****
  #if defined (JOB_CONTROL)
    { "checkjobs", &check_jobs_at_exit, (shopt_set_func_t *)NULL },
  #endif
!   { "checkwinsize", &check_window_size, (shopt_set_func_t *)NULL },
  #if defined (HISTORY)
    { "cmdhist", &command_oriented_history, (shopt_set_func_t *)NULL },
  #endif
--- 165,171 ----
  #if defined (JOB_CONTROL)
    { "checkjobs", &check_jobs_at_exit, (shopt_set_func_t *)NULL },
  #endif
!   { "checkwinsize", &check_window_size, shopt_set_check_window_size },
  #if defined (HISTORY)
    { "cmdhist", &command_oriented_history, (shopt_set_func_t *)NULL },
  #endif
***************
*** 593,598 ****
--- 594,606 ----
  #endif
  
  static int
+ shopt_set_check_window_size (char *option_name, int mode)
+ {
+   get_new_window_size (0, (int *)0, (int *)0);
+   return (0);
+ }
+ 
+ static int
  set_compatibility_level (option_name, mode)
       char *option_name;
       int mode;

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 13:01:43 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOoRL-00010Y-LD
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 13:01:43 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:35430)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOoRJ-000102-Bw
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:01:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOoRG-0006wq-9p
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:01:41 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:14241
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dOoRG-0006vY-4p
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:01:38 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANS53141; Sat, 24 Jun 2017 13:01:28 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSL35935 (AUTH cpr);
	Sat, 24 Jun 2017 13:01:28 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Unexpected word splitting on $* when IFS is unset
To: Robert Elz <kre@munnari.OZ.AU>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <20170623153945.GA4028@eeg.ccf.org>
	<20170622115111.GQ22519@eeg.ccf.org>
	<707bc708-9c7a-c2dc-0bd3-67eddba698e6@gmail.com>
	<20170620053308.kxwjqs6gmi2ncoii@debian>
	<9318ff0f-4157-68a7-bf9f-5dbb80dfb13f@case.edu>
	<777ca6e6-0a4e-9eaf-c239-b3c016738f9c@gmail.com>
	<3343acd2-8501-3aa6-5e7e-80b5e4a6ab66@case.edu>
	<4a2d195d-0dde-6fd0-9b1b-94cd3ec28f7d@gmail.com>
	<db46801d-6048-233f-f444-b30e7256a164@case.edu>
	<3693.1498231664@andromeda.noi.kre.to>
	<6237.1498271734@andromeda.noi.kre.to>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <1ca151a8-18ad-8f6f-4b42-8d41ad6f3888@case.edu>
Date: Sat, 24 Jun 2017 13:01:29 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <6237.1498271734@andromeda.noi.kre.to>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.24.160016:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__STOCK_PHRASE_24, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __FORWARDED_MSG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_900_999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 17:01:42 -0000

On 6/23/17 10:35 PM, Robert Elz wrote:
>     Date:        Fri, 23 Jun 2017 11:39:45 -0400
>     From:        Greg Wooledge <wooledg@eeg.ccf.org>
>     Message-ID:  <20170623153945.GA4028@eeg.ccf.org>
> 
>   | That's what I always thought too, but if commonly used shells like
>   | dash can't even agree on this, then I simply upgrade my response level
>   | from "bad practice" to "completely wrong, don't ever do this" when
>   | someone uses unquoted $* or $@.
> 
> As Chet said in an earlier response, unquoted expansions are more often
> bugs than not - but not always.  Anything that you attempt to apply as a
> "one rule to govern them all" is going to be inappropriate sometimes.

In the vast majority of cases, people really desire the effects of "$@"
and should just use that.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 24 13:13:16 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOocV-0004MF-PM
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 13:13:15 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37011)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOocS-0004Jg-M0
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:13:13 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOocP-0005Sc-Ga
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:13:12 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:15411
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dOocP-0005Qs-BL
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:13:09 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANS53452; Sat, 24 Jun 2017 13:13:05 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HTB08421 (AUTH cpr);
	Sat, 24 Jun 2017 13:13:04 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Bug in select-command
To: "skynet@top-email.net" <skynet@top-email.net>, bug-bash@gnu.org
References: <3422067.bOg8qTKhfZ@pc0>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <73b74603-16c1-af3c-ae7a-adfd0e5d1c3d@case.edu>
Date: Sat, 24 Jun 2017 13:13:06 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <3422067.bOg8qTKhfZ@pc0>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.24.160016:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NO_NAME,
	__TO_NAME, __REFERENCES, __HAS_FROM, FROM_EDU_TLD,
	__HAS_MSGID, __SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__NO_HTML_TAG_RAW, BODYTEXTP_SIZE_3000_LESS,
	BODY_SIZE_900_999, __MIME_TEXT_P1, __MIME_TEXT_ONLY,
	__URI_NS, HTML_00_01, HTML_00_10, __FRAUD_MONEY_CURRENCY,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	LEGITIMATE_SIGNS, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 17:13:13 -0000

On 6/24/17 7:46 AM, skynet@top-email.net wrote:
> It is necessary to refresh the variable $COLUMNS in a script (COLUMNS="tput 
> cols") otherwise the command "select" will not set the number of columns 
> correctly for actual screen resolution.

So you are saying that the value of COLUMNS passed in the environment is
not correct? Or that it's not present?

When the shell isn't interactive, it relies on the value passed in the
environment.  It's not the shell's role to second-guess the environment
value and change it regardless of whather or not it's "correct".

If the value doesn't appear in the environment, it's the programmer's
responsibility to make sure that the correct value is set.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 24 13:17:33 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOogf-0005TQ-9c
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 13:17:33 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:37549)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOogc-0005TC-Si
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:17:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dOogX-00029i-VE
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:17:30 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:25196
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dOogX-000290-PR
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:17:25 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANN51375; Sat, 24 Jun 2017 13:17:21 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSL42992 (AUTH cpr);
	Sat, 24 Jun 2017 13:17:21 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Bug in select-command
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	"skynet@top-email.net" <skynet@top-email.net>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <13b3afe7-8b23-b663-6f77-0b1c3ca747a1@case.edu>
Date: Sat, 24 Jun 2017 13:17:23 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170624144647.6lp2axilj7p3y5ps@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.24.162116:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_500_599,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT,
	__TO_REAL_NAMES, [TRUNCATED], so=2010-03-03 19:42:08,
	dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 17:17:31 -0000

On 6/24/17 10:46 AM, Eduardo A. Bustamante López wrote:

> I think this is an easier way to reproduce the problem. I have a terminal
> window with the following dimensions:
> 
>   dualbus@debian:~$ declare -p COLUMNS LINES
>   declare -- COLUMNS="191"
>   declare -- LINES="49"

You haven't exported these.  If you had, the subshell started to run the
script would have the correct values.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sat Jun 24 13:38:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOp1G-0001Wn-U8
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 13:38:50 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40834)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOp1E-0001We-5E
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:38:49 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOp1A-0000on-Us
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:38:48 -0400
Received: from mail-ot0-x243.google.com ([2607:f8b0:4003:c0f::243]:35767)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOp1A-0000mk-P5
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:38:44 -0400
Received: by mail-ot0-x243.google.com with SMTP id z48so7817153otz.2
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 10:38:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=JKXzga802F4VeK4gjVKwcr16Lv13DFiWb+XDc0CA6nQ=;
	b=oNz0nlKZvVANlm+U/8+HFnR07dWnGwJe85uH80+mD3XYnNVfqHNF/7MSDRssgFD5th
	m9StpEfemK63hN+JZEB0/fEK+oXF2jX+6445FmfT9PKbPQQHIKxbUZc+wPV7oZwCfAgv
	nEPuCZR4/lfTEglolPuXlKZGUS1s8onvNcUSdTddsh4vMlihd4FdUA2cEECWDwkcnI7Z
	7jJz1EZkUE9m4asBepSDd71j7XwC8GO2H1vyo3cXaCmHlUno5e+uV5HnucZklTcl9cGP
	I54I52YdRsIyV4E6K4QAPXt4SLLxrWgKEFTxj18cm1k4UJP/cwgMCeKIZfndugcQawtW
	Vjgg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=JKXzga802F4VeK4gjVKwcr16Lv13DFiWb+XDc0CA6nQ=;
	b=NGQ5ig5YiDNFMTMXrMFd13IDKkW5/41lKCSJJKi3v3W6yWaTVtfKuqEl6TUkka3L6B
	J0Xus98DXXIih7cTET739wDEvDegVps2yd9iQkctI8T0jj9oa0PlTImfl/d0W6+IDI0y
	lIyyJfrEnQW3n7GMPkkaiIDnvdTaxh1R//cUxndpDfXkpOLN+bRyCf1ZpaoxDEmTZQ7T
	RdvfbJBkNkowXjXSZLPKjXX0CGyca5tIEMMvPXdhMtBxB4paVc7aCJm3puvLnag6BHaJ
	rIy0xBS97XnTYE7phWq6uW0EbIkpEU96Ge+a/2iS1s0fN05VIO/KAYsg+vKImh6BuWSB
	iQtg==
X-Gm-Message-State: AKS2vOx74+ihMTgZPl/IeyWaWdMDR+42hZN4fqDEgb3Y4gzxafijeNAp
	WYGBtNFhhD/NDg==
X-Received: by 10.157.30.163 with SMTP id n32mr7975031otn.96.1498325921660;
	Sat, 24 Jun 2017 10:38:41 -0700 (PDT)
Received: from localhost ([201.157.174.156])
	by smtp.gmail.com with ESMTPSA id y20sm4014139oty.2.2017.06.24.10.38.38
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 10:38:40 -0700 (PDT)
Date: Sat, 24 Jun 2017 12:38:28 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Chet Ramey <chet.ramey@case.edu>
Cc: "skynet@top-email.net" <skynet@top-email.net>, bug-bash@gnu.org
Subject: Re: Bug in select-command
Message-ID: <20170624173828.zvrad4dmneh5w3t6@debian>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
	<13b3afe7-8b23-b663-6f77-0b1c3ca747a1@case.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <13b3afe7-8b23-b663-6f77-0b1c3ca747a1@case.edu>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::243
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 17:38:49 -0000

On Sat, Jun 24, 2017 at 01:17:23PM -0400, Chet Ramey wrote:
[...]
> You haven't exported these.  If you had, the subshell started to run the
> script would have the correct values.

Hm. I think this may be a documentation / usability problem.

The manual states the following:

  COLUMNS
	 Used  by the select compound command to determine the terminal width
	 when printing selection lists.  *Automatically set if the checkwinsize
	 option is enabled* or in an interactive shell upon receipt of a
         SIGWINCH.

  [...]

  checkwinsize
	  If set, bash checks the window size after each command and, if
	  necessary, updates the values of LINES and COLUMNS.

Furthermore, POSIX [1] says the following:

  COLUMNS
	  This variable shall represent a decimal integer >0 used to indicate
	  the user's preferred width in column positions for the terminal
	  screen or window; see Column Position. If this variable is unset or
	  null, the implementation determines the number of columns,
	  appropriate for the terminal or window, in an unspecified manner.
	  When COLUMNS is set, any terminal-width information implied by TERM
	  is overridden. Users and conforming applications should not set
	  COLUMNS unless they wish to override the system selection and produce
	  output unrelated to the terminal characteristics.

	  Users *should not need to set this variable in the environment*
	  unless there is a specific reason to override the implementation's
	  default behavior, such as to display data in an area arbitrarily
	  smaller than the terminal or window.

So, from the manual alone, I know the following:

- `select' uses the COLUMNS variable to determine the terminal width
- the value of COLUMNS is automatically set if the `checkwinsize' option is
  enabled (** restrictions apply).
- bash checks the window size after each command

I have the following problems with the documentation:

- It seems to imply that it's set automatically *when* `checkwinsize' is
  enabled. A careful reading uncovers that this is not true though, and that
  you have to run a command for the window size to be checked.
- It doesn't mention that the window size is NOT checked after *builtin*
  commands.
- POSIX recommends against exporting the COLUMNS variable.

I know that I can get the desired behavior by either:

- Running the script under an interactive shell
- Setting `checkwinsize' and running a dummy external command to trigger the
window size check.
- Exporting the COLUMNS variable from the parent interactive shell.

I think that's too much hassle, when bash could easily:

- If the `select' statement is used and `checkwinsize' is set and
  `COLUMNS' is unset, then call `get_new_window_size'
- Call `get_new_window_size' when `checkwinsize' is enabled.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap08.html#tag_08_03

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 13:41:52 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOp4C-0001su-5Y
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 13:41:52 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:41051)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOp47-0001s9-Ut
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:41:49 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOp44-0003n2-T1
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:41:47 -0400
Received: from mail-ot0-x22b.google.com ([2607:f8b0:4003:c0f::22b]:34880)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOp44-0003m4-MO
	for bug-bash@gnu.org; Sat, 24 Jun 2017 13:41:44 -0400
Received: by mail-ot0-x22b.google.com with SMTP id u13so48403386otd.2
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 10:41:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:subject:message-id:mime-version:content-disposition
	:content-transfer-encoding:user-agent;
	bh=hucKXu+w4Bd6YfTBci51vGmTFZYthu4SK6+r27ltOjQ=;
	b=EVRuGNxa9qBRuSbzndiFRK1vy+WMVybsvtI9uaMqlGuccqtjjtPMXn5nK3+4kaVJN2
	UQQRrNRU1C6iJyjydMH2+TjdOJaFl65n7tiYZ5X0OhaJCniLWhNw+s8DlSnliFlg1wfo
	SMVG/bDygXLgqBcWoU3CMUj6ZImc4O2Mkm65rNbAlRdC4bkZuYkNF5g0KrQadomYWTZU
	8gmF4yfQ8IEf2LFILo4gZEoPC5quzs5upkGfn3plVdJdybjWlKD39LIiesoFdyx1Exam
	X4YzMifuT4aYbllt9qFldXy8v2pbBxdc5pORVfsBXb6FX0oceFqj37Uc4fzV31YRAN+0
	6d0A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:subject:message-id:mime-version
	:content-disposition:content-transfer-encoding:user-agent;
	bh=hucKXu+w4Bd6YfTBci51vGmTFZYthu4SK6+r27ltOjQ=;
	b=jQ92MEzwvx5UJFqCm/Q4yvA/xafnV5M1SztvPD7WnxxDBQmAlRTGlPSiSBPZEY2HVi
	aIRlB6Hkp3Y6by1lxDoYKMYt8S+SCXgm/sjWkEhaLKyAlAzgcpsabjyX0l9J+x5RieHP
	Z0MerIXurSB+MBFGEXuZQN4XTWg8wjvOO3UW+htOR4lVD7gH+fsSlTY8hU1h0+vU5jE8
	4Iqrv8E+khns3ua8kIxiDyH/RAHi9l7uFpFC8u4lZWXD2gdo0H5bsE0tZTbbiq6g+O+l
	65aRmicBPXpLbFvIoA3oxEcX9ujpszidiEmUIibUZhHBtZ/3BMvdKt0TblGwx3Hgty5l
	VKrA==
X-Gm-Message-State: AKS2vOzd5MHzUs2uHoKuaH9H9ZRAfSBUtjqvZbEaIHCCq5sshDNQsVhy
	M9/IUEeILWDAHDcc
X-Received: by 10.157.35.27 with SMTP id j27mr9399907otb.186.1498326103807;
	Sat, 24 Jun 2017 10:41:43 -0700 (PDT)
Received: from localhost ([201.157.174.156]) by smtp.gmail.com with ESMTPSA id
	j36sm3622350oth.12.2017.06.24.10.41.39
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 10:41:42 -0700 (PDT)
Date: Sat, 24 Jun 2017 12:41:30 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: bug-bash@gnu.org
Subject: Re: Fwd: Non-upstream patches for bash (2014)
Message-ID: <20170624174130.b7wkdnjurzdalc35@debian>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c0f::22b
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 17:41:49 -0000

I was looking through this old thread:
http://seclists.org/oss-sec/2014/q3/851

It looks like the issue reported in there is still there:

  dualbus@debian:~$ LANG=zh_CN.GBK printf 'echo \u4e57\n' |LANG=zh_CN.GBK bash
  �\
  dualbus@debian:~$ LANG=en_US.UTF8 printf 'echo \u4e57\n' |LANG=en_US.UTF8 bash
  乗
  dualbus@debian:~$ LANG=zh_CN.GBK printf 'echo \u4e57\n' |LANG=zh_CN.GBK mksh
  �
  dualbus@debian:~$ LANG=zh_CN.GBK printf 'echo \u4e57\n' |LANG=zh_CN.GBK ksh
  �\
  dualbus@debian:~$ LANG=zh_CN.GBK printf 'echo \u4e57\n' |LANG=zh_CN.GBK zsh
  �
(In the case that your font doesn't render the glyph for U+4E57, it's:
http://www.unicode.org/cgi-bin/GetUnihanData.pl?codepoint=4e57)

  dualbus@debian:~$ LANG=zh_CN.GBK printf '\u4e57' | od -tx1 -An
   81 5c

It looks like it doesn't detect that \x81\x5c is a single character, and
instead treats the multibyte character as separate characters.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 16:47:05 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOrxR-0007zN-QP
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 16:47:05 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:40025)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dOrxP-0007zG-1W
	for bug-bash@gnu.org; Sat, 24 Jun 2017 16:47:04 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dOrxL-0004ZJ-Q1
	for bug-bash@gnu.org; Sat, 24 Jun 2017 16:47:02 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:45670
	helo=homiemail-a48.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dOrxL-0004WQ-Dx
	for bug-bash@gnu.org; Sat, 24 Jun 2017 16:46:59 -0400
Received: from homiemail-a48.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a48.g.dreamhost.com (Postfix) with ESMTP id 7CFBC70D430B; 
	Sat, 24 Jun 2017 13:46:49 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=xgJRa0p29552go0S
	p/Ycd6S4aZE=; b=ryDHNKsWpPZJj0rlOekUN4UI4egn8TuCskdmycsNLU1KH6rw
	cUUYFddMj47b5yvwITgB3Wrm0w3j/874fBQI+7IyoA2hcmTiYRKr62jLEytvUaXX
	R4HjAtKd91awq/XBouKZ2UVnbnhLealC0nbqVrqIF+j2XvQtSvZY6twUGDs=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a48.g.dreamhost.com (Postfix) with ESMTPSA id 22EE670D430A;
	Sat, 24 Jun 2017 13:46:49 -0700 (PDT)
Message-ID: <1498337207.20019.15.camel@scope-eye.net>
Subject: Re: Fwd: Non-upstream patches for bash (2014)
From: George <tetsujin@scope-eye.net>
To: "Eduardo A. Bustamante" =?ISO-8859-1?Q?L=F3pez?= <dualbus@gmail.com>, 
	bug-bash@gnu.org
Date: Sat, 24 Jun 2017 16:46:47 -0400
In-Reply-To: <20170624174130.b7wkdnjurzdalc35@debian>
References: <20170624174130.b7wkdnjurzdalc35@debian>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 20:47:04 -0000

On Sat, 2017-06-24 at 12:41 -0500, Eduardo A. Bustamante L=C3=B3pez wrote=
:
> I was looking through this old thread:
> http://seclists.org/oss-sec/2014/q3/851
>=20
> It looks like the issue reported in there is still there:
>=20
> =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf 'echo \u4e57\n' |LANG=3D=
zh_CN.GBK bash
> =C2=A0 =EF=BF=BD\
> =C2=A0 dualbus@debian:~$ LANG=3Den_US.UTF8 printf 'echo \u4e57\n' |LANG=
=3Den_US.UTF8 bash
> =C2=A0 =E4=B9=97
> =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf 'echo \u4e57\n' |LANG=3D=
zh_CN.GBK mksh
> =C2=A0 =EF=BF=BD
> =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf 'echo \u4e57\n' |LANG=3D=
zh_CN.GBK ksh
> =C2=A0 =EF=BF=BD\
> =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf 'echo \u4e57\n' |LANG=3D=
zh_CN.GBK zsh
> =C2=A0 =EF=BF=BD
> (In the case that your font doesn't render the glyph for U+4E57, it's:
> http://www.unicode.org/cgi-bin/GetUnihanData.pl?codepoint=3D4e57)
>=20
> =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf '\u4e57' | od -tx1 -An
> =C2=A0=C2=A0=C2=A081 5c
>=20
> It looks like it doesn't detect that \x81\x5c is a single character, an=
d
> instead treats the multibyte character as separate characters.
>=20
I'm not seeing the problem here (at least, not in Bash or ksh - mksh and =
zsh seem to have gotten it wrong...)
Bash and ksh (in GBK locale) are outputting $'\u4E57' as a two-byte seque=
nce, (0x81, 0x5C), and then you're reading that back into bash and ksh
(respectively) under the same locale, and that same two-byte sequence is =
being retained. If your terminal were in a GBK or GB18030 locale, the
character would be displayed correctly, too.
That said, this seems to not work as well:
$ LANG=3Dzh_CN.GBK printf "echo \$'%s'" $'\u4e57n' |LANG=3Dzh_CN.GBK bash
=EF=BF=BD
The test checks to see whether the 0x5c byte (as part of a multi-byte cha=
racter) is treated like a backslash in the $'..' quoting syntax - in this
case, it is treated as a backslash, and the '\n' sequence is turned into =
a newline.

From MAILER-DAEMON Sat Jun 24 18:01:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOt7p-0001Di-Fv
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 18:01:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52917)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOt7m-0001Db-Or
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:01:51 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dOt7j-0007q6-Le
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:01:50 -0400
Received: from mail-pf0-x234.google.com ([2607:f8b0:400e:c00::234]:32835)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dOt7j-0007ps-Fm
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:01:47 -0400
Received: by mail-pf0-x234.google.com with SMTP id e7so38334179pfk.0
	for <bug-bash@gnu.org>; Sat, 24 Jun 2017 15:01:47 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=XJFMmFo0cHH2Xnbsi6WLx5R25UMjt6C02H3TJtC1I3I=;
	b=O4drtyyXUQ7VGCNbP4e5H9wmBhZnjz2vWN+BEWD3fxNcZJ9b69inH1kX/PflQovy1G
	VDKdsYChk45286MERIRYvtPv5SSmERLH3KEMo64BEekogdoUmkwuqmt1Cwp27xsv42JV
	8cV26DQbgKqnUe3vf6GuMkUquAojw/csHu+vJ3wlTpo8NWTPPWn/4qPXbjv+ChtnJXmj
	ki1bZ6XY7PK8ym5Q1TdGz7zSf1kU5cjhMj5UEbo6c6EJUBRcDjWf9+sQyrgdRSH1mS1h
	ECcuaKMuIcgP5T48mYqkn6xbesDYrGJ/o+dWAld3vIDXd3lPbR0n86M0b/u4SiL2HDzL
	6Q6g==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=XJFMmFo0cHH2Xnbsi6WLx5R25UMjt6C02H3TJtC1I3I=;
	b=Y1xXq4H5eRS+XZl90Z+Vs3uXEoHboq9acvyyqzm0EYX3rH0NJHChdFftbsiAxKxwHL
	A/a6FaSjtgKdmSqnQ2vJKzz+SZaNylgy2eBlNL4VS+ZruQkx/JbJzYRx8GfbGIQjQQDn
	6+MBNt0HhVTwKmyJKJ875qKMyJVfux4na/kflfZVUmmezDX0c1aAMxOp+MmGUhrcGYDw
	C35uCwqo4Qq6g0Ho1qGrTkWIBetchjykl+DrNXY+JJF3L4deVlxw9iCjfZ08TQYvj1bx
	UQnBFqcKRoAG07Jh/GRitFuqFxKdWhVth30IhRReKrRQU2wh68wbti8TaxG5sljaIalh
	arzw==
X-Gm-Message-State: AKS2vOxruxebkdNDpODONb0hKEgXQpKnND58GHnllLCjpBBtWIPEQ7Vw
	Qy9TqEeYV35qVDJE
X-Received: by 10.84.148.203 with SMTP id y11mr16201197plg.211.1498341706433; 
	Sat, 24 Jun 2017 15:01:46 -0700 (PDT)
Received: from localhost ([159.153.60.75]) by smtp.gmail.com with ESMTPSA id
	y15sm13562319pgs.33.2017.06.24.15.01.45
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Sat, 24 Jun 2017 15:01:45 -0700 (PDT)
Date: Sat, 24 Jun 2017 17:01:43 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: George <tetsujin@scope-eye.net>
Cc: bug-bash@gnu.org
Subject: Re: Fwd: Non-upstream patches for bash (2014)
Message-ID: <20170624220143.iflrqxul2x4fidml@debian>
References: <20170624174130.b7wkdnjurzdalc35@debian>
	<1498337207.20019.15.camel@scope-eye.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <1498337207.20019.15.camel@scope-eye.net>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400e:c00::234
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 22:01:51 -0000

On Sat, Jun 24, 2017 at 04:46:47PM -0400, George wrote:
[...]
> I'm not seeing the problem here (at least, not in Bash or ksh - mksh and zsh seem to have gotten it wrong...)

You are right. I should get some sleep. FWIW, the original claim is that
having a locale-dependent parser is a problem.

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Sat Jun 24 18:13:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dOtJD-00049Z-UF
	for mharc-bug-bash@gnu.org; Sat, 24 Jun 2017 18:13:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54269)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <P@draigBrady.com>) id 1dOtJC-00049Q-25
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:13:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <P@draigBrady.com>) id 1dOtJ8-0002mP-QY
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:13:38 -0400
Received: from mail.magicbluesmoke.com ([82.195.144.49]:41468)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <P@draigBrady.com>) id 1dOtJ8-0002lu-KX
	for bug-bash@gnu.org; Sat, 24 Jun 2017 18:13:34 -0400
Received: from localhost.localdomain (unknown [73.93.155.38])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by mail.magicbluesmoke.com (Postfix) with ESMTPSA id A87FE9510;
	Sat, 24 Jun 2017 23:13:31 +0100 (IST)
Subject: Re: Worth mentioning in documentation
To: Eric Blake <eblake@redhat.com>, Juanma
	<juan-manuel.menendez@tecsidel.es>, Greg Wooledge <wooledg@eeg.ccf.org>
References: <3156909.AJj7susDjE@debxuan> <2473887.nPWqTkAiyd@debxuan>
	<20150807122454.GU4309@eeg.ccf.org> <3273328.haPDicsXFC@debxuan>
	<55C89F4C.1040509@redhat.com>
Cc: "bug-bash@gnu.org" <bug-bash@gnu.org>
From: =?UTF-8?Q?P=c3=a1draig_Brady?= <P@draigBrady.com>
Message-ID: <2d3cbf7b-deaf-e63a-55a6-ffc23b2eba19@draigBrady.com>
Date: Sat, 24 Jun 2017 15:13:29 -0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
	Thunderbird/45.8.0
MIME-Version: 1.0
In-Reply-To: <55C89F4C.1040509@redhat.com>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 82.195.144.49
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sat, 24 Jun 2017 22:13:39 -0000

On 10/08/15 05:55, Eric Blake wrote:
> On 08/10/2015 02:18 AM, Juanma wrote:
>=20
>> Here is another point I find confusing: I thought a "shell builtin" di=
dn't have a separate binary executable file, like 'cd' (which cd =3D> fai=
l),
>=20
> Actually, POSIX requires that there be a separate 'cd' binary, although
> it does not have to behave the same as the shell builtin.  (About all a=
n
> exec'able cd can do is tell you by exit status whether the builtin cd
> would succeed or fail; or be used for its CDPATH side-effect of printin=
g
> a directory name).
>=20
> GNU/Linux systems tend to ignore the POSIX requirement of exec'able
> counterparts, although here is how Solaris effectively does it:
>=20
> $ cat /bin/cd
> #!/bin/sh
> exec $(basename $0) "$@"
> $
>=20
> and hard-linking that 2-liner to all of the shell builtins where POSIX
> requires to have a non-builtin counterpart.
>=20
> See also http://austingroupbugs.net/view.php?id=3D705
>=20
> It is only the special builtins (such as 'exit') where POSIX does not
> require an exec'able counterpart.

For the record I see this on Fedora 25


$ rpm -q bash
bash-4.3.43-4.fc25.x86_64

$ rpm -ql bash | grep /bin/ | grep -v bash
/usr/bin/alias
/usr/bin/bg
/usr/bin/cd
/usr/bin/command
/usr/bin/fc
/usr/bin/fg
/usr/bin/getopts
/usr/bin/hash
/usr/bin/jobs
/usr/bin/read
/usr/bin/sh
/usr/bin/type
/usr/bin/ulimit
/usr/bin/umask
/usr/bin/unalias
/usr/bin/wait

$ cat /usr/bin/cd
#!/bin/sh
builtin cd "$@"

cheers,
P=C3=A1draig


From MAILER-DAEMON Sun Jun 25 09:21:25 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dP7Th-0000b3-LU
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 09:21:25 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45794)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dP7Tf-0000ap-QF
	for bug-bash@gnu.org; Sun, 25 Jun 2017 09:21:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <jidanni@jidanni.org>) id 1dP7Ta-0003SS-Tr
	for bug-bash@gnu.org; Sun, 25 Jun 2017 09:21:23 -0400
Received: from homie.mail.dreamhost.com ([208.97.132.208]:57712
	helo=homiemail-a60.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <jidanni@jidanni.org>) id 1dP7Ta-0003Rr-Lm
	for bug-bash@gnu.org; Sun, 25 Jun 2017 09:21:18 -0400
Received: from homiemail-a60.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a60.g.dreamhost.com (Postfix) with ESMTP id C3A4F3BC06B;
	Sun, 25 Jun 2017 06:21:16 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc
	:subject:references:date:message-id:mime-version:content-type;
	s=jidanni.org; bh=z4Q4/M+tIvDRx12NIuXzQhfpZ/M=; b=BSQkexm80ulSJ
	DEAUjMZJ4209YxuPgq1YVTrZylHtuDhLH3EyypBNPtl9s+khuWhjXDm0Mtqn3E+J
	CxDw/Dm2hE8l1p5CdV+xYrIoqodc1POyKnp0d8Obu0C9cFG1t3n6sd+w29ZVQge4
	x1OZ3aRvYn3ogF8x+RuykDdzF7qV0M=
Received: from jidanni.org (114-46-57-78.dynamic-ip.hinet.net [114.46.57.78])
	(using TLSv1 with cipher AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: jidanni@jidanni.org)
	by homiemail-a60.g.dreamhost.com (Postfix) with ESMTPSA id 882563BC059; 
	Sun, 25 Jun 2017 06:21:16 -0700 (PDT)
From: =?utf-8?B?56mN5Li55bC8?= Dan Jacobson <jidanni@jidanni.org>
To: Chet Ramey <chet.ramey@case.edu>
Cc: bug-bash@gnu.org
Subject: Re: expand x*y concludes with one
References: <874lv64h09.fsf@jidanni.org>
Date: Sun, 25 Jun 2017 21:21:14 +0800
Message-ID: <8760fkqk39.fsf@jidanni.org>
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy]
X-Received-From: 208.97.132.208
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Jun 2017 13:21:24 -0000

OK I submitted
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=865875
against bash-completion.


From MAILER-DAEMON Sun Jun 25 12:24:08 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPAKW-00054T-Oi
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 12:24:08 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46184)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAKU-00053d-GF
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:24:07 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAKR-0003wS-BU
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:24:06 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:60679
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPAKR-0003vv-6D
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:24:03 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMN65694; Sun, 25 Jun 2017 12:24:01 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HTH24523 (AUTH cpr);
	Sun, 25 Jun 2017 12:23:58 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Fwd: Non-upstream patches for bash (2014)
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170624174130.b7wkdnjurzdalc35@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <3c30c826-87d1-bb0a-0240-61e5da8b27c6@case.edu>
Date: Sun, 25 Jun 2017 12:23:57 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170624174130.b7wkdnjurzdalc35@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.25.153616:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_1100_1199, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Jun 2017 16:24:07 -0000

On 6/24/17 1:41 PM, Eduardo A. Bustamante López wrote:
> I was looking through this old thread:
> http://seclists.org/oss-sec/2014/q3/851
> 
> It looks like the issue reported in there is still there:
> 
>   dualbus@debian:~$ LANG=zh_CN.GBK printf 'echo \u4e57\n' |LANG=zh_CN.GBK bash
>   �\
>   dualbus@debian:~$ LANG=en_US.UTF8 printf 'echo \u4e57\n' |LANG=en_US.UTF8 bash
>   乗

This shows that if it's a valid character in the current locale, bash will
convert it and read it back.  `printf' takes the unicode encoding (in this
case, a three-byte character) and runs it through iconv to try and convert
it to a valid multibyte character in the current locale.

>   dualbus@debian:~$ LANG=zh_CN.GBK printf '\u4e57' | od -tx1 -An
>    81 5c
> 
> It looks like it doesn't detect that \x81\x5c is a single character, and
> instead treats the multibyte character as separate characters.

It's apparently not a single character in that locale.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 25 12:27:53 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPAO9-0006W8-Ca
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 12:27:53 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:46960)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAO7-0006Vn-J3
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:27:52 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAO4-0005la-EV
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:27:51 -0400
Received: from mpv4-2015.cwru.edu ([129.22.103.195]:50536
	helo=mpv4-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPAO4-0005lT-9B
	for bug-bash@gnu.org; Sun, 25 Jun 2017 12:27:48 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv4-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMI66618; Sun, 25 Jun 2017 12:27:43 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSQ99966 (AUTH cpr);
	Sun, 25 Jun 2017 12:27:42 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Bug in select-command
To: "skynet@top-email.net" <skynet@top-email.net>, bug-bash@gnu.org
References: <3422067.bOg8qTKhfZ@pc0>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <f3ebf5fc-bb81-315c-e978-db003d926575@case.edu>
Date: Sun, 25 Jun 2017 12:27:41 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <3422067.bOg8qTKhfZ@pc0>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.25.151816:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NO_NAME,
	__TO_NAME, __REFERENCES, __HAS_FROM, FROM_EDU_TLD,
	__HAS_MSGID, __SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW, BODY_SIZE_600_699,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	__FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS, IN_REP_TO,
	MSG_THREAD, __FROM_DOMAIN_IN_RCPT, MULTIPLE_REAL_RCPTS,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.195
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Jun 2017 16:27:52 -0000

On 6/24/17 7:46 AM, skynet@top-email.net wrote:
> It is necessary to refresh the variable $COLUMNS in a script (COLUMNS="tput 
> cols") otherwise the command "select" will not set the number of columns 
> correctly for actual screen resolution.
> 
> Information:		checkwinsize    on

I can't see anywhere in the script where you set the checkwinsize option,
so I can't see what you think the effect should be of having it set in
the parent shell.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 25 13:01:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPAur-0005jU-Ri
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 13:01:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51743)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAup-0005j5-ED
	for bug-bash@gnu.org; Sun, 25 Jun 2017 13:01:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPAum-00020D-A8
	for bug-bash@gnu.org; Sun, 25 Jun 2017 13:01:39 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:63109
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPAum-0001zd-4N
	for bug-bash@gnu.org; Sun, 25 Jun 2017 13:01:36 -0400
Received: from mpv8-2015.CWRU.Edu (EHLO mpv8-2015.case.edu) ([129.22.103.210])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMN66331; Sun, 25 Jun 2017 13:01:31 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv8-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HTH38527 (AUTH cpr);
	Sun, 25 Jun 2017 13:01:31 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: Bug in select-command
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	"skynet@top-email.net" <skynet@top-email.net>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <265c7d34-51ce-8147-2ed6-41a2976bfd6c@case.edu>
Date: Sun, 25 Jun 2017 13:01:28 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170624144647.6lp2axilj7p3y5ps@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.25.153616:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1800_1899,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Jun 2017 17:01:40 -0000

On 6/24/17 10:46 AM, Eduardo A. Bustamante López wrote:

> I think this is an easier way to reproduce the problem. I have a terminal
> window with the following dimensions:
> 
>   dualbus@debian:~$ declare -p COLUMNS LINES
>   declare -- COLUMNS="191"
>   declare -- LINES="49"
> 
>   dualbus@debian:~$ bash --version | head -n1
>   GNU bash, version 4.4.12(1)-release (x86_64-pc-linux-gnu)
> 
> Running the script in `interactive' mode (which triggers calls to
> `get_new_window_size' through `get_tty_state' when checkwinsize is
> enabled), lays out the options on seven columns:

Yes, bash is actually doing more work here than it should. The reason for
the calls to get_tty_state is if a program terminates prematurely and
leaves the terminal in a state where interactive input is inconvenient
(noecho mode, for example). If bash isn't reading input from the terminal,
this isn't strictly necessary. But for now, it works.


> Whereas running the same script in `non-interactive' mode results in three
> columns.

Yes, there's no reason to worry about tty settings, so the shell relies on
the environment for the value of COLUMNS.  If it's not there, or doesn't
have a sane value, select defaults to 80.

> So the trick is to run an external command in foreground. To see why this
> works, read:
> http://git.savannah.gnu.org/cgit/bash.git/tree/jobs.c?h=devel#n3390

Yes, since the point is to protect interactive shell input from badly-
behaved external programs that can modify the terminal settings.  The
shell knows what it does to the terminal and how to undo it.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 25 17:29:10 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPF5i-0002H6-SY
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 17:29:10 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38457)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPF5g-0002Gy-EN
	for bug-bash@gnu.org; Sun, 25 Jun 2017 17:29:09 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPF5c-0007Re-Ed
	for bug-bash@gnu.org; Sun, 25 Jun 2017 17:29:08 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:37135
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPF5c-0007Qq-8O
	for bug-bash@gnu.org; Sun, 25 Jun 2017 17:29:04 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANS72593; Sun, 25 Jun 2017 17:28:58 -0400 (EDT)
Received: from h164.51.131.174.dynamic.ip.windstream.net (EHLO
	_192.168.254.9_) ([174.131.51.164])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HSY78449 (AUTH cpr);
	Sun, 25 Jun 2017 17:28:54 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, "skynet@top-email.net" <skynet@top-email.net>,
	bug-bash@gnu.org
Subject: Re: Bug in select-command
To: "=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>
References: <3422067.bOg8qTKhfZ@pc0> <20170624144647.6lp2axilj7p3y5ps@debian>
	<13b3afe7-8b23-b663-6f77-0b1c3ca747a1@case.edu>
	<20170624173828.zvrad4dmneh5w3t6@debian>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <633555a9-5d40-856e-d555-87bcf916982f@case.edu>
Date: Sun, 25 Jun 2017 17:28:51 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <20170624173828.zvrad4dmneh5w3t6@debian>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.25.210016:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__CC_NAME, __BOUNCE_CHALLENGE_SUBJ,
	__BOUNCE_NDR_SUBJ_EXEMPT, __SUBJ_ALPHA_END,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __INVOICE_MULTILINGUAL,
	__SUBJ_ALPHA_NEGATE, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW, BODY_SIZE_3000_3999,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Sun, 25 Jun 2017 21:29:09 -0000

On 6/24/17 1:38 PM, Eduardo A. Bustamante López wrote:
> On Sat, Jun 24, 2017 at 01:17:23PM -0400, Chet Ramey wrote:
> [...]
>> You haven't exported these.  If you had, the subshell started to run the
>> script would have the correct values.
> 
> Hm. I think this may be a documentation / usability problem.

It's a documentation problem, since the documentation doesn't completely
reflect the behavior.

> The manual states the following:
> 
>   COLUMNS
> 	 Used  by the select compound command to determine the terminal width
> 	 when printing selection lists.  *Automatically set if the checkwinsize
> 	 option is enabled* or in an interactive shell upon receipt of a
>          SIGWINCH.

Yes, and the checkwinsize description has the details of how it does that.

>   [...]
> 
>   checkwinsize
> 	  If set, bash checks the window size after each command and, if
> 	  necessary, updates the values of LINES and COLUMNS.

This should be after each external (non-builtin) command.

> Furthermore, POSIX [1] says the following:
> 
>   COLUMNS
> 	  This variable shall represent a decimal integer >0 used to indicate
> 	  the user's preferred width in column positions for the terminal
> 	  screen or window; see Column Position. If this variable is unset or
> 	  null, the implementation determines the number of columns,
> 	  appropriate for the terminal or window, in an unspecified manner.

This is Posix-speak for "we don't know how it does it, but we assume the
appropriate value is put into COLUMNS and exported somehow," since "the
implementation" doesn't mean "the shell".


> 	  When COLUMNS is set, any terminal-width information implied by TERM
> 	  is overridden. Users and conforming applications should not set
> 	  COLUMNS unless they wish to override the system selection and produce
> 	  output unrelated to the terminal characteristics.
> 
> 	  Users *should not need to set this variable in the environment*
> 	  unless there is a specific reason to override the implementation's
> 	  default behavior, such as to display data in an area arbitrarily
> 	  smaller than the terminal or window.

In this case, the implementation's default behavior is to not export
COLUMNS or, apparently, set it in non-interactive shells.

> 
> So, from the manual alone, I know the following:
> 
> - `select' uses the COLUMNS variable to determine the terminal width
> - the value of COLUMNS is automatically set if the `checkwinsize' option is
>   enabled (** restrictions apply).
> - bash checks the window size after each command

So it's a documentation problem concerning what "each command" means.

> I have the following problems with the documentation:
> 
> - It seems to imply that it's set automatically *when* `checkwinsize' is

That's not what it says.  It says "if", not "when".  The description of
`checkwinsize' should describe the circumstances under which it acts.

> - It doesn't mention that the window size is NOT checked after *builtin*
>   commands.

And that is the problem.

> - POSIX recommends against exporting the COLUMNS variable.

No, it doesn't. It says that it should usually not be necessary.  If you
find that your implementation doesn't make the value available, you have
the option to export it.
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Sun Jun 25 23:08:51 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPKOQ-0002GX-VN
	for mharc-bug-bash@gnu.org; Sun, 25 Jun 2017 23:08:50 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50673)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPKOO-0002GI-G1
	for bug-bash@gnu.org; Sun, 25 Jun 2017 23:08:49 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPKOL-0002xV-Ar
	for bug-bash@gnu.org; Sun, 25 Jun 2017 23:08:48 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:54921
	helo=homiemail-a114.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dPKOL-0002wJ-2O
	for bug-bash@gnu.org; Sun, 25 Jun 2017 23:08:45 -0400
Received: from homiemail-a114.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a114.g.dreamhost.com (Postfix) with ESMTP id 561C448000A2E;
	Sun, 25 Jun 2017 20:08:38 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:subject:from:to:date:in-reply-to:references
	:content-type:mime-version; s=scope-eye.net; bh=FGSk6mNeB1N3LUEB
	T2LQkUZ3SUI=; b=Jb1BrJsdv+/8XNKaSB3k9dW5/yh3aTfpMW1fNHFylUHFpJbs
	+rlcm9DCZtb/xA5AqKOQw7EaOM9KEfN14TFuM3uFA7XU6Iv9318g0EliIf/8O880
	3DT6SF5BV88KsbtPKwFCnsf1rt/OvZkwfxt7sVZoPrUwM7/BIGdQ0nelCy4=
Received: from frontier (pool-108-49-70-33.bstnma.fios.verizon.net
	[108.49.70.33])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a114.g.dreamhost.com (Postfix) with ESMTPSA id
	E467248000A2B; Sun, 25 Jun 2017 20:08:37 -0700 (PDT)
Message-ID: <1498446517.3912.6.camel@scope-eye.net>
Subject: Re: Fwd: Non-upstream patches for bash (2014)
From: George <tetsujin@scope-eye.net>
To: chet.ramey@case.edu, "Eduardo A. Bustamante" =?ISO-8859-1?Q?L=F3pez?=
	<dualbus@gmail.com>, bug-bash@gnu.org
Date: Sun, 25 Jun 2017 23:08:37 -0400
In-Reply-To: <3c30c826-87d1-bb0a-0240-61e5da8b27c6@case.edu>
References: <20170624174130.b7wkdnjurzdalc35@debian>
	<3c30c826-87d1-bb0a-0240-61e5da8b27c6@case.edu>
X-Mailer: Evolution 3.18.5.1-1 
Mime-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 03:08:49 -0000

On Sun, 2017-06-25 at 12:23 -0400, Chet Ramey wrote:
> On 6/24/17 1:41 PM, Eduardo A. Bustamante L=C3=B3pez wrote:
>=20
> >=20
> > =C2=A0 dualbus@debian:~$ LANG=3Dzh_CN.GBK printf '\u4e57' | od -tx1 -=
An
> > =C2=A0=C2=A0=C2=A081 5c
> >=20
> > It looks like it doesn't detect that \x81\x5c is a single character, =
and
> > instead treats the multibyte character as separate characters.
> It's apparently not a single character in that locale.
>=20
Yes it is!
https://en.wikipedia.org/wiki/GBK
\x81 \x5C is a two-byte character from level GBK/3.
But unless I've misunderstood something, it seems to be behaving correctl=
y already. At least, with the exception of within $'..' quotes.

From MAILER-DAEMON Mon Jun 26 09:33:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPU8d-0000M4-1a
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 09:33:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:51502)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <Angus.Duggan@globalgraphics.com>) id 1dPTpt-0000HN-1V
	for bug-bash@gnu.org; Mon, 26 Jun 2017 09:13:54 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <Angus.Duggan@globalgraphics.com>) id 1dPTpK-0007QO-8T
	for bug-bash@gnu.org; Mon, 26 Jun 2017 09:13:48 -0400
Received: from smtp-out4.electric.net ([192.162.216.189]:63818)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <Angus.Duggan@globalgraphics.com>)
	id 1dPTpK-0007GZ-0J
	for bug-bash@gnu.org; Mon, 26 Jun 2017 09:13:14 -0400
Received: from 1dPTp4-00069g-U5 by out4d.electric.net with emc1-ok (Exim 4.87)
	(envelope-from <Angus.Duggan@globalgraphics.com>) id 1dPTp4-0006Bt-VE
	for bug-bash@gnu.org; Mon, 26 Jun 2017 06:12:58 -0700
Received: by emcmailer; Mon, 26 Jun 2017 06:12:58 -0700
Received: from [82.1.12.131] (helo=mail.globalgraphics.com)
	by out4d.electric.net with esmtps
	(TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.87)
	(envelope-from <Angus.Duggan@globalgraphics.com>) id 1dPTp4-00069g-U5
	for bug-bash@gnu.org; Mon, 26 Jun 2017 06:12:58 -0700
From: Angus Duggan <Angus.Duggan@globalgraphics.com>
To: "bug-bash@gnu.org" <bug-bash@gnu.org>
Subject: Incorrect unicode escapes
Thread-Topic: Incorrect unicode escapes
Thread-Index: AdLufWkVglt6zDfpT6OB+B5gZ4CjCA==
Date: Mon, 26 Jun 2017 13:12:57 +0000
Message-ID: <a82bf5f3dc00417ab92de278ce17bd41@globalgraphics.com>
Accept-Language: en-US, en-GB
Content-Language: en-US
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
x-originating-ip: [172.16.155.10]
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Outbound-IP: 82.1.12.131
X-Env-From: Angus.Duggan@globalgraphics.com
X-Proto: esmtps
X-Revdns: 
X-HELO: mail.globalgraphics.com
X-TLS: TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256
X-Authenticated_ID: 
X-PolicySMART: 3620332
X-Virus-Status: Scanned by VirusSMART (c)
X-Virus-Status: Scanned by VirusSMART (s)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 192.162.216.189
X-Mailman-Approved-At: Mon, 26 Jun 2017 09:33:10 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 13:13:54 -0000

Sorry, bashbug didn't work under cygwin...

BASH_VERSION=3D4.4.12(3)-release
uname -a: CYGWIN_NT-6.1 xxxxxxx 2.8.0(0.309/5/3) 2017-04-01 20:47 x86_64 Cy=
gwin

The function u32toutf16() in lib/sh/unicode.c incorrectly implements
surrogate pairs. \uff08 (Full Width Left Paren) is encoded to the invalid
surrogate pair d7ff df08.

Unicode code points in the range 0xe000-0xffff should be encoded as a singl=
e
16-bit code unit.

To repeat (Windows 64-bit, cygwin):

  export LANG=3Den_us.UTF-8
  echo $'\uff08' | hexdump -C

This prints:

00000000  ed 9f bf ed bc 88 0a                              |.......|
00000007

This is UTF-8 encoding for the two 16-bit values 0xdf77 0xdf08. This is
invalid as a UTF-8 encoding, surrogate pairs should not be UTF-8 encoded.

The fix is simple, add tests for the e000-ffff range, or invert the test
order and add a test for dfff (CAVEAT EMPTOR! THIS IS UNTESTED!):

    if (c >=3D 0x010000 && c <=3D 0x010ffff)
    {
      c -=3D 0x010000;
      s[0] =3D (unsigned short)((c >> 10) + 0xd800);
      s[1] =3D (unsigned short)((c & 0x3ff) + 0xdc00);
      l =3D 2;
    }
    else if (c < 0x0d800 || c > 0xdfff )
    {
      s[0] =3D (unsigned short) (c & 0xFFFF);
      l =3D 1;
    }

a.




From MAILER-DAEMON Mon Jun 26 11:04:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPVZR-0002pG-GU
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 11:04:57 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53242)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPVZP-0002nW-5w
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:04:56 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPVZK-0007qs-7s
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:04:55 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:20392
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPVZK-0007qa-2g
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:04:50 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMN90262; Mon, 26 Jun 2017 11:04:44 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGK36584 (AUTH cpr);
	Mon, 26 Jun 2017 11:04:43 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Fwd: Non-upstream patches for bash (2014)
To: George <tetsujin@scope-eye.net>,
	"=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <20170624174130.b7wkdnjurzdalc35@debian>
	<3c30c826-87d1-bb0a-0240-61e5da8b27c6@case.edu>
	<1498446517.3912.6.camel@scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <c0cb5c5b-638f-4632-dbe9-beda89087d72@case.edu>
Date: Mon, 26 Jun 2017 11:04:42 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <1498446517.3912.6.camel@scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.26.143616:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NAME, __TO_NAME_DIFF_FROM_ACC,
	__REFERENCES, __HAS_FROM, FROM_EDU_TLD, __HAS_MSGID,
	__SANE_MSGID, DATE_TZ_NA, __USER_AGENT,
	__MOZILLA_USER_AGENT, __MIME_VERSION, __IN_REP_TO, __CT,
	__CT_TEXT_PLAIN, __CTE, __REPLYTO_SAMEAS_FROM_ADDY,
	__REPLYTO_SAMEAS_FROM_ACC, __FROM_DOMAIN_IN_ANY_CC1,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __HTTPS_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __FRAUD_MONEY_CURRENCY_DOLLAR,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1200_1299,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, __FROM_DOMAIN_IN_RCPT, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 15:04:56 -0000

On 6/25/17 11:08 PM, George wrote:
> On Sun, 2017-06-25 at 12:23 -0400, Chet Ramey wrote:
>> On 6/24/17 1:41 PM, Eduardo A. Bustamante López wrote:
>>
>>> dualbus@debian:~$ LANG=zh_CN.GBK printf '\u4e57' | od -tx1 -An 81 5c It
>>> looks like it doesn't detect that \x81\x5c is a single character, and
>>> instead treats the multibyte character as separate characters. 
>>
>>
>> It's apparently not a single character in that locale.
>>
> 
> Yes it is!
> 
> https://en.wikipedia.org/wiki/GBK
> \x81 \x5C is a two-byte character from level GBK/3.

OK. The terminal emulator I'm using simply doesn't render the glyph.

> But unless I've misunderstood something, it seems to be behaving correctly
> already. At least, with the exception of within $'..' quotes.

It is behaving correctly. $'...' works using bytes.  You can get it to
expand a byte sequence to a multibyte character using \u or \x, but it
works on bytes and always has, just like in C.  Since 0x5c introduces an
escape sequence, that's how it's treated.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 26 11:19:12 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPVnE-0000qT-QP
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 11:19:12 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57938)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPVnD-0000qM-0V
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:19:11 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPVn9-0005nZ-0R
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:19:10 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:47347
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPVn8-0005my-R3
	for bug-bash@gnu.org; Mon, 26 Jun 2017 11:19:06 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANS93710; Mon, 26 Jun 2017 11:18:37 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGK39317 (AUTH cpr);
	Mon, 26 Jun 2017 11:18:37 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Incorrect unicode escapes
To: Angus Duggan <Angus.Duggan@globalgraphics.com>,
	"bug-bash@gnu.org" <bug-bash@gnu.org>
References: <a82bf5f3dc00417ab92de278ce17bd41@globalgraphics.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <0c3abe35-f47d-af0c-370a-225ff02cf096@case.edu>
Date: Mon, 26 Jun 2017 11:18:36 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <a82bf5f3dc00417ab92de278ce17bd41@globalgraphics.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.26.115416:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	URI_ENDS_IN_HTML, __URI_NO_WWW, __CP_URI_IN_BODY,
	__SUBJ_ALPHA_NEGATE, __MULTIPLE_URI_TEXT, __URI_IN_BODY,
	__URI_NOT_IMG, __FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODY_SIZE_700_799, BODYTEXTP_SIZE_3000_LESS,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 15:19:12 -0000

On 6/26/17 9:12 AM, Angus Duggan wrote:
> Sorry, bashbug didn't work under cygwin...
> 
> BASH_VERSION=4.4.12(3)-release
> uname -a: CYGWIN_NT-6.1 xxxxxxx 2.8.0(0.309/5/3) 2017-04-01 20:47 x86_64 Cygwin
> 
> The function u32toutf16() in lib/sh/unicode.c incorrectly implements
> surrogate pairs. \uff08 (Full Width Left Paren) is encoded to the invalid
> surrogate pair d7ff df08.

Thanks for the report.  This was reported and fixed back in November, 2016
as the result of

http://lists.gnu.org/archive/html/bug-bash/2016-11/msg00039.html

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 26 12:46:32 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPX9k-0001rQ-KV
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 12:46:32 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:55062)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPX9c-0001rD-Rc
	for bug-bash@gnu.org; Mon, 26 Jun 2017 12:46:31 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPX9Z-0002fy-PA
	for bug-bash@gnu.org; Mon, 26 Jun 2017 12:46:24 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:44290
	helo=homiemail-a114.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dPX9Z-0002fV-Dq
	for bug-bash@gnu.org; Mon, 26 Jun 2017 12:46:21 -0400
Received: from homiemail-a114.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a114.g.dreamhost.com (Postfix) with ESMTP id B99DE48000A30;
	Mon, 26 Jun 2017 09:46:19 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=xbgWjx6UlN3uxZlrzweaTyVuIN8=; b=
	f9lUJ99RpBbtknMw0QM3oxgUUSUyiS1l8x1PshXUvKSmAdrNA0qcz0kV4v6Rn92H
	3j7ZZ+Z3OTVBrhUImFiB0miL2UHk8q/oqcUbykORE9/9vF1mHCstEfpkdPy+aim0
	oEmaxATGpOJ2n5PcjA14AbCmhHROb2MNTDIziTgL/FA=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a114.g.dreamhost.com (Postfix) with ESMTPSA id
	9BFAA48000A2F; Mon, 26 Jun 2017 09:46:19 -0700 (PDT)
Message-Id: <38f38de1212b7a311eb4317aa9a2fc4e874836b1@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu, =?UTF-8?B?RWR1YXJkb19BLl9CdXN0YW1hbnRlX0zDs3Bleg==?=
	<dualbus@gmail.com>, bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <c0cb5c5b-638f-4632-dbe9-beda89087d72@case.edu>
Subject: Re: Fwd: Non-upstream patches for bash (2014)
Date: Mon, 26 Jun 2017 12:46:19 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 16:46:31 -0000

=0AIt seems a strange inconsistency, though: Double-quoted strings (and,=
=0Areally, pretty much all other Bash syntax as far as I have seen)=0Are=
cognize 0x81 0x5C as a two-byte character rather than treating 0x5C=0Aas=
 a backslash within the quoting syntax, but $'..' strings=0Aunconditiona=
lly treat 0x5C as a backslash...=C2=A0 Is there any reason a=0Adisparity=
 like that would be desirable?=0A=0A----- Original Message -----=0AFrom:=
 chet.ramey@case.edu=0ATo:"George" <tetsujin@scope-eye.net>, "Eduardo_A.=
_Bustamante_L=C3=B3pez"=0A<dualbus@gmail.com>, <bug-bash@gnu.org>=0ACc:<=
chet.ramey@case.edu>=0ASent:Mon, 26 Jun 2017 11:04:42 -0400=0ASubject:Re=
: Fwd: Non-upstream patches for bash (2014)=0A=0A On 6/25/17 11:08 PM, G=
eorge wrote:=0A > On Sun, 2017-06-25 at 12:23 -0400, Chet Ramey wrote:=
=0A >> On 6/24/17 1:41 PM, Eduardo A. Bustamante L=C3=B3pez wrote:=0A >>=
=0A >>> dualbus@debian:~$ LANG=3Dzh_CN.GBK printf 'u4e57' | od -tx1 -An=
 81=0A5c It=0A >>> looks like it doesn't detect that x81x5c is a single=
 character,=0Aand=0A >>> instead treats the multibyte character as separ=
ate characters. =0A >>=0A >>=0A >> It's apparently not a single characte=
r in that locale.=0A >>=0A > =0A > Yes it is!=0A > =0A > https://en.wiki=
pedia.org/wiki/GBK=0A > x81 x5C is a two-byte character from level GBK/3=
.=0A=0A OK. The terminal emulator I'm using simply doesn't render the gl=
yph.=0A=0A > But unless I've misunderstood something, it seems to be beh=
aving=0Acorrectly=0A > already. At least, with the exception of within $=
'..' quotes.=0A=0A It is behaving correctly. $'...' works using bytes. Y=
ou can get it to=0A expand a byte sequence to a multibyte character usin=
g u or x, but it=0A works on bytes and always has, just like in C. Since=
 0x5c introduces=0Aan=0A escape sequence, that's how it's treated.=0A=0A=
 -- =0A ``The lyf so short, the craft so long to lerne.'' - Chaucer=0A `=
`Ars longa, vita brevis'' - Hippocrates=0A Chet Ramey, UTech, CWRU chet@=
case.edu=0Ahttp://cnswww.cns.cwru.edu/~chet/=0A

From MAILER-DAEMON Mon Jun 26 14:34:43 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPYqR-0003ig-Dl
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 14:34:43 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57573)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPYqP-0003iG-4J
	for bug-bash@gnu.org; Mon, 26 Jun 2017 14:34:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPYqL-0007SC-4i
	for bug-bash@gnu.org; Mon, 26 Jun 2017 14:34:41 -0400
Received: from mpv3-2015.cwru.edu ([129.22.103.194]:57044
	helo=mpv3-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPYqK-0007Ru-Ug
	for bug-bash@gnu.org; Mon, 26 Jun 2017 14:34:37 -0400
Received: from mpv6-2015.CWRU.Edu (EHLO mpv6-2015.case.edu) ([129.22.103.202])
	by mpv3-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id AMO02547; Mon, 26 Jun 2017 14:34:33 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv6-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGC50084 (AUTH cpr);
	Mon, 26 Jun 2017 14:34:32 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Fwd: Non-upstream patches for bash (2014)
To: tetsujin@scope-eye.net,
	"=?UTF-8?Q?Eduardo=5fA.=5fBustamante=5fL=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <38f38de1212b7a311eb4317aa9a2fc4e874836b1@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <bd84a574-4dcf-659c-9836-05939164a123@case.edu>
Date: Mon, 26 Jun 2017 14:34:32 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <38f38de1212b7a311eb4317aa9a2fc4e874836b1@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv3-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.26.173916:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, URI_ENDS_IN_PHP, __ANY_URI,
	__URI_WITH_PATH, __URI_NO_WWW, __CP_URI_IN_BODY,
	__FRAUD_MONEY_CURRENCY_DOLLAR, __SUBJ_ALPHA_NEGATE,
	__MULTIPLE_URI_TEXT, __URI_IN_BODY, __URI_NOT_IMG,
	__FORWARDED_MSG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_1000_1099,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, __FRAUD_MONEY_CURRENCY, BODY_SIZE_5000_LESS,
	IN_REP_TO, MSG_THREAD, [TRUNCATED],
	so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.194
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 18:34:42 -0000

On 6/26/17 12:46 PM, tetsujin@scope-eye.net wrote:
> 
> It seems a strange inconsistency, though: Double-quoted strings (and,
> really, pretty much all other Bash syntax as far as I have seen) recognize
> 0x81 0x5C as a two-byte character rather than treating 0x5C as a backslash
> within the quoting syntax, but $'..' strings unconditionally treat 0x5C as
> a backslash...  Is there any reason a disparity like that would be desirable?

Because that's how C works, and that's how all the shells that currently
implement it work (and have always worked).

Posix has considered this feature on and off (2010, 2015, 2016)[1], albeit
with a lot of tangents.  If it ever gets standardized, I expect this
question to be resolved. When it does, and if it's required, I'll change
Posix mode to match and then we'll see.

[1] http://austingroupbugs.net/view.php?id=249

Chet

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Mon Jun 26 16:35:40 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPajU-00067p-Ov
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 16:35:40 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:56864)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPajR-00065s-3L
	for bug-bash@gnu.org; Mon, 26 Jun 2017 16:35:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dPajN-0006GB-Ji
	for bug-bash@gnu.org; Mon, 26 Jun 2017 16:35:37 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:45440
	helo=homiemail-a91.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dPajN-0006En-6d
	for bug-bash@gnu.org; Mon, 26 Jun 2017 16:35:33 -0400
Received: from homiemail-a91.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a91.g.dreamhost.com (Postfix) with ESMTP id A61AF4713;
	Mon, 26 Jun 2017 13:35:28 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=zqgjVNt+AQQNtGZeCWQnV4dBY4s=; b=
	YJELWqhBnSG+AdFa8Um/EiDcxKggb7QRUce26mLoGSl7I7h9w8sCIa9Q+St+w+P4
	tw3h8Bl++ph5/JCPII+4JUDI+/gh6TGFPnZ5nuCf1ua2LV4D/S8C9qML2p6jf0/t
	/+7xQhM6MwFq63ZSnQh5H5tT4RQG7UhhXu0uwPjoi84=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a91.g.dreamhost.com (Postfix) with ESMTPSA id 8CD29470F;
	Mon, 26 Jun 2017 13:35:28 -0700 (PDT)
Message-Id: <6767292582c8b21efa30eaa67d9c81ec507e4ada@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu, =?UTF-8?B?RWR1YXJkb19BLl9CdXN0YW1hbnRlX0zDs3Bleg==?=
	<dualbus@gmail.com>, bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.1
X-Originating-IP: 50.78.252.161
in-reply-to: <bd84a574-4dcf-659c-9836-05939164a123@case.edu>
Subject: Re: Fwd: Non-upstream patches for bash (2014)
Date: Mon, 26 Jun 2017 16:35:28 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 20:35:38 -0000

=0AThat's not a reason why this disparity is "desirable" IMO.=0A=0AGener=
ally, the rule is that the shell interprets the shell script it's=0Agive=
n according to the character set of the active locale. It may not=0Aallo=
w any given sequence of characters in any given context, but in=0Aterms=
 of how the parser translates the sequence of input bytes into=0Ainput c=
haracters, it's always in terms of that input locale. Why would=0Athis b=
e true for virtually every facet of the language except for one=0Apartic=
ular quoting syntax? The character set of a script is its most=0Afundame=
ntal layer of abstraction, and the shell is generally expected=0Ato resp=
ect that abstraction. The idea that 0x5C in this context is=0Astill a "b=
ackslash" is a fiction created by mis-interpreting the=0Ascript.=0A=0AI'=
d argue that having this kind of inconsistency in the parser is=0Aundesi=
rable, and retaining it only causes harm. If other shells also=0Aimpleme=
nt it this way, then those other shells are also broken, and=0AI'll subm=
it this as a bug to their projects, too. :)=0A=0A----- Original Message=
 -----=0AFrom: chet.ramey@case.edu=0ATo:<tetsujin@scope-eye.net>, "Eduar=
do_A._Bustamante_L=C3=B3pez"=0A<dualbus@gmail.com>, <bug-bash@gnu.org>=
=0ACc:<chet.ramey@case.edu>=0ASent:Mon, 26 Jun 2017 14:34:32 -0400=0ASub=
ject:Re: Fwd: Non-upstream patches for bash (2014)=0A=0A On 6/26/17 12:4=
6 PM, tetsujin@scope-eye.net wrote:=0A > =0A > It seems a strange incons=
istency, though: Double-quoted strings=0A(and,=0A > really, pretty much=
 all other Bash syntax as far as I have seen)=0Arecognize=0A > 0x81 0x5C=
 as a two-byte character rather than treating 0x5C as a=0Abackslash=0A >=
 within the quoting syntax, but $'..' strings unconditionally treat=0A0x=
5C as=0A > a backslash... Is there any reason a disparity like that woul=
d be=0Adesirable?=0A=0A Because that's how C works, and that's how all t=
he shells that=0Acurrently=0A implement it work (and have always worked)=
.=0A=0A Posix has considered this feature on and off (2010, 2015, 2016)[=
1],=0Aalbeit=0A with a lot of tangents. If it ever gets standardized, I=
 expect this=0A question to be resolved. When it does, and if it's requi=
red, I'll=0Achange=0A Posix mode to match and then we'll see.=0A=0A [1]=
 http://austingroupbugs.net/view.php?id=3D249=0A=0A Chet=0A=0A -- =0A ``=
The lyf so short, the craft so long to lerne.'' - Chaucer=0A ``Ars longa=
, vita brevis'' - Hippocrates=0A Chet Ramey, UTech, CWRU chet@case.edu=
=0Ahttp://cnswww.cns.cwru.edu/~chet/=0A=0A

From MAILER-DAEMON Mon Jun 26 19:48:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dPdk0-0005wH-6E
	for mharc-bug-bash@gnu.org; Mon, 26 Jun 2017 19:48:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:47607)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPdjy-0005wA-0D
	for bug-bash@gnu.org; Mon, 26 Jun 2017 19:48:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dPdju-0002vz-2K
	for bug-bash@gnu.org; Mon, 26 Jun 2017 19:48:22 -0400
Received: from mpv1-2015.cwru.edu ([129.22.103.226]:60313
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dPdjt-0002vl-Si
	for bug-bash@gnu.org; Mon, 26 Jun 2017 19:48:17 -0400
Received: from mpv7-2015.CWRU.Edu (EHLO mpv7-2015.case.edu) ([129.22.103.242])
	by mpv1-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANO12564; Mon, 26 Jun 2017 19:48:13 -0400 (EDT)
Received: from h99.71.130.174.dynamic.ip.windstream.net (EHLO _192.168.254.9_)
	([174.130.71.99])
	by mpv7-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id HTK49091 (AUTH cpr);
	Mon, 26 Jun 2017 19:48:13 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu
Subject: Re: Fwd: Non-upstream patches for bash (2014)
To: tetsujin@scope-eye.net,
	"=?UTF-8?Q?Eduardo=5fA.=5fBustamante=5fL=c3=b3pez?=" <dualbus@gmail.com>,
	bug-bash@gnu.org
References: <6767292582c8b21efa30eaa67d9c81ec507e4ada@webmail.scope-eye.net>
From: Chet Ramey <chet.ramey@case.edu>
Organization: ITS, Case Western Reserve University
Message-ID: <0c893c93-60aa-9b51-e876-0ba16693b583@case.edu>
Date: Mon, 26 Jun 2017 19:48:12 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.1.1
MIME-Version: 1.0
In-Reply-To: <6767292582c8b21efa30eaa67d9c81ec507e4ada@webmail.scope-eye.net>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=7/60, host=mpv1-2015.case.edu
X-Junkmail-PrAS-Raw: score=7/60, refid=2.7.2:2017.6.26.230316:17:7.944, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__TO_MALFORMED_2, __TO_NO_NAME, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC1, __FROM_DOMAIN_IN_ANY_CC2,
	__REPLYTO_SAMEAS_FROM_DOMAIN, __ANY_URI, __URI_WITH_PATH,
	__URI_NO_WWW, __CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE,
	__URI_IN_BODY, __URI_NOT_IMG, __NO_HTML_TAG_RAW,
	BODYTEXTP_SIZE_3000_LESS, BODY_SIZE_400_499,
	__MIME_TEXT_P1, __MIME_TEXT_ONLY, __URI_NS, HTML_00_01,
	HTML_00_10, BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.226
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Mon, 26 Jun 2017 23:48:22 -0000

On 6/26/17 4:35 PM, tetsujin@scope-eye.net wrote:
> 
> That's not a reason why this disparity is "desirable" IMO.

It's not intended to be anything but an explanation of why things are
the way they are: compatibility and backwards compatibility.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 29 09:52:56 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQZsO-0002nZ-6F
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 09:52:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52410)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQOrp-0005b5-Sq
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:07:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQOro-0004WH-LE
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:07:37 -0400
Received: from mail-qk0-x22b.google.com ([2607:f8b0:400d:c09::22b]:35869)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <keithsthompson@gmail.com>)
	id 1dQOro-0004Vu-GY
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:07:36 -0400
Received: by mail-qk0-x22b.google.com with SMTP id p21so65808152qke.3
	for <bug-bash@gnu.org>; Wed, 28 Jun 2017 19:07:35 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:sender:from:date:message-id:subject:to:cc;
	bh=9AwRIxRjK1A/PwMhVKDkm4m+U4a/nUPKkxai85xdT4Q=;
	b=d7J6SRh2ruOwdNq+8ok6FnRi+RbrgSGF+jD9oGoP2YlRgGnWBJ/rQCsfalDZilKTcp
	qeA/SfalQmREyEuD2AXGG5VGDYtXjjhBqtPdF5vhbtLYBkiMnyhsfmgEohlUPw2BPS8Z
	p+H4aJBV/rrvT60W5gVlmVKbFQPoCMGNMj4q/3m6hKRGCE6fdWjM0oeT9/+1UV0oGgQK
	SHJgcuHuTwlKnBpm7+RMxw/GtzN6znf/M/7g0OEeXvjilLEjSdxlmRRnuedNyAKfmiUC
	K9LsSnjFsH98Xe5zuExUFrbFphOp3BLoW02ARWai1HybsR5A0V/jwYTLBu8LkZk39xbt
	M7dw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:sender:from:date:message-id:subject
	:to:cc;
	bh=9AwRIxRjK1A/PwMhVKDkm4m+U4a/nUPKkxai85xdT4Q=;
	b=p6A3b/pZKKvmHw3RbmGa5pMSC0N67ytyLno6qVoDNW5D4JFdLvKScgEqYiHVmWT7hO
	hqEleBLMiOKDfPxBVCCWeQA/3wHvDVe0a6y+uRgoNAomhmc5TmaBW7PYhIoRaxXlUqsm
	US4be27wSMK2yWyZErtSInF8N0lrUVEvXllmkZ0lNSjYvrBzKO8D3Y/yDFVwIc9Z2N0T
	f7KKnhc4onK2Owzh1CZH7IF5AP3MOu/zTA+8heVAwMu7Tc2IoZC2NPBWGIfh3gsza7qu
	cuw2XDhco0mn+dlNPsraOjmsWzV2SiMX3W+TdU4PV0y0se6sw4JZEApaWQXagdcW5Ke7
	MHaw==
X-Gm-Message-State: AKS2vOyqcjfjDbsE1uPgAt/W9SMPuYwZFP0Jrf3vXi3mCehRd0C52YzI
	V7bOuLdv66z4Av8vfwjDIfoRj6oqSiBYhOE=
X-Received: by 10.55.220.133 with SMTP id v127mr16750660qki.42.1498702054290; 
	Wed, 28 Jun 2017 19:07:34 -0700 (PDT)
MIME-Version: 1.0
Sender: keithsthompson@gmail.com
Received: by 10.55.94.194 with HTTP; Wed, 28 Jun 2017 19:07:33 -0700 (PDT)
From: Keith Thompson <Keith.S.Thompson@gmail.com>
Date: Wed, 28 Jun 2017 19:07:33 -0700
X-Google-Sender-Auth: ogY-SKMZL0mdLqNXIWy8Ptzvojw
Message-ID: <CAAHpriOhWJUpbZ_cnaStrkBV0-pod7=JCwfoscu+8HVtggj6Rw@mail.gmail.com>
Subject: Typo in bash manual: "QUANTUMP"
To: bug-bash@gnu.org
Cc: Keith Thompson <Keith.S.Thompson@gmail.com>
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c09::22b
X-Mailman-Approved-At: Thu, 29 Jun 2017 09:52:54 -0400
Content-Type: text/plain; charset="UTF-8"
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 02:07:38 -0000

In the documentation for the "mapfile" builtin command:

     '-C'
          Evaluate CALLBACK each time QUANTUMP lines are read.  The '-c'
          option specifies QUANTUM.

"QUANTUMP" should be "QUANTUM".

In the latest sources cloned from git://git.savannah.gnu.org/bash.git, this
occurs in:

bash/doc/bash.info
bash/doc/bashref.info

From MAILER-DAEMON Thu Jun 29 09:52:57 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQZsO-0002oH-TZ
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 09:52:56 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:52491)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQOsf-0005j5-65
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:08:30 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQOse-0004hZ-AI
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:08:29 -0400
Received: from mail-qt0-x22b.google.com ([2607:f8b0:400d:c0d::22b]:35858)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <keithsthompson@gmail.com>)
	id 1dQOse-0004hT-64
	for bug-bash@gnu.org; Wed, 28 Jun 2017 22:08:28 -0400
Received: by mail-qt0-x22b.google.com with SMTP id i2so64104283qta.3
	for <bug-bash@gnu.org>; Wed, 28 Jun 2017 19:08:28 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:sender:from:date:message-id:subject:to:cc;
	bh=uNEz6a+u5M9J2hEujDW5TqVUxU5pa74y3mTqYrVJp+o=;
	b=E9GxeHTVzfX1Wj5Wh6KMJIPvtDNxIWIknf8kXkoreczbfd0/f2azSxo3jEbhoUOGBK
	oP1Vi+EWtHixLiz8PeGxeMQzO/BpHX7WTmuls+K5JG1wG/+0xHPfyd4LjUXjrR4iZJob
	28pKe6EMMs2nRfVuMNZZcNWo1vzuqthYkLrNcuSuUzHI7KceHNjkxDjF0Fohjgrk9X10
	u9bx4LAof8ekwUxgRSHqVzOefwJvAiw76aTD3dZQv6TKNsrUi6tToLCRUgDOTjBq2esA
	5a/hwc1mbR7JxqaEcFVm3ksPC9vphNCCU/0dP67ofQkc2vEcZtlCIzDmCkRBSApQ02f+
	uV3A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:sender:from:date:message-id:subject
	:to:cc;
	bh=uNEz6a+u5M9J2hEujDW5TqVUxU5pa74y3mTqYrVJp+o=;
	b=XLAW1eIC9oHgX3CfWKiHi3C075F0p/LTrvqQwwf8O9rphk51fgeelchPlZBM6n4rr6
	zlpWxg5Dhk1D97wLhsaSBxvaqgJVt7Jbc3ubq6QJd9a1T5+i4l81i4aiRqd59rwIIctM
	gE6Kme/sOOAKVg4W5OnF0O1XdI7y3Q6nGb4gaoYwBkODnPJ+aLc44SwZHlRxkE6E8T3j
	MEa3LwER6OfroBDQNIzYx7m08ymoK8DVwWmPxre21bRQAhUVgVJiex3PUHNP5JrZlv1i
	dede2BtAsTjTqMuJNcEMu5pdty9f8wFtXytHlofwaBrW0F50GmrabXgUCJGARbUt9qkw
	gbdQ==
X-Gm-Message-State: AKS2vOwvx4KOLSbChNGjLvl6zxT844ikjaQ5CwFc8x9DWfnLnsxNyEHg
	DXNy3FOzY4h5weZUZTspdk2pqclj9x8XoaM=
X-Received: by 10.200.13.4 with SMTP id q4mr12335089qti.221.1498702107459;
	Wed, 28 Jun 2017 19:08:27 -0700 (PDT)
MIME-Version: 1.0
Sender: keithsthompson@gmail.com
Received: by 10.55.94.194 with HTTP; Wed, 28 Jun 2017 19:08:27 -0700 (PDT)
From: Keith Thompson <Keith.S.Thompson@gmail.com>
Date: Wed, 28 Jun 2017 19:08:27 -0700
X-Google-Sender-Auth: UH9lBkAdYdQYdlhiAT3x_rTc4ug
Message-ID: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
Subject: mapfile doesn't accept input from a pipe
To: bug-bash@gnu.org
Cc: Keith Thompson <Keith.S.Thompson@gmail.com>
Content-Type: text/plain; charset="UTF-8"
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::22b
X-Mailman-Approved-At: Thu, 29 Jun 2017 09:52:54 -0400
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 02:08:30 -0000

Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -g -O2 -Wno-parentheses -Wno-format-security
uname output: Linux bomb20 4.8.0-46-generic #49-Ubuntu SMP Fri Mar 31
13:57:14 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Machine Type: x86_64-unknown-linux-gnu

Bash Version: 4.4
Patch Level: 12
Release Status: maint

Description:
        The "mapfile" command works correctly if stdin is redirected
from a file, but not if it's from a pipe.
        Demonstrated with several versions including the latest
bash-snap-20170626

Repeat-By:
        This script demonstrates the problem:
        __CUT_HERE__
        #!/bin/bash

        printf 'one\ntwo\nthree\n' > /tmp/input.txt

        mapfile REDIRECT < /tmp/input.txt
        cat /tmp/input.txt | mapfile PIPE

        echo "\$REDIRECT has ${#REDIRECT[@]} elements"
        echo "\$PIPE     has ${#PIPE[@]} elements"

        if [ ${#REDIRECT[@]} -eq 3 ] && [ ${#PIPE[@]} -eq 3 ] ; then
            echo PASS
            exit 0
        else
            echo FAIL
            exit 1
        fi
        __AND_HERE__


From MAILER-DAEMON Thu Jun 29 09:56:11 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQZvX-0006El-D7
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:11 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59128)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQZvV-0006Cl-9R
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:10 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQZvR-0000h8-Da
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:09 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:50652 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQZvR-0000Rz-4p
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:05 -0400
Received: (qmail 10506 invoked from network); 29 Jun 2017 13:55:33 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 29 Jun 2017 09:55:33 -0400
Received: (qmail 16368 invoked by uid 563); 29 Jun 2017 13:55:33 -0000
Date: Thu, 29 Jun 2017 09:55:33 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: Keith Thompson <Keith.S.Thompson@gmail.com>
Cc: bug-bash@gnu.org
Subject: Re: mapfile doesn't accept input from a pipe
Message-ID: <20170629135532.GX4028@eeg.ccf.org>
References: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
User-Agent: Mutt/1.8.3 (2017-05-23)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 13:56:10 -0000

On Wed, Jun 28, 2017 at 07:08:27PM -0700, Keith Thompson wrote:
> Description:
>         The "mapfile" command works correctly if stdin is redirected
> from a file, but not if it's from a pipe.

This is because each command in a pipeline is executed in its own subshell.
Not a bug.

If you need to read input from a command with mapfile (or read), use a
process substitution.

>         cat /tmp/input.txt | mapfile PIPE

mapfile PIPE < /tmp/input.txt
mapfile PIPE < <(a real program, not cat)


From MAILER-DAEMON Thu Jun 29 09:56:45 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQZw5-0006jJ-6A
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:59473)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dQZw2-0006gU-3a
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:42 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <dualbus@gmail.com>) id 1dQZvy-0000vB-7o
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:42 -0400
Received: from mail-oi0-x22c.google.com ([2607:f8b0:4003:c06::22c]:32951)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <dualbus@gmail.com>) id 1dQZvy-0000uB-3d
	for bug-bash@gnu.org; Thu, 29 Jun 2017 09:56:38 -0400
Received: by mail-oi0-x22c.google.com with SMTP id p188so11083822oia.0
	for <bug-bash@gnu.org>; Thu, 29 Jun 2017 06:56:36 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=date:from:to:cc:subject:message-id:references:mime-version
	:content-disposition:in-reply-to:user-agent;
	bh=dVUBb5dSTjGr/VHaOZqF9AR4EzXgzy2dghpn+WwObPo=;
	b=fVKdHjGy5j5ES0dT+oz1/SZxmtELffC1ySAbAoCVPq2e1q6VGFwiJUMlVGemMmNAOa
	QKjsjqYBVGHgYu84/+SWTVTGIul627n7xMJuNBSdZCzqFyy3ii/duSf/PhBHJcRdfoFg
	RXMd6njFrCazyzJe06A2/Ado6J9W7WlN/5apbWaqojzon+QeE7qpENhBqK9FdG+xLs8e
	0vYecCQd1MRC+8XmH32VqzKW30SgA7JviiT1RRmo4iRz/Wh4u5vLKxE0M7m65daprv2k
	Q+tx9Jhbdofl8C025KcRS51AXKYj9fadGHPVrngqIPrPCdXtUbc+IoOldVtXp0a3w2wi
	bq5A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:date:from:to:cc:subject:message-id:references
	:mime-version:content-disposition:in-reply-to:user-agent;
	bh=dVUBb5dSTjGr/VHaOZqF9AR4EzXgzy2dghpn+WwObPo=;
	b=Ljo9tnNf7Dn+SPbgHuhVbM+0zE6WSq7Vpmbz+gerYND0+nw+I2QWBLNBMLvH+OzQ11
	n83XiKaUoih/6+hCrypiIfO+/kBqoqVTYLKWQI+Qs3bBADzljFHt45b6pgKApk+8YNl/
	db/2HmaL6xSlTcoXkUuKZ+VqYzBFq5s/C2196Uh2HbxGwvV5d4x8M3dWHSHk48j3s/N4
	Rv95dPEdI1W1wL9XKbrp3DPVyvR7Jhwgkv5EHZl7251l4XXob+HnUgFXH9ERjTROoHxN
	/J4Y+/TufLzB1Df6HC+wh5/uLQliWsSPXJ4aSsMx50xu0ykDQdkkb6aq6/L5X1jjQtdB
	hXTQ==
X-Gm-Message-State: AKS2vOzxoYYUjT0stBwodoYx052k2vl71ljAR+NDcCvvN8Q8rvgafr0g
	lfJ0iP9KAZloqDZK
X-Received: by 10.202.117.151 with SMTP id q145mr9936902oic.140.1498744595946; 
	Thu, 29 Jun 2017 06:56:35 -0700 (PDT)
Received: from localhost ([201.157.174.156]) by smtp.gmail.com with ESMTPSA id
	s127sm5962785oif.34.2017.06.29.06.56.35
	(version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
	Thu, 29 Jun 2017 06:56:35 -0700 (PDT)
Date: Thu, 29 Jun 2017 08:56:33 -0500
From: Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
To: Keith Thompson <Keith.S.Thompson@gmail.com>
Cc: bug-bash@gnu.org
Subject: Re: mapfile doesn't accept input from a pipe
Message-ID: <20170629135633.vkk54w5ckpfxbngp@debian>
References: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
In-Reply-To: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
User-Agent: NeoMutt/20170113 (1.7.2)
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:4003:c06::22c
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 13:56:43 -0000

On Wed, Jun 28, 2017 at 07:08:27PM -0700, Keith Thompson wrote:
[...]
>         mapfile REDIRECT < /tmp/input.txt
>         cat /tmp/input.txt | mapfile PIPE

The `mapfile PIPE' is a piece of a pipeline, and as such, it runs in a
subshell (different process).

See: http://mywiki.wooledge.org/BashFAQ/024

-- 
Eduardo Bustamante
https://dualbus.me/


From MAILER-DAEMON Thu Jun 29 12:38:24 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQcSW-0003zd-EH
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 12:38:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:39041)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQcST-0003xd-VT
	for bug-bash@gnu.org; Thu, 29 Jun 2017 12:38:22 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <keithsthompson@gmail.com>) id 1dQcSS-00067z-Sh
	for bug-bash@gnu.org; Thu, 29 Jun 2017 12:38:22 -0400
Received: from mail-qt0-x22a.google.com ([2607:f8b0:400d:c0d::22a]:36857)
	by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <keithsthompson@gmail.com>)
	id 1dQcSS-00067i-P9
	for bug-bash@gnu.org; Thu, 29 Jun 2017 12:38:20 -0400
Received: by mail-qt0-x22a.google.com with SMTP id i2so79007411qta.3
	for <bug-bash@gnu.org>; Thu, 29 Jun 2017 09:38:20 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=mime-version:sender:in-reply-to:references:from:date:message-id
	:subject:to:cc:content-transfer-encoding;
	bh=iaKCcRuFPgZlDmAtw+EwkQEj9ytodma3ZY9xojV+V8A=;
	b=sL79YLtjRFqGULl5c7g4wNhSk4nsED2gqSolXdEpRXZ3ZB3DqMF7IpZOhaIa51ZWkz
	xcIgKATToAFRUnWpLo+axhaqQa1KbK3G1N8nbS+4Nq+8el7BI1IIP5wCNUfwVDJbwgPJ
	GgT7n2B510V0/w9SFrzmjmfEsRqRtgwFr+pFL7iwOXxDIS94by6d2MgfHI8os1YK/NSb
	/3BohL29sjAvm9dyDiJbTt9lgm4kgIM5JcQcKArcEa5umgalCfv0qIp0gtl5+co8J/A1
	vEznXdKQTzAG8Gs/Cdqscs7W97OuEkG9Mlyz6zQJ1ycsSCXkQ8mYWXpT4qxZ9iHYECoG
	hJKA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:mime-version:sender:in-reply-to:references:from
	:date:message-id:subject:to:cc:content-transfer-encoding;
	bh=iaKCcRuFPgZlDmAtw+EwkQEj9ytodma3ZY9xojV+V8A=;
	b=hXLA1McBFSAasTu46jFcSkdzMZDgJNU8Zh8AV2X1bcesSuXVYXwahANIgWz6osIdf7
	GKwe4JtrbEfvpGY/hl8JhvwsVgg0HQj8Kqdpt+F0H1al+qXsfx5Ih9NQh2gXqZCb4E89
	+YPejx3ZZRRI4blELB28kkaj+cInGyjuvjZky5YTxsa2qVienUvUOAM1vpjGyKAtaiQR
	YPqJXWgBEZqhj4M086mXsSYkoBsYRqPKrHcFrQE/PVcnkt4B9fv5jIcLhKCx/Q7ku09F
	zCGGCks+jxKtD7wSdWf1sXVux0dce68zYOojd5vlkZDzh2d7lE7s6wuFg3OgTd00S4eZ
	/NPg==
X-Gm-Message-State: AKS2vOwFY+CrTf+YpVZ11kfrzgqSYB4ZdJqyln2p2euuP65GZMeAI1rn
	YVkUoHs0ctJW38A9s6zKbwe4O7hwxQ==
X-Received: by 10.237.63.119 with SMTP id q52mr20401616qtf.49.1498754300218;
	Thu, 29 Jun 2017 09:38:20 -0700 (PDT)
MIME-Version: 1.0
Sender: keithsthompson@gmail.com
Received: by 10.55.94.194 with HTTP; Thu, 29 Jun 2017 09:38:19 -0700 (PDT)
In-Reply-To: <20170629135633.vkk54w5ckpfxbngp@debian>
References: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
	<20170629135633.vkk54w5ckpfxbngp@debian>
From: Keith Thompson <Keith.S.Thompson@gmail.com>
Date: Thu, 29 Jun 2017 09:38:19 -0700
X-Google-Sender-Auth: hvGyvRudgtU1onGiuUnBYbU_OwY
Message-ID: <CAAHpriMpZFzi+SNdrXASvbfkeqq0raHL0eixOAqRNe+aZsmXCA@mail.gmail.com>
Subject: Re: mapfile doesn't accept input from a pipe
To: =?UTF-8?Q?Eduardo_A=2E_Bustamante_L=C3=B3pez?= <dualbus@gmail.com>
Cc: bug-bash@gnu.org
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
	recognized.
X-Received-From: 2607:f8b0:400d:c0d::22a
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 16:38:23 -0000

On Thu, Jun 29, 2017 at 6:56 AM, Eduardo A. Bustamante L=C3=B3pez
<dualbus@gmail.com> wrote:
> On Wed, Jun 28, 2017 at 07:08:27PM -0700, Keith Thompson wrote:
> [...]
>>         mapfile REDIRECT < /tmp/input.txt
>>         cat /tmp/input.txt | mapfile PIPE
>
> The `mapfile PIPE' is a piece of a pipeline, and as such, it runs in a
> subshell (different process).
>
> See: http://mywiki.wooledge.org/BashFAQ/024

OK, that makes sense, and of course the same thing applies to "read".

I suggest that it would be worthwhile to mention this issue in the
documentation.
The fact that it's a FAQ suggests that people are likely to run into it.


From MAILER-DAEMON Thu Jun 29 14:07:41 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQdqv-0006Iv-Kc
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 14:07:41 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:36373)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dQdqt-0006I4-IY
	for bug-bash@gnu.org; Thu, 29 Jun 2017 14:07:40 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <chet.ramey@case.edu>) id 1dQdqq-0004N8-Fl
	for bug-bash@gnu.org; Thu, 29 Jun 2017 14:07:39 -0400
Received: from mpv2-2015.cwru.edu ([129.22.103.227]:61049
	helo=mpv1-2015.case.edu)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16)
	(Exim 4.71) (envelope-from <chet.ramey@case.edu>) id 1dQdqq-0004MO-A3
	for bug-bash@gnu.org; Thu, 29 Jun 2017 14:07:36 -0400
Received: from mpv5-2015.CWRU.Edu (EHLO mpv5-2015.case.edu) ([129.22.103.234])
	by mpv2-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id ANU43126; Thu, 29 Jun 2017 14:07:33 -0400 (EDT)
Received: from caleb.INS.CWRU.Edu (EHLO caleb.ins.cwru.edu) ([129.22.8.211])
	by mpv5-2015.case.edu (MOS 4.4.7-GA FastPath queued)
	with ESMTP id BGO68371 (AUTH cpr);
	Thu, 29 Jun 2017 14:07:33 -0400 (EDT)
Reply-To: chet.ramey@case.edu
Cc: chet.ramey@case.edu, bug-bash@gnu.org
Subject: Re: mapfile doesn't accept input from a pipe
To: Keith Thompson <Keith.S.Thompson@gmail.com>,
	"=?UTF-8?Q?Eduardo_A._Bustamante_L=c3=b3pez?=" <dualbus@gmail.com>
References: <CAAHpriOd29GqOJLA+6Q33neKSAzbCTLfVZXgk-jBnjFu15wo_A@mail.gmail.com>
	<20170629135633.vkk54w5ckpfxbngp@debian>
	<CAAHpriMpZFzi+SNdrXASvbfkeqq0raHL0eixOAqRNe+aZsmXCA@mail.gmail.com>
From: Chet Ramey <chet.ramey@case.edu>
Message-ID: <d4df9e8e-bc30-619c-d1d2-8355b409a684@case.edu>
Date: Thu, 29 Jun 2017 14:07:32 -0400
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0)
	Gecko/20100101 Thunderbird/52.2.0
MIME-Version: 1.0
In-Reply-To: <CAAHpriMpZFzi+SNdrXASvbfkeqq0raHL0eixOAqRNe+aZsmXCA@mail.gmail.com>
Content-Type: text/plain; charset=utf-8
Content-Language: en-US
Content-Transfer-Encoding: 7bit
X-Junkmail-Status: score=8/60, host=mpv2-2015.case.edu
X-Junkmail-PrAS-Raw: score=8/60, refid=2.7.2:2017.6.29.171217:17:8.317, ip=,
	rules=__HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2,
	__BOUNCE_CHALLENGE_SUBJ, __BOUNCE_NDR_SUBJ_EXEMPT,
	__SUBJ_ALPHA_END, __TO_MALFORMED_2, __TO_NAME,
	__TO_NAME_DIFF_FROM_ACC, __REFERENCES, __HAS_FROM,
	FROM_EDU_TLD, __HAS_MSGID, __SANE_MSGID, DATE_TZ_NA,
	__USER_AGENT, __MOZILLA_USER_AGENT, __MIME_VERSION,
	__IN_REP_TO, __CT, __CT_TEXT_PLAIN, __CTE,
	__REPLYTO_SAMEAS_FROM_ADDY, __REPLYTO_SAMEAS_FROM_ACC,
	__FROM_DOMAIN_IN_ANY_CC2, __REPLYTO_SAMEAS_FROM_DOMAIN,
	__ANY_URI, __URI_WITH_PATH, __URI_NO_WWW,
	__CP_URI_IN_BODY, __SUBJ_ALPHA_NEGATE, __URI_IN_BODY,
	__URI_NOT_IMG, __NO_HTML_TAG_RAW, BODY_SIZE_700_799,
	BODYTEXTP_SIZE_3000_LESS, __MIME_TEXT_P1,
	__MIME_TEXT_ONLY, __URI_NS, HTML_00_01, HTML_00_10,
	BODY_SIZE_5000_LESS, IN_REP_TO, MSG_THREAD,
	__FROM_DOMAIN_IN_RCPT, __TO_REAL_NAMES,
	MULTIPLE_REAL_RCPTS, LEGITIMATE_SIGNS, __SINGLE_URI_TEXT,
	[TRUNCATED], so=2010-03-03 19:42:08, dmn=2016-08-03-0138
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
	[fuzzy]
X-Received-From: 129.22.103.227
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 18:07:40 -0000

On 6/29/17 12:38 PM, Keith Thompson wrote:

> I suggest that it would be worthwhile to mention this issue in the
> documentation.

"Each  command in a pipeline is executed as a separate process (i.e., in
a subshell).  See COMMAND EXECUTION ENVIRONMENT for a description of  a
subshell  environment.   If  the  lastpipe  option is enabled using the
shopt builtin (see the description of shopt below), the last element of
a pipeline may be run by the shell process."

or maybe

"Builtin commands that are invoked as part of a pipeline are also
executed in a subshell environment."

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://cnswww.cns.cwru.edu/~chet/


From MAILER-DAEMON Thu Jun 29 15:22:39 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQf1T-0002ai-Ik
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 15:22:39 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53690)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dQf1Q-0002aY-Hl
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:22:38 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dQf1L-00061d-Ij
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:22:36 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:38637
	helo=homiemail-a80.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dQf1L-0005zC-5s
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:22:31 -0400
Received: from homiemail-a80.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a80.g.dreamhost.com (Postfix) with ESMTP id E288A6003D2E; 
	Thu, 29 Jun 2017 12:22:24 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:cc:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=G1hQSe32eQYDoya8QFbK0BLnOIs=; b=
	UqkYdPSYlt2AGFAqQL6UV+wpyEyJxTwkJ4nZMumq7y3zRJfpFM7lfDAYJmFgHu26
	uzkcwtXnxPPiBUVfme23JHLolCzEoyitJG/p5qZARJsM8BYxZZj2ufnSwEOvRabF
	kVEl9tZ+t81R9qCO5x/udIAMatWkg6qPprL/0kfZUNM=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a80.g.dreamhost.com (Postfix) with ESMTPSA id D2DD26003D2B;
	Thu, 29 Jun 2017 12:22:24 -0700 (PDT)
Message-Id: <d284662d2c7e62bf76d24a993a3415537b538155@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: chet.ramey@case.edu, "Keith Thompson" <Keith.S.Thompson@gmail.com>,
	=?UTF-8?B?RWR1YXJkb19BLl9CdXN0YW1hbnRlX0zDs3Bleg==?= <dualbus@gmail.com>
Cc: bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.2
X-Originating-IP: 50.78.252.161
in-reply-to: <d4df9e8e-bc30-619c-d1d2-8355b409a684@case.edu>
Subject: Re: mapfile doesn't accept input from a pipe
Date: Thu, 29 Jun 2017 15:22:24 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 19:22:38 -0000

=0AI think that when programmers first learn shell programming, this is=
 a=0Ahard piece of information to effectively convey. The Bash=0Adocumen=
tation provides the important facts:=0A=0A- Subshells are quietly and au=
tomatically constructed for a variety of=0Ashell programming constructs,=
 including pipelines=0A- Code run in a subshell can't affect the parent=
 shell's execution=0Aenvironment=0A=0ABut what's important for a new she=
ll programmer, and so easy to miss,=0Ais the implication that comes from=
 these facts: piping a command's=0Aoutput into "read" seems like a perfe=
ctly reasonable thing to do if=0Ayou haven't wrapped your head around th=
ose two facts and their=0Aimplications. And if you do try "cmd | read x"=
, it's not considered to=0Abe any kind of error or anything, the side-ef=
fects of "read" are just=0Acarried out and then quietly discarded.=0A=0A=
So I look at this not just as a RTFM issue, it's a pitfall built-in to=
=0Athe design of the language, and programmers need to understand a bit=
=0Aabout the implementation of the language to understand what's going=
=0Aon. As such I think it may be worth spelling it out a bit more=0Adire=
ctly in terms of the implications here. For instance, stick it in=0Athe=
 help for 'read' and 'mapfile':=0A=0A"Care must be taken when using 'rea=
d' in a pipeline or another form of=0Asubshell environment, as this may=
 cause the data that's read to be=0Alost. See BASH SCRIPTING BASICS (sec=
tion whatever) for more=0Ainformation."=0A=0AIt's the same basic informa=
tion, but it's better targeted: It lives in=0Athe help for the command t=
hat's apparently "failing", it says your=0Adata may be "lost", and it po=
ints at a relevant section of a newbie=0AFAQ that explains why.=0A=0AI'd=
 also wonder if it's maybe worth trying to detect cases of this=0Akind o=
f thing and flagging them as errors...=C2=A0 Like if "read" or=0A"mapfil=
e" wind up as the only command in a subshell, the command's=0Aside-effec=
ts are going to be lost, so it's an error. Of course that=0Adoes nothing=
 for the wide variety of other cases impacted by this=0Aissue, but maybe=
 it's still worth it...=C2=A0 If someone does "cmd | read=0Ax", and "las=
tpipe" isn't on AND in effect, it's almost certainly a=0Amistake...=C2=
=A0 (Of course, there's ALWAYS the possibility that someone=0Arelies on=
 the current behavior - for instance to see if "read" would=0Asucceed, o=
r trigger a SIGPIPE in "cmd" after a certain amount of data=0Ais read...=
)=0A=0AThe whole issue of sub-shells is kind of a mess IMO - there's all=
=0Athese cases where one gets created automatically, and the (cmd) synta=
x=0Awhich exists specifically to run a command in a subshell, looks to t=
he=0Auninitiated like a simple command-grouping syntax, because that's h=
ow=0Aparentheses work in C and many other languages...=C2=A0 And if some=
thing=0Awinds up in a subshell that shouldn't be, its side-effects on th=
e=0Ashell environment are simply lost without warning. Ideally, forking=
=0Athe shell shouldn't be so baked-in to the language that people wind u=
p=0Atripping over it.=C2=A0 Instead these cases that require parallelism=
=0Ashould use threading and synchronized access to a shared environment.=
=0A(So a pipeline could contain *multiple* built-ins or shell functions=
=0Awith side-effects for the shell's environment) But I think that's a=
=0Adifficult direction to pursue, unfortunately, and I'm guessing it's=
=0Anot one that will happen in Bash...=C2=A0 (On the bright side it soun=
ds as=0Athough POSIX allows it...)=0A----- Original Message -----=0AFrom=
: chet.ramey@case.edu=0ATo:"Keith Thompson" <Keith.S.Thompson@gmail.com>=
,=0A"Eduardo_A._Bustamante_L=C3=B3pez" <dualbus@gmail.com>=0ACc:<bug-bas=
h@gnu.org>, <chet.ramey@case.edu>=0ASent:Thu, 29 Jun 2017 14:07:32 -0400=
=0ASubject:Re: mapfile doesn't accept input from a pipe=0A=0A On 6/29/17=
 12:38 PM, Keith Thompson wrote:=0A=0A > I suggest that it would be wort=
hwhile to mention this issue in the=0A > documentation.=0A=0A "Each comm=
and in a pipeline is executed as a separate process (i.e.,=0Ain=0A a sub=
shell). See COMMAND EXECUTION ENVIRONMENT for a description of a=0A subs=
hell environment. If the lastpipe option is enabled using the=0A shopt b=
uiltin (see the description of shopt below), the last element=0Aof=0A a=
 pipeline may be run by the shell process."=0A=0A or maybe=0A=0A "Builti=
n commands that are invoked as part of a pipeline are also=0A executed i=
n a subshell environment."=0A=0A -- =0A ``The lyf so short, the craft so=
 long to lerne.'' - Chaucer=0A ``Ars longa, vita brevis'' - Hippocrates=
=0A Chet Ramey, UTech, CWRU chet@case.edu=0Ahttp://cnswww.cns.cwru.edu/~=
chet/=0A=0A

From MAILER-DAEMON Thu Jun 29 15:39:29 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQfHl-0003WH-Ji
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 15:39:29 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:57552)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQfHi-0003VC-Vz
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:39:27 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQfHe-0004p5-WB
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:39:27 -0400
Received: from ccfadm.eeg.ccf.org ([139.137.100.1]:50769 helo=svr4.eeg.ccf.org)
	by eggs.gnu.org with smtp (Exim 4.71)
	(envelope-from <wooledg@eeg.ccf.org>) id 1dQfHe-0004on-Nw
	for bug-bash@gnu.org; Thu, 29 Jun 2017 15:39:22 -0400
Received: (qmail 12813 invoked from network); 29 Jun 2017 19:39:20 -0000
Received: from imadev.eeg.ccf.org (qmailr@10.76.173.78)
	by gateway.eeg.ccf.org with SMTP; Thu, 29 Jun 2017 15:39:20 -0400
Received: (qmail 17168 invoked by uid 563); 29 Jun 2017 19:39:20 -0000
Date: Thu, 29 Jun 2017 15:39:20 -0400
From: Greg Wooledge <wooledg@eeg.ccf.org>
To: bug-bash@gnu.org
Subject: Re: mapfile doesn't accept input from a pipe
Message-ID: <20170629193920.GG4028@eeg.ccf.org>
References: <d4df9e8e-bc30-619c-d1d2-8355b409a684@case.edu>
	<d284662d2c7e62bf76d24a993a3415537b538155@webmail.scope-eye.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <d284662d2c7e62bf76d24a993a3415537b538155@webmail.scope-eye.net>
User-Agent: Mutt/1.8.3 (2017-05-23)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
	[fuzzy]
X-Received-From: 139.137.100.1
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 19:39:28 -0000

On Thu, Jun 29, 2017 at 03:22:24PM -0400, tetsujin@scope-eye.net wrote:
> So I look at this not just as a RTFM issue, it's a pitfall built-in to
> the design of the language, and programmers need to understand a bit
> about the implementation of the language to understand what's going
> on. As such I think it may be worth spelling it out a bit more
> directly in terms of the implications here. For instance, stick it in
> the help for 'read' and 'mapfile':

If you include helpful text about every pitfall in every builtin, the
bash documentation will become three times its current size.

Hell, it's probably less work to write out what things you *can* safely
do, rather than what you can't.  There aren't very many!

But I don't think either of those things belongs in the reference manual.
You can't learn proper shell programming from a reference.  It's just
too big, too convoluted, too full of historical constructs.  You need
a more focused document.


From MAILER-DAEMON Thu Jun 29 17:20:46 2017
Received: from list by lists.gnu.org with archive (Exim 4.71)
	id 1dQgrl-0002Pw-UE
	for mharc-bug-bash@gnu.org; Thu, 29 Jun 2017 17:20:45 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:54756)
	by lists.gnu.org with esmtp (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dQgrk-0002PW-4e
	for bug-bash@gnu.org; Thu, 29 Jun 2017 17:20:45 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
	(envelope-from <tetsujin@scope-eye.net>) id 1dQgrg-0005xO-Tn
	for bug-bash@gnu.org; Thu, 29 Jun 2017 17:20:44 -0400
Received: from sub5.mail.dreamhost.com ([208.113.200.129]:33807
	helo=homiemail-a118.g.dreamhost.com)
	by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
	(Exim 4.71) (envelope-from <tetsujin@scope-eye.net>)
	id 1dQgrg-0005wj-Iq
	for bug-bash@gnu.org; Thu, 29 Jun 2017 17:20:40 -0400
Received: from homiemail-a118.g.dreamhost.com (localhost [127.0.0.1])
	by homiemail-a118.g.dreamhost.com (Postfix) with ESMTP id 62D9260002002;
	Thu, 29 Jun 2017 14:20:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=scope-eye.net; h=
	message-id:from:to:in-reply-to:subject:date:content-type
	:mime-version; s=scope-eye.net; bh=dSoDuuDWRD2cIQ7sxYVdlALoEz8=; b=
	Gv9GtMHEMK7EMZ74B0ZZoSMqVMxS7eXyyiWXDFbUW4sDaPKV0IlTwGsz1TQCZGYW
	n/HDzuF5u4hAplUF39jck2e6WxH6Y5+bWlvZg5YE9DP6mRU1vKkzAQ3X63p4vjVl
	vqNyzPulKvqa3LGkeB7EHoInQgI8whg1s1tCdi/DT6U=
Received: from localhost (alc-nat.dreamhost.com [66.33.206.8])
	(using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits))
	(No client certificate requested)
	(Authenticated sender: tetsujin@scope-eye.net)
	by homiemail-a118.g.dreamhost.com (Postfix) with ESMTPSA id
	F367960002001; Thu, 29 Jun 2017 14:20:33 -0700 (PDT)
Message-Id: <1b6485e0d7f04d0afbe821e2e6fb45112dc047b9@webmail.scope-eye.net>
From: tetsujin@scope-eye.net
To: "Greg Wooledge" <wooledg@eeg.ccf.org>,
 bug-bash@gnu.org
X-Mailer: Atmail 7.8.0.2
X-Originating-IP: 50.78.252.161
in-reply-to: <20170629193920.GG4028@eeg.ccf.org>
Subject: Re: mapfile doesn't accept input from a pipe
Date: Thu, 29 Jun 2017 17:20:33 -0400
MIME-Version: 1.0
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no
	timestamps) [generic] [fuzzy]
X-Received-From: 208.113.200.129
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Content-Filtered-By: Mailman/MimeDel 2.1.21
X-BeenThere: bug-bash@gnu.org
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/archive/html/bug-bash/>
List-Post: <mailto:bug-bash@gnu.org>
List-Help: <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/bug-bash>,
	<mailto:bug-bash-request@gnu.org?subject=subscribe>
X-List-Received-Date: Thu, 29 Jun 2017 21:20:45 -0000

=0AIt's a fair point but I think there may be a reasonable middle-ground=
,=0Ain which common pitfalls are briefly addressed in TFM, but the manua=
l=0Adoesn't become bogged down with exhaustive detail of every possible=
=0Apitfall.=0A=0AAfter all, information overload would just become anoth=
er thing=0Apreventing readers from absorbing the information.=0A=0A-----=
 Original Message -----=0AFrom: "Greg Wooledge" <wooledg@eeg.ccf.org>=0A=
To:<bug-bash@gnu.org>=0ACc:=0ASent:Thu, 29 Jun 2017 15:39:20 -0400=0ASub=
ject:Re: mapfile doesn't accept input from a pipe=0A=0A On Thu, Jun 29,=
 2017 at 03:22:24PM -0400, tetsujin@scope-eye.net=0Awrote:=0A > So I loo=
k at this not just as a RTFM issue, it's a pitfall built-in=0Ato=0A > th=
e design of the language, and programmers need to understand a=0Abit=0A=
 > about the implementation of the language to understand what's going=
=0A > on. As such I think it may be worth spelling it out a bit more=0A=
 > directly in terms of the implications here. For instance, stick it=0A=
in=0A > the help for 'read' and 'mapfile':=0A=0A If you include helpful=
 text about every pitfall in every builtin, the=0A bash documentation wi=
ll become three times its current size.=0A

