diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/screencopy-dmabuf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/screencopy-dmabuf.c b/examples/screencopy-dmabuf.c index ea6b9f50..ebc6ea75 100644 --- a/examples/screencopy-dmabuf.c +++ b/examples/screencopy-dmabuf.c @@ -87,7 +87,7 @@ static bool find_render_node(char *node, size_t maxlen) { continue; } - strncpy(node, dev->nodes[DRM_NODE_RENDER], maxlen); + strncpy(node, dev->nodes[DRM_NODE_RENDER], maxlen - 1); node[maxlen - 1] = '\0'; r = true; break; |