* eoDetSelect: when the call of howmany() returns 0 it is replaced by 1
This commit is contained in:
parent
8e858e8fff
commit
bb5b1965c7
1 changed files with 6 additions and 0 deletions
|
|
@ -55,6 +55,12 @@ class eoDetSelect : public eoSelect<EOT>
|
|||
unsigned int pSize = _source.size();
|
||||
size_t target = howMany(pSize);
|
||||
|
||||
if ( target == 0 )
|
||||
{
|
||||
eo::log << eo::warnings << "Call to a eoHowMany instance returns 0 (target=" << target << ") it will be replaced by 1 to continue." << std::endl;
|
||||
target = 1;
|
||||
}
|
||||
|
||||
_dest.resize(target);
|
||||
|
||||
unsigned remain = target % pSize;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue