[
https://issues.apache.org/jira/browse/STDCXX-640?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12590182#action_12590182
]
farid edited comment on STDCXX-640 at 4/17/08 12:50 PM:
----------------------------------------------------------------
The patch is attached.
ChangeLog:
{noformat}
STDCXX-640
* include/loc/_num_get.cc (_C_get): Increase size of the __buf and
__grpbuf using __rw::__rw_tmpbuf() if needed.
* include/rw/_tmpbuf.h: New header file with a declaration of the
__rw::__rw_tmpbuf().
* include/rw/_rawiter.h: #include <rw/_tmpbuf.h> for declaring
__rw::__rw_tmpbuf().
* src/tmpbuf.cpp: Ditto.
{noformat}
was (Author: farid):
The patch is attached.
ChangeLog:
STDCXX-640
* include/loc/_num_get.cc (_C_get): Increase size of the __buf and __grpbuf
using __rw::__rw_tmpbuf() if needed.
* include/rw/_tmpbuf.h: New header file with a declaration of the
__rw::__rw_tmpbuf().
* include/rw/_rawiter.h: #include <rw/_tmpbuf.h> for declaring
__rw::__rw_tmpbuf().
* src/tmpbuf.cpp: Ditto.
> std::num_get::do_get() parses no more than 128 characters
> ---------------------------------------------------------
>
> Key: STDCXX-640
> URL: https://issues.apache.org/jira/browse/STDCXX-640
> Project: C++ Standard Library
> Issue Type: Bug
> Components: 22. Localization
> Affects Versions: 4.1.2, 4.1.3, 4.1.4, 4.2.0
> Environment: All
> Reporter: Farid Zaripov
> Assignee: Farid Zaripov
> Priority: Minor
> Fix For: 4.2.1
>
> Attachments: stdcxx-640.patch
>
> Original Estimate: 4h
> Remaining Estimate: 4h
>
> The following program fails on assert.
> {noformat}
> #include <cassert>
> #include <sstream>
> #include <string>
> int main ()
> {
> typedef std::num_get<char> NumGet;
> typedef std::istreambuf_iterator<char> Iter;
> std::locale loc;
> for (unsigned i = 0; i < 10000; ++i) {
> std::string s (i, '0');
> s.push_back ('1');
> std::istringstream is (s);
> std::ios::iostate state = std::ios::goodbit;
> long val = 0;
> std::use_facet<NumGet> (loc).get (Iter (is), Iter (), is, state, val);
> assert (1 == val && std::ios::eofbit == state);
> }
> return 0;
> }
> {noformat}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.