diff options
Diffstat (limited to 'gfx/gl')
-rw-r--r-- | gfx/gl/shader-source.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/gfx/gl/shader-source.h b/gfx/gl/shader-source.h index 9403e80..f22cc3b 100644 --- a/gfx/gl/shader-source.h +++ b/gfx/gl/shader-source.h @@ -17,9 +17,11 @@ struct GLsource { constexpr auto constexpr_strlen(const GLchar * const s) { - auto e {s}; - while (*++e) { } - return e - s; + std::size_t ch {}; + while (s[ch]) { + ch++; + } + return ch; } #endif |