From: rnv Date: Fri, 28 Nov 2008 13:23:12 +0000 (+0000) Subject: Dump Python Extension. X-Git-Tag: TG_DumpPython_Extension_3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=ddfd078fc9d5e89095129c6abfe81f0c840ea283;p=modules%2Fkernel.git Dump Python Extension. --- diff --git a/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx b/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx index 762f2e766..51d00c1a2 100644 --- a/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx +++ b/src/SALOMEDSImpl/SALOMEDSImpl_Tool.cxx @@ -246,7 +246,7 @@ vector SALOMEDSImpl_Tool::splitStringWithEmpty(const string& theValue, c vector aResult; if(theValue[0] == sep ) aResult.push_back(string()); int pos = theValue.find(sep); - if(pos < 0 && theValue.size() > 0) { + if(pos < 0 ) { aResult.push_back(theValue); return aResult; } @@ -272,9 +272,11 @@ vector SALOMEDSImpl_Tool::splitStringWithEmpty(const string& theValue, c vector< vector > SALOMEDSImpl_Tool::splitStringWithEmpty(const string& theValue, char sep1, char sep2) { vector< vector > aResult; - vector aSections = splitStringWithEmpty( theValue, sep1 ); - for( int i = 0, n = aSections.size(); i < n; i++ ) - aResult.push_back( splitStringWithEmpty( aSections[i], sep2 ) ); + if(theValue.size() > 0) { + vector aSections = splitStringWithEmpty( theValue, sep1 ); + for( int i = 0, n = aSections.size(); i < n; i++ ) + aResult.push_back( splitStringWithEmpty( aSections[i], sep2 ) ); + } return aResult; }