Actually assign the string correctly through the std::string pointer.

llvm-svn: 8704
This commit is contained in:
Misha Brukman 2003-09-24 22:10:47 +00:00
parent e317856e0e
commit 86c8a485d0
1 changed files with 2 additions and 2 deletions

View File

@ -174,7 +174,7 @@ Module *ParseBytecodeBuffer(const unsigned char *Buffer, unsigned Length,
M = AMP->releaseModule();
delete AMP;
} catch (std::string &err) {
if (ErrorStr) ErrorStr = err;
if (ErrorStr) *ErrorStr = err;
return 0;
}
return M;
@ -199,7 +199,7 @@ Module *ParseBytecodeFile(const std::string &Filename, std::string *ErrorStr) {
M = AMP->releaseModule();
delete AMP;
} catch (std::string &err) {
if (ErrorStr) ErrorStr = err;
if (ErrorStr) *ErrorStr = err;
return 0;
}
return M;