Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #14638

Re: bash sockets: printf \x0a does TCP fragmentation

Path csiph.com!xmission!news.snarked.org!news.linkpendium.com!news.linkpendium.com!panix!usenet.stanford.edu!not-for-mail
From Chet Ramey <chet.ramey@case.edu>
Newsgroups gnu.bash.bug
Subject Re: bash sockets: printf \x0a does TCP fragmentation
Date Sat, 22 Sep 2018 16:39:22 -0400
Organization ITS, Case Western Reserve University
Lines 16
Approved bug-bash@gnu.org
Message-ID <mailman.1143.1537663540.1284.bug-bash@gnu.org> (permalink)
References <c6de6616-dda0-570d-de56-419e7676be8a@cbii-hh.de> <69b48113-bc58-e0c8-a551-03a7e72d88d4@case.edu> <1a70754f-4302-1c96-1ae3-5ab9bdbdf8c3@iki.fi>
Reply-To chet.ramey@case.edu
NNTP-Posting-Host lists.gnu.org
Mime-Version 1.0
Content-Type text/plain; charset=utf-8
Content-Transfer-Encoding 7bit
X-Trace usenet.stanford.edu 1537663540 16529 208.118.235.17 (23 Sep 2018 00:45:40 GMT)
X-Complaints-To action@cs.stanford.edu
Cc chet.ramey@case.edu, dirk+bash@testssl.sh, bug-bash@gnu.org
To Ilkka Virta <itvirta@iki.fi>
Envelope-to bug-bash@gnu.org
X-Google-DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:reply-to:cc:subject:to:references:from :organization:message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=zKFS0SZxGrB9rJrV1Pxpyz5PNg2aIgyX6g8PaOombpQ=; b=iT3l/WDpCx+whytYv47n/FnH0XXjmPWCEQ4yuL3rFHrx744XffWI4hxzJClI/XFXEO 53+tA5dmIu2miw7ldHqaiCRe58rRa2Dw0spzsZAXy1SuAgBqBKRdabpOXFmVrNsbXewW KY5ju5OAmgK7Z5sh7X+MQnnVImN6KkuKNEh09/+909Pk10gbWCgwIuiqSpWubaP+RslH iUNVcskkhKXYimGcvIMCXgIB42zLJNpU4qTB/IfC9XDyOmFRMtATs/lF3lmkBZQaol3o 8zaw2iKEnNIyFCv0z6Eh+m808QfZmFEygysJMmANkczkZBg5v32PfM1slTqJ9PtdDIW7 71IA==
X-Gm-Message-State ABuFfogJ5tmGncnNcjHdiA+ORIFewNj62RtbJ2L5mKUHn+mDAeY/scE2 NDmANhDQrnKfesz1NNjXNGMPqusVvh4YmRo4OoN45jPSvhH9bTErZHD9NvOggEdlPD54rNGWulg PMSGAko9thw0=
X-Received by 2002:a24:1603:: with SMTP id a3-v6mr2632069ita.119.1537648764825; Sat, 22 Sep 2018 13:39:24 -0700 (PDT)
X-Google-Smtp-Source ANB0VdbXnSVNnd12gDHEQYy62Jjpqgup9TzWrlSdfM5XdOFyCbV3DblN5RRGhBFwE81fnB7dVEXRWw==
X-Received by 2002:a24:1603:: with SMTP id a3-v6mr2632053ita.119.1537648764606; Sat, 22 Sep 2018 13:39:24 -0700 (PDT)
User-Agent Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.9.1
In-Reply-To <1a70754f-4302-1c96-1ae3-5ab9bdbdf8c3@iki.fi>
Content-Language en-US
X-Junkmail-Status score=8/90, host=mpv4-2015.case.edu
X-Junkmail-PrAS-Raw score=8/90, refid=2.7.2:2018.9.22.193017:17:8.317, ip=, rules=__YOUTUBE_RCVD, __X_GOOGLE_DKIM_SIGNATURE, __HAS_REPLYTO, __HAS_CC_HDR, __MULTIPLE_RCPTS_CC_X2, __SUBJ_REPLY, __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, [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]
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>
Xref csiph.com gnu.bash.bug:14638

Show key headers only | View raw


On 9/22/18 6:38 AM, Ilkka Virta wrote:
> On 22.9. 02:34, Chet Ramey wrote:
>> Newline? It's probably that stdout is line-buffered and the newline causes
>> a flush, which results in a write(2).
> 
> Mostly out of curiosity, what kind of buffering logic does Bash (or the
> builtin printf in particular) use? 

Bash sets stdout and stderr to line buffering. It's done this since the
early 1.x days.

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

Back to gnu.bash.bug | Previous | Next | Find similar | Unroll thread


Thread

Re: bash sockets: printf \x0a does TCP fragmentation Chet Ramey <chet.ramey@case.edu> - 2018-09-22 16:39 -0400

csiph-web