Skip to content

Commit

Permalink
String must be null-terminated.
Browse files Browse the repository at this point in the history
  • Loading branch information
intorr committed Dec 8, 2017
1 parent 54ccc73 commit 1b897a2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Layers/xrRenderPC_R2/r2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1098,6 +1098,8 @@ HRESULT CRender::shader_compile(LPCSTR name, DWORD const* pSrcData, UINT SrcData
++len;
}

sh_name[len] = '\0';

// finish
defines[def_it].Name = 0;
defines[def_it].Definition = 0;
Expand Down

0 comments on commit 1b897a2

Please sign in to comment.