[commit] r1787 - trunk/GME/Mga
GMESRC Repository Notifications
gme-commit at list.isis.vanderbilt.edu
Fri Jan 6 17:33:34 CST 2012
Author: ksmyth
Date: Fri Jan 6 17:33:34 2012
New Revision: 1787
Log:
BSTRs may be NULL; fix Jason crash on IFV export
Modified:
trunk/GME/Mga/MgaAttribute.cpp
Modified: trunk/GME/Mga/MgaAttribute.cpp
==============================================================================
--- trunk/GME/Mga/MgaAttribute.cpp Fri Jan 6 17:33:22 2012 (r1786)
+++ trunk/GME/Mga/MgaAttribute.cpp Fri Jan 6 17:33:34 2012 (r1787)
@@ -730,9 +730,9 @@
continue_ = false;
return;
}
- if (wcsncmp(it->first, mypath, mypath.Length()) == 0)
+ if (wcsncmp(it->first ? it->first : L"", mypath, mypath.Length()) == 0)
{
- std::wstring path = it->first;
+ std::wstring path = it->first ? it->first : L"";
if (path.length() > mypath.Length() && (mypath.Length() == 0 || path[mypath.Length()] == L'/'))
{
size_t end = path.find(L'/', mypath.Length() + 1);
@@ -842,7 +842,7 @@
for (auto it = map->begin(); it != map->end();)
{
- if (wcsncmp(it->first, mypath, mypath.Length()) == 0)
+ if (wcsncmp(it->first ? it->first : L"", mypath, mypath.Length()) == 0)
{
map->erase(it++);
} else
More information about the gme-commit
mailing list