From b6e4eb556d8520aa2d562a6a0db9fdce0f18cfa1 Mon Sep 17 00:00:00 2001 From: ana Date: Tue, 13 May 2014 15:51:20 +0400 Subject: [PATCH] Win32: Fix error in Debug mode --- src/MEDLoader/MEDLoaderBase.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MEDLoader/MEDLoaderBase.cxx b/src/MEDLoader/MEDLoaderBase.cxx index 86bf9c227..0d661aa69 100644 --- a/src/MEDLoader/MEDLoaderBase.cxx +++ b/src/MEDLoader/MEDLoaderBase.cxx @@ -89,7 +89,7 @@ std::string MEDLoaderBase::buildUnionUnit(const char *name, int nameLgth, const { std::string ret(buildStringFromFortran(name,nameLgth)); std::string unitCpp(buildStringFromFortran(unit,unitLgth)); - if(unitCpp[0]=='\0') + if(unitCpp.empty() || unitCpp[0]=='\0') return ret; ret+=" ["; ret+=unitCpp; -- 2.39.2