The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: usotsuki@buric.co (Steve Nickolas)
Subject: [TUHS] History of strncpy
Date: Thu, 24 Jan 2013 01:34:27 -0500 (EST)	[thread overview]
Message-ID: <alpine.DEB.2.02.1301240132540.3249@Ryou-VM1.yauncle.net> (raw)
In-Reply-To: <20130124060205.GQ24498@bitmover.com>

On Wed, 23 Jan 2013, Larry McVoy wrote:

> On Wed, Jan 23, 2013 at 04:46:51PM -0500, John Cowan wrote:
>> Ronald Natalie scripsit:
>>> Why on earth did they preserve the silly fread/fwrite size feature
>>> that just multiplies the two middle args together long after it was
>>> realized that portability doesn't demand making such a distinction.
>>
>> I like the idea: essentially it's about reading or writing an array
>> of a specified type.
>
> As a SPARC guy (in the past), I think it may have had something to do
> about alignment.
>
> That said, I hate the fread/fwrite interfaces.  We're fixing them in
> our stdio.  freadn(f, buf, n).
>

That syntax makes sense.  Though you'd prolly need a "#define 
fread(b,s,n,f) freadn(f,b,((s)*(n)))", right?  For backward compatibility.



  reply	other threads:[~2013-01-24  6:34 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-23 17:56 Michael Spacefalcon
2013-01-23 21:08 ` Larry McVoy
2013-01-23 21:39 ` Ronald Natalie
2013-01-23 21:46   ` John Cowan
2013-01-24  6:02     ` Larry McVoy
2013-01-24  6:34       ` Steve Nickolas [this message]
2013-01-24 14:42       ` Ronald Natalie
2013-01-24 14:52         ` Warner Losh
2013-01-24 16:01           ` Ronald Natalie
2013-01-24 18:31             ` Tom Ivar Helbekkmo
2013-01-25  2:06               ` Warner Losh
2013-01-24 16:21           ` Clem Cole
2013-02-01  0:28             ` Larry McVoy
2013-01-31 23:52           ` Random832
2013-02-01  0:06             ` Warner Losh
  -- strict thread matches above, loose matches on Subject: below --
2013-01-23  4:03 Nevin Liber
2013-01-23  4:41 ` Warren Toomey
2013-01-23  4:58 ` Warner Losh
2013-01-23 14:16 ` Clem Cole
2013-01-23 15:01   ` Ronald Natalie
2013-01-23 15:24     ` Armando Stettner
2013-01-23 17:49       ` scj
2013-01-23 18:19       ` Ronald Natalie
2013-01-23 19:33         ` Ronald Natalie
2013-01-23 19:59           ` Clem Cole
2013-01-23 22:43     ` Mary Ann Horton
2013-01-24  0:01       ` Clem Cole
2013-01-24  0:37 ` Jonathan Gevaryahu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.2.02.1301240132540.3249@Ryou-VM1.yauncle.net \
    --to=usotsuki@buric.co \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).