Skip to content

Commit c37419b

Browse files
pragmascriptmellinoe
authored andcommitted
Fixed small bug in null-terminated string counting
1 parent 49a11a7 commit c37419b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ImGui.NET.SampleProgram/ImGuiController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ private unsafe void SetWindowTitle(ImGuiViewportPtr vp, IntPtr title)
228228
int count = 0;
229229
while (titlePtr[count] != 0)
230230
{
231-
titlePtr += 1;
231+
count += 1;
232232
}
233233
window.Window.Title = System.Text.Encoding.ASCII.GetString(titlePtr, count);
234234
}

0 commit comments

Comments
 (0)