Page MenuHomeFreeBSD

(RFC) stdio: consolidate the two memstream implementations
Needs ReviewPublic

Authored by kevans on Fri, Jun 5, 1:09 AM.
Tags
None
Referenced Files
F159716424: D57461.id179249.diff
Wed, Jun 17, 10:48 AM
Unknown Object (File)
Sat, Jun 13, 12:26 PM
Unknown Object (File)
Wed, Jun 10, 10:29 PM
Unknown Object (File)
Wed, Jun 10, 6:20 PM
Unknown Object (File)
Wed, Jun 10, 6:30 AM
Unknown Object (File)
Tue, Jun 9, 7:10 PM
Subscribers

Details

Reviewers
jhb
des
Group Reviewers
Klara
Summary

Substantial parts of the memstream and wmemstream implementations
overlap, and it's a little laborious to duplicate code between the two.

Abstract the differences out into some streamcfg structs and see if we
can get the arithmetic right and converge on a single implementation.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 73692
Build 70575: arc lint + arc unit

Event Timeline

kevans requested review of this revision.Fri, Jun 5, 1:09 AM
lib/libc/stdio/open_memstream.c
97

is newoff here in bytes or in characters? I think the code might be easier to reason about if everything is in characters.

lib/libc/stdio/open_memstream.c
47

See NLINK_MAX in D57324