Our application was ported from UNIX to Linux(x86) and we are using Red Hat Linux. I have hit a problem with Rogue Wave libraries and would appreciate any help.
RWTPtrSlistIterator is being used to iterate a list which has RWTPtrSlist in them.
The code flow goes something like
CaUpdateSetIterator updateIter(( RWTPtrSlist<CaTableRow>)rightsideObj);
while(1)
{
nextRow = updateIter();
if(nextRow != null)
{
some logic
}
else
{
break;
}
}
The function enters the iterator
template <class TP> RWTPtrSlist<TP>::RWTPtrSlist(const RWTPtrSlist<TP>& s)
{
// Construct an iterator, casting away "constness"
// (which we promise to honor anyway):
RWTPtrSlistIterator<TP> next((RWTPtrSlist<TP>&)s);
TP* p;
while ((p = next())!=rwnil)
append(p);
RWPOSTCONDITION(s.entries()==entries());
}
There's one entry present and that gets appended in append(p). But when it exits the function, it calls the destructor and clears off the entry. So the nextRow doesn't get any value.
But the same code in UNIX works fine and the destructor for the same gets called only when break command gets executed.
Any ideas?
Please note that I am using the librwtool.so.2 along with the sunstudio11 installation in UNIX but working with the sunstudio12 library in Linux. I tried to find the sunstudio11 library for linux version but couldn't find any