You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stdcxx.apache.org by "Travis Vitek (JIRA)" <ji...@apache.org> on 2007/10/25 19:44:50 UTC
[jira] Issue Comment Edited: (STDCXX-619) purify reports array
bounds read error in 25.remove test
[ https://issues.apache.org/jira/browse/STDCXX-619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12537457 ]
vitek edited comment on STDCXX-619 at 10/25/07 10:43 AM:
----------------------------------------------------------------
Simply avoid accessing the array inappropriately. I could have opted to add an else with a different assertion to keep the assertion count consistent, but that seems unnecessary.
was (Author: vitek):
Simply avoid the unnecessarily accessing the array inappropriately. I could have opted to add an else with a different assertion to keep the assertion count consistent, but that seems unnecessary.
> purify reports array bounds read error in 25.remove test
> --------------------------------------------------------
>
> Key: STDCXX-619
> URL: https://issues.apache.org/jira/browse/STDCXX-619
> Project: C++ Standard Library
> Issue Type: Improvement
> Components: Tests
> Affects Versions: 4.2
> Reporter: Travis Vitek
> Assignee: Travis Vitek
> Priority: Minor
> Fix For: 4.2.1
>
> Attachments: stdcxx-619.patch
>
>
> An rw_assert indexes past the end of an array if the preceeding for loop does not experience a failure.
> **** Purify instrumented ./25.remove (pid 19671) ****
> ABR: Array bounds read:
> * This is occurring while in thread 19671:
> test_remove<FwdIter<UserClass>, UserClass, EqualityPredicate<UserClass> >(int, char const*, char, unsigned, FwdIter<UserClass>, NoIterator, UserClass const*, UserClass const*, RemoveTag) [25.remove.cpp:213]
> test_remove<FwdIter<UserClass>, NoIterator, UserClass, EqualityPredicate<UserClass>, RemoveTag >(FwdIter<UserClass>, UserClass, NoIterator const*, UserClass const*, EqualityPredicate<UserClass>) [25.remove.cpp:384]
> test_remove<UserClass, EqualityPredicate<UserClass>, RemoveTag >(UserClass const*, EqualityPredicate<UserClass> const*, UserClass) [25.remove.cpp:440]
> test_remove<UserClass>(UserClass const*) [25.remove.cpp:471]
> run_test(int, char**) [25.remove.cpp:590]
> *unknown func* [pc=0x81201a8]
> * Reading 4 bytes from 0x81b88f8 in the heap.
> * Address 0x81b88f8 is 5 bytes past end of a malloc'd block at 0x81b88c0 of 52 bytes.
> * This block was allocated from thread -1207973632:
> malloc [rtlib.o]
> operator new(unsigned) [libstd15d.so]
> operator new [](unsigned) [libstd15d.so]
> UserClass* __rw_from_char<UserClass>(UserClass*, char const*, unsigned, bool) [value.cpp:485]
> UserClass::from_char(char const*, unsigned, bool) [value.cpp:533]
> test_remove<FwdIter<UserClass>, UserClass, EqualityPredicate<UserClass> >(int, char const*, char, unsigned, FwdIter<UserClass>, NoIterator, UserClass const*, UserClass const*, RemoveTag) [25.remove.cpp:153]
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.