Add null terminator to string pointers (#77)

This commit is contained in:
Vladiwostok 2023-11-01 11:45:10 +02:00 committed by Vladiwostok
parent 3bd9b5c8cd
commit fdab43bee7
3 changed files with 18 additions and 15 deletions

3
.gitignore vendored
View File

@ -11,6 +11,9 @@
# Sublime Text 2 # Sublime Text 2
*.sublime-workspace *.sublime-workspace
# Idea stuff
.idea/
# Subversion # Subversion
.svn/ .svn/

View File

@ -502,8 +502,8 @@ void assertAnalyzerWarningsDMD(string code, const StaticAnalysisConfig config, b
global.params.useUnitTests = true; global.params.useUnitTests = true;
global.path = new Strings(); global.path = new Strings();
global.path.push((dmdParentDir ~ "/dmd").ptr); global.path.push((dmdParentDir ~ "/dmd" ~ "\0").ptr);
global.path.push((dmdParentDir ~ "/dmd/druntime/src").ptr); global.path.push((dmdParentDir ~ "/dmd/druntime/src" ~ "\0").ptr);
initDMD(); initDMD();

View File

@ -405,8 +405,8 @@ bool analyze(string[] fileNames, const StaticAnalysisConfig config, string error
global.params.useUnitTests = true; global.params.useUnitTests = true;
global.path = new Strings(); global.path = new Strings();
global.path.push((dmdParentDir ~ "/dmd").ptr); global.path.push((dmdParentDir ~ "/dmd" ~ "\0").ptr);
global.path.push((dmdParentDir ~ "/dmd/druntime/src").ptr); global.path.push((dmdParentDir ~ "/dmd/druntime/src" ~ "\0").ptr);
initDMD(); initDMD();