mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-06 06:33:24 +00:00
Use '\0' instead of 0 for nul character constants.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118096 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
5df0e0a61d
commit
a0f1a2baee
@ -693,7 +693,7 @@ Path::createDirectoryOnDisk( bool create_parents, std::string* ErrMsg ) {
|
||||
if (pathname[lastchar] != '/')
|
||||
++lastchar;
|
||||
|
||||
pathname[lastchar] = 0;
|
||||
pathname[lastchar] = '\0';
|
||||
|
||||
if (createDirectoryHelper(pathname, pathname+lastchar, create_parents))
|
||||
return MakeErrMsg(ErrMsg,
|
||||
@ -766,9 +766,9 @@ Path::eraseFromDisk(bool remove_contents, std::string *ErrStr) const {
|
||||
path.copy(pathname, MAXPATHLEN);
|
||||
size_t lastchar = path.length() - 1;
|
||||
if (pathname[lastchar] == '/')
|
||||
pathname[lastchar] = 0;
|
||||
pathname[lastchar] = '\0';
|
||||
else
|
||||
pathname[lastchar+1] = 0;
|
||||
pathname[lastchar+1] = '\0';
|
||||
|
||||
if (rmdir(pathname) != 0)
|
||||
return MakeErrMsg(ErrStr,
|
||||
|
Loading…
x
Reference in New Issue
Block a user