Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
glslang
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
glslang
Commits
3693e631
Commit
3693e631
authored
Sep 29, 2017
by
John Kessenich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix #1060: Could crash if using --source-entry-point with -e; fixed.
parent
5a57ca68
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
2 deletions
+6
-2
StandAlone.cpp
StandAlone/StandAlone.cpp
+5
-1
ParseHelper.h
glslang/MachineIndependent/ParseHelper.h
+1
-1
No files found.
StandAlone/StandAlone.cpp
View file @
3693e631
...
@@ -781,8 +781,12 @@ void CompileAndLinkShaderUnits(std::vector<ShaderCompUnit> compUnits)
...
@@ -781,8 +781,12 @@ void CompileAndLinkShaderUnits(std::vector<ShaderCompUnit> compUnits)
shader
->
setStringsWithLengthsAndNames
(
compUnit
.
text
,
NULL
,
compUnit
.
fileNameList
,
compUnit
.
count
);
shader
->
setStringsWithLengthsAndNames
(
compUnit
.
text
,
NULL
,
compUnit
.
fileNameList
,
compUnit
.
count
);
if
(
entryPointName
)
// HLSL todo: this needs to be tracked per compUnits
if
(
entryPointName
)
// HLSL todo: this needs to be tracked per compUnits
shader
->
setEntryPoint
(
entryPointName
);
shader
->
setEntryPoint
(
entryPointName
);
if
(
sourceEntryPointName
)
if
(
sourceEntryPointName
)
{
if
(
entryPointName
==
nullptr
)
printf
(
"Warning: Changing source entry point name without setting an entry-point name.
\n
"
"Use '-e <name>'.
\n
"
);
shader
->
setSourceEntryPoint
(
sourceEntryPointName
);
shader
->
setSourceEntryPoint
(
sourceEntryPointName
);
}
if
(
UserPreamble
.
isSet
())
if
(
UserPreamble
.
isSet
())
shader
->
setPreamble
(
UserPreamble
.
get
());
shader
->
setPreamble
(
UserPreamble
.
get
());
shader
->
addProcesses
(
Processes
);
shader
->
addProcesses
(
Processes
);
...
...
glslang/MachineIndependent/ParseHelper.h
View file @
3693e631
...
@@ -152,7 +152,7 @@ public:
...
@@ -152,7 +152,7 @@ public:
{
{
// Replace the entry point name given in the shader with the real entry point name,
// Replace the entry point name given in the shader with the real entry point name,
// if there is a substitution.
// if there is a substitution.
if
(
name
!=
nullptr
&&
*
name
==
sourceEntryPointName
)
if
(
name
!=
nullptr
&&
*
name
==
sourceEntryPointName
&&
intermediate
.
getEntryPointName
().
size
()
>
0
)
name
=
NewPoolTString
(
intermediate
.
getEntryPointName
().
c_str
());
name
=
NewPoolTString
(
intermediate
.
getEntryPointName
().
c_str
());
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment